adjust jinja template

This commit is contained in:
Cyberes 2023-09-30 22:11:51 -06:00
parent bc25d92c95
commit c5b30d985c
2 changed files with 3 additions and 3 deletions

View File

@ -105,9 +105,9 @@ def home():
if default_backend_info['queued'] == 0 and default_backend_info['queued'] >= opts.concurrent_gens: if default_backend_info['queued'] == 0 and default_backend_info['queued'] >= opts.concurrent_gens:
# There will be a wait if the queue is empty but prompts are processing, but we don't # There will be a wait if the queue is empty but prompts are processing, but we don't
# know how long. # know how long.
default_estimated_wait_sec = f"less than {default_backend_info['estimated_wait']} seconds" default_estimated_wait_sec = f"less than {int(default_backend_info['estimated_wait'])} seconds"
else: else:
default_estimated_wait_sec = f"{default_backend_info['estimated_wait']} seconds" default_estimated_wait_sec = f"{int(default_backend_info['estimated_wait'])} seconds"
if len(config['analytics_tracking_code']): if len(config['analytics_tracking_code']):
analytics_tracking_code = f"<script>\n{config['analytics_tracking_code']}\n</script>" analytics_tracking_code = f"<script>\n{config['analytics_tracking_code']}\n</script>"

View File

@ -163,7 +163,7 @@
<strong>OpenAI-Compatible API URL:</strong> {{ value.openai_client_api }} <strong>OpenAI-Compatible API URL:</strong> {{ value.openai_client_api }}
</p> </p>
<p><strong>Context Size:</strong> {{ value.context_size }}</p> <p><strong>Context Size:</strong> {{ value.context_size }}</p>
<p><strong>Average Generation Time:</strong> {{ value.avg_generation_time | int }}</p> <p><strong>Average Generation Time:</strong> {{ value.avg_generation_time | int }} seconds</p>
</div> </div>
<br> <br>
{% endfor %} {% endfor %}