Skip to content

Stage 2c: lyric annotations and manual review

Lyric text remains unchanged. The lyrics API adds a nullable annotation to each line: bookOsis, chapter, verseStart, verseEnd, reference, and note. Only lines with a stored annotation are interactive. Passage requests use the existing WEB API and its dot reference syntax, for example PSA.23.1-2.

lyrics-annotate-auto --receipt <file> [--checkpoints <directory>] processes current approved, non-instrumental versions. All qwen3-next:80b generation runs before any gpt-oss:20b screening. Generation favors four strong connections, allowing up to eight when each adds a different connection. References must exist in WEB; notes are at most 400 characters. The screen must explicitly approve relevance and a charitable, encouraging reading. Invalid proposals, failed screens, and model errors are dropped without retry. Each pass permits at most 10% operational errors. Parsed checkpoints bind version, content hash, policy, and model; screen checkpoints also bind the proposals. Checkpoints contain notes but no lyrics or raw model responses. Console output and the receipt contain counts and IDs only. Requests use an 8,192-token context and batch size 64 to limit working memory on the gaming PC. Screening uses low thinking and a 4,096-token prediction budget. During generation, the same generator is released after each 16 actual requests and loaded again for the next chunk. Cached results do not count toward a chunk. This bounds memory growth while keeping all generation ahead of screening. On Windows, transient file locks get up to six atomic rename attempts, 100 ms apart. The temporary JSON is written once; this never repeats a model request.

Manual review commands:

lyrics-review-export --out <file.csv>
song-remove --song <id> --reason <text> --actor <name>
song-restore --song <id> --reason <text> --actor <name>

The CSV contains rejected/pending candidate songs, including historical lyric candidates, with title, artist, status, and reason codes. It contains no lyrics. Removal affects only that song; the artist's other songs remain listed. Removal and restoration record the actor, reason, and time. Neither model makes removal decisions. Inbox links open email to hello@verse4verse.org; they have no backend and do not invoke these commands.

scripts/build-snapshot-2c.ps1 copies the verified source snapshot, publishes the worker/API, applies migrations to the copy, annotates, exports review metadata, and runs the existing count/identity checks plus a local API smoke. -FinalizeOnly uses a completed annotation receipt without inference. Its manifest retains stage: "2b" for the existing swap protocol and adds annotationStage: "2c" and annotation counts. The inherited publication evidence is unchanged. The legacy CLI migration context uses an isolated staging file; public lyrics and the inbox do not read it. No deployment is performed.

The 2c build also carries every manual review decision made live onto the copy. Pass exactly one of -LiveDatabase <checkpointed live copy>, -LiveDecisionsExport <json> or -NoLiveDecisions -NoLiveDecisionsReason <why>. The build exports, replays and gates the decisions before its other gates. It then runs the tuple gate against the post-replay publicationTuples and records manualDecisions in the manifest. Steps and failure codes are in docs/snapshot-manual-decisions.md.