Added execution time to the UI
This commit is contained in:
parent
cfd1147d5a
commit
5110e956d2
|
@ -882,6 +882,7 @@ function formatChunkInnerText(chunk) {
|
|||
}
|
||||
|
||||
function dosubmit(disallow_abort) {
|
||||
submit_start = Date.now();
|
||||
var txt = input_text.val().replace(/\u00a0/g, " ");
|
||||
if((disallow_abort || gamestate !== "wait") && !memorymode && !gamestarted && ((!adventure || !action_mode) && txt.trim().length == 0)) {
|
||||
return;
|
||||
|
@ -2099,6 +2100,10 @@ $(document).ready(function(){
|
|||
scrollToBottom();
|
||||
} else if(msg.cmd == "updatechunk") {
|
||||
hideMessage();
|
||||
if (typeof submit_start !== 'undefined') {
|
||||
$("#runtime")[0].innerHTML = `Generation time: ${Math.round((Date.now() - submit_start)/1000)} sec`;
|
||||
delete submit_start;
|
||||
}
|
||||
var index = msg.data.index;
|
||||
var html = msg.data.html;
|
||||
var existingChunk = game_text.children('#n' + index);
|
||||
|
|
|
@ -93,6 +93,7 @@
|
|||
</div>
|
||||
<div id="connectstatusdiv" class="flex-row-container">
|
||||
<span id="connectstatus" class="color_orange flex-row">Waiting for connection...</span>
|
||||
<div class="layer-container status-container flex-push-left" style="color: #FFFFFF;" id="runtime"></div>
|
||||
<div class="layer-container status-container flex-push-right">
|
||||
<span class="oi oi-puzzle-piece statusicon layer-bottom" aria-hidden="true">
|
||||
<div class="statustext statustext-wide">
|
||||
|
|
|
@ -150,6 +150,10 @@ def test_load_model_from_web_ui(client_data, model, expected_load_options):
|
|||
|
||||
generate_story_data(client_data)
|
||||
|
||||
def test_load_GooseAI_from_web_ui(client_data):
|
||||
|
||||
pytest.skip("unsupported configuration")
|
||||
|
||||
@pytest.mark.parametrize("model, expected_load_options", test_models)
|
||||
def test_load_model_from_command_line(client_data, model, expected_load_options):
|
||||
(client, app, socketio_client) = client_data
|
||||
|
|
Loading…
Reference in New Issue