feat(asr): feed campaign proper nouns to the transcriber as vocabulary bias (#355) #491
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/355-asr-vocabulary"
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?
Closes #355 (all criteria except the golden-corpus measurement — see below).
Every transcription request for a session now carries the campaign's proper nouns through the ASR contract's
vocabularyinput (#350), whichLocalWhisperProvidermaps to Whisper'sinitial_prompt.What
app/services/vocabulary_service.py—campaign_vocabulary(db, campaign_id, *, limit)over three sources, ranked in tiers so a whole tier survives truncation before the next starts: (0) party character names, (1) wiki entry titles of proper-noun types + NPC cards, ranked by session-appearance count then recency, (2) aliases. Case-insensitive dedupe after ranking so the higher-ranked spelling wins. Excludes trashed entries (#408) and unaccepted bot proposals, so the pipeline cannot teach itself its own misspelling. Cleaning drops junk (single lowercase words, >6-word titles, edge punctuation) and is scoped to cased scripts.reminder_tasks.resolve_asr_vocabulary— resolves the ASR provider, reads its declared vocabulary style and limit, returns nothing without querying when the provider has no vocabulary support, logs the count only.audio_service: plain, VAD, per-span, and the language-detection probe (whose transcript is kept as that span's result, so skipping it would leave one span per track unbiased).asr_providernow travels with it — it was read from settings and dropped before.Not claimed
"Measured effect recorded against the golden corpus" — the synthetic-audio harness (#433) that can measure proper-noun survival is not built yet; the measurement is a follow-up on that issue. Also note the bundled WhisperX server currently ignores
initial_prompt; the server-side #352 change (in flight in the infrastructure repo) makes it honour it.Verification
🤖 Generated with Claude Code