{% extends "base.html" %} {% block content %}
AI Model Health, Selection Reasoning, and Availability.
{{ cache.error }}
| Role | Selected Model | Est. Cost | Selection Reasoning |
|---|---|---|---|
| {{ role }} | {{ info.model }} | {{ info.estimated_cost }} | {{ info.reason }} |
| Image | {% if image_model %} {{ image_model }} {% else %} Unavailable {% endif %} | {{ image_source or 'None' }} | {% if image_model %}Imagen model used for book cover generation.{% else %}No image generation model could be initialized. Check GCP credentials or Gemini API key.{% endif %} |
|
No model configuration found.
Click Refresh & Optimize to scan available Gemini models. |
|||
| Rank | Model Name | Est. Cost | Reasoning |
|---|---|---|---|
| {{ loop.index }} | {{ item.model }} | {{ item.estimated_cost }} | {{ item.reason }} |
| No ranking data available. Refresh models to generate. | |||
# Full list of models returned by google.generativeai.list_models():
Last Scan: {% if cache and cache.timestamp %} {{ datetime.fromtimestamp(cache.timestamp).strftime('%Y-%m-%d %H:%M:%S') }} UTC {% else %} Never {% endif %}
Next Refresh: {% if cache and cache.timestamp %} {% set expires = cache.timestamp + 86400 %} {% set now_ts = datetime.utcnow().timestamp() %} {% if expires > now_ts %} {% set remaining = (expires - now_ts) | int %} {% set h = remaining // 3600 %}{% set m = (remaining % 3600) // 60 %} in {{ h }}h {{ m }}m Cache Valid {% else %} Expired — click Refresh & Optimize {% endif %} {% else %} No cache — click Refresh & Optimize {% endif %}
Model selection is cached for 24 hours to save API calls.