Street-name STT keyterms — Expected Output Spec
§0 Root cause (verified 2026-09-04)
"30 PEERS PLACE" is published and loads into the agent's listing set;
resolve_listing finds it from "Peers Place", "30 Peers", "the house on Peers
Place" — but returns NONE for "Piers Place"/"Pierce Place"/"pears place". The
caller said "Peers"; Deepgram rendered a homophone; the resolver correctly
declined to name a wrong house. Fix upstream: make STT hear the real street.
The keyterm list (main.py ~1596-1625) currently boosts town names, never
street names.
§1 Expected output
- On the real-estate path, derive a DISTINCT set of street-name tokens from the tenant's loaded listings (the address minus the leading number and the generic suffix — "Peers" from "30 PEERS PLACE", "Commissioners" from "1487 Commissioners Rd"). Reuse the existing address tokenizer / stopword set so "place/street/road/etc." are excluded — do NOT reinvent it.
- Feed those tokens into
keytermsalongside the existing town/brand terms. - CAP + PRIORITISE: Deepgram keyterms are bounded; do not dump hundreds. Cap at a sane N (e.g. 100 street tokens), preferring OWN-brokerage listings first (own_office_keys), then most-recent, and DEDUPE case-insensitively. Log the count kept and dropped (no silent truncation — house rule).
- ORDERING: keyterms are assembled before listings load today. Restructure so the street tokens are available at STT construction (load listings first, or pass them through, or rebuild keyterms after load) WITHOUT changing any other call-setup ordering that matters. If that proves too invasive, say so and propose the smallest safe alternative rather than forcing it.
- Multilingual path: street tokens are language-neutral proper nouns; include them on the Hindi path too (they are Latin-script names either way).
§2 Acceptance checks
- Unit: given listings incl. "30 PEERS PLACE", the derived keyterm set contains "Peers" (case-insensitively) and excludes the generic suffix.
- Unit: the cap holds — > N listings yields ≤ N street tokens, own-brokerage preferred, deduped; the drop count is logged.
- Unit/integration: keyterms actually reach the Deepgram STT constructor on BOTH the English and multilingual real-estate paths (assert on the built args, not just the list).
- Regression: church/funeral/vet/sales keyterms unchanged (street derivation is real-estate-only) — pin it.
- The full voice unit + behavioural suites stay green.
- NOTE the honest limit: this raises the odds STT hears the street; it is not a guarantee for every homophone, and the resolver's refuse-to-guess behaviour stays as the correct backstop. Do not weaken the resolver.
§3 Out of scope
Phonetic/fuzzy matching in the resolver (deliberately NOT loosened); full-board (non-owned) street names beyond the loaded set; church/other verticals.