From 3a7d796f30e0bf24ab4142de81748b838128019d Mon Sep 17 00:00:00 2001 From: iamdoubz <> Date: Fri, 6 Nov 2026 11:50:06 -0600 Subject: [PATCH] Show scan stats behind a Scan Stats button --- .env.example | 2 +- CHANGELOG.md | 2 +- docs/SPEC.md | 2 +- frontend/src/routes/ScanPage.svelte | 36 +++++++++++++++++++++-------- 4 files changed, 29 insertions(+), 13 deletions(-) diff --git a/.env.example b/.env.example index b26c6ea..ae7880d 100644 --- a/.env.example +++ b/.env.example @@ -40,5 +40,5 @@ EXTRACT_MODEL=nemotron-3.5-bolt:e4b # Days to keep photos after a scan is published. IMAGE_RETENTION_DAYS=90 -# 1 shows the model and how long it took on each scan's page, for comparing models. Every scan's time is logged either way. +# 1 adds a "Scan Stats" button to each scan's page (model, tokens, pages, events, scan time), for comparing models. Every scan's time is logged either way. # SHOW_SCAN_STATS=0 diff --git a/CHANGELOG.md b/CHANGELOG.md index d250e67..767a891 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,7 +10,7 @@ The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and ### Added - A published scan's photo can still be viewed from its scan page, under "Scanned photo", until it's deleted after `IMAGE_RETENTION_DAYS`. -- A log line for every scan with how long it took, the model and what it found. `SHOW_SCAN_STATS=1` also shows the model and time on each scan's page. +- A log line for every scan with how long it took, the model and what it found. `SHOW_SCAN_STATS=1` adds a "Scan Stats" button next to a scan's status that shows the model, tokens used, pages, events and scan time. - Today stands out on the Lunch screen and in the Calendar list: a filled day number like the month view, a "Today" label and a tinted card. ## [0.0.3] - 2026-11-06 diff --git a/docs/SPEC.md b/docs/SPEC.md index cd806a2..25d96a0 100644 --- a/docs/SPEC.md +++ b/docs/SPEC.md @@ -105,7 +105,7 @@ Both include `python main.py backup `, which runs SQLite's online b | `EXTRACT_IGNORE` | Comma-separated labels dropped from every source's menu items and event titles. Each source can add its own in `ignore_labels` | Not set; for example `BHS,Milk` | | `HOST`, `PORT` | Bind address | `127.0.0.1`, `8000` | | `IMAGE_RETENTION_DAYS` | Days to keep images after publish | `90` | -| `SHOW_SCAN_STATS` | `1` shows the model and processing time on each scan's page. Every scan's time is logged either way | `0` | +| `SHOW_SCAN_STATS` | `1` adds a "Scan Stats" button to each scan's page: model, tokens used, pages, events and scan time. Every scan's time is logged either way | `0` | **Deployment on the home server** diff --git a/frontend/src/routes/ScanPage.svelte b/frontend/src/routes/ScanPage.svelte index 9b2b897..7607622 100644 --- a/frontend/src/routes/ScanPage.svelte +++ b/frontend/src/routes/ScanPage.svelte @@ -1,7 +1,7 @@