Backend optimizations: - Refactor get_random_images() using SQLite ORDER BY RANDOM() - Simplify from 60+ lines to ~20 lines with better performance - Remove complex multi-cycle index calculations - Maintain file existence check and auto-cleanup ComfyUI support: - Add fallback to 'parameters' field in PNG metadata - Improve detection for ComfyUI-generated images Frontend improvements: - Smart prompt display: auto-detect tag vs natural language format - Add getTextLength() with Chinese character weight (1 char = 3 letters) - Refactor isTagStylePrompt() with clear rules: * Any tag length > 50 natural language format * Average tag length > 30 natural language format - Natural language prompts shown as paragraphs - Tag-style prompts shown as badges - Better support for Chinese/English mixed content Build: - Update frontend asset references |
||
|---|---|---|
| .. | ||
| datamodel.py | ||
| update_image_data.py | ||