OCR / text extraction from screenshots into searchable content #118
Labels
No labels
bug
duplicate
enhancement
future
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
rbrooks/TeaLeaves#118
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Feature idea (audit Phase 5, rank #1 by value-to-effort) · Effort: low-medium
Why
The domain is media analysis and the user screenshots lyrics, captions, and on-screen text. Today the vision model produces a description and tags (
api/src/services/ai.ts) but never extracts the literal text into the entry's searchable content, so screenshotted text isn't findable by full-text search.Proposal
Reuse the existing vision provider to OCR image text on upload and offer the extracted text for the user to accept into
content- the same approve-before-apply pattern already used for AI tag suggestions (nothing applied automatically). Fits the provider-agnostic AI service and the media pipeline.Why it was likely missed
AI was scoped to "describe + tag," not "transcribe image text."
Acceptance criteria
Filed from the 2026-07-15 codebase audit. Full report:
docs/.internal/report-2026-07-15.md(gitignored).Done — shipped in v9.3.0 (PR #142, merge
c69897c).extractImageText()reuses the provider-agnostic vision path (new OCR prompt);runAIAnalysisstoresmedia.ocr_text(migration 055).POST /api/media/:id/accept-ocrappends the text to the entry content — sanitized on write, and full-text searchable immediately (the FTS index is an expression overentries.content). UI: a "Show extracted text (OCR)" → "Add transcribed text to entry" control on the media card. 3 integration tests.Acceptance: ✅ extracted text offered on upload · ✅ accepted text sanitized + searchable · ✅ nothing applied without explicit approval (no-ops entirely when AI isn't configured).