Repository navigation
v0.2.2 — Fix Daily Summary Context Window Overflow
v0.2.2 — Fix Daily Summary Context Window Overflow
This release fixes #16 where daily summary generation could fail with 400 Bad Request when the prompt exceeded the llama-server context window.
What's Fixed
🔧 Summary generation no longer overflows the context window
The prompt is now dynamically budgeted against your context_window setting. Even at the minimum 2048 tokens, summaries generate reliably — older entries are trimmed to fit, and max_tokens adapts automatically.
🧹 Placeholder entries no longer pollute stats, search, or summaries
Entries like "Skipped (analysis backlog)" and "Analysis failed: ..." were counted as real activities in category breakdowns, search results, and summary prompts. A new 5-state status model (pending → ok / skipped / failed / dead) cleanly separates real analyses from placeholders across all 15 query sites.
🚫 Failed summaries no longer get persisted as the summary text
Previously, if the LLM call failed, the error message was stored as the day's summary. Now the endpoint returns HTTP 500 with the actual error, and the dashboard displays it properly — your previously-good summary is never overwritten.
🔄 Corrupt/deleted screenshots no longer loop forever
Screenshots that are deleted from disk or corrupted are now marked as dead (terminal state) instead of being re-picked by the backfill worker every idle cycle.
What's New
📊 Analysis Status card on the Analytics dashboard
A new card shows the health of your analysis pipeline — how many captures were successfully analyzed vs pending, skipped, failed, or dead. Includes a progress bar and respects the Day/Week/Month toggle.
Upgrade Notes
⚠️ Database migration (v7): This release adds astatuscolumn to the activities table. The migration runs automatically on first startup and is irreversible. Back up~/.screenmind/screenmind.dbbefore upgrading if you want a safety net.
# Backup (optional but recommended)
cp ~/.screenmind/screenmind.db ~/.screenmind/screenmind.db.backup
# Upgrade
pip install --upgrade screenmindThe migration backfills existing rows by analyzing their summary text — real analyses become ok, staleness skips become skipped, failures become failed, and corrupt/deleted screenshots become dead. No data is lost.
Files Changed
11 files, +548 / -47 lines across backend (Python), frontend (JS), and tests.
Full diff: v0.2.1...v0.2.2