Skip to content

feat(search): query-relevance rerank, list answers, multi-round latency guard#87

Open
us wants to merge 1 commit into
mainfrom
feat/search-relevance-list-answers
Open

feat(search): query-relevance rerank, list answers, multi-round latency guard#87
us wants to merge 1 commit into
mainfrom
feat/search-relevance-list-answers

Conversation

@us
Copy link
Copy Markdown
Owner

@us us commented Jun 3, 2026

No description provided.

…cy guard

Fix the "best pizza in belgrade" failure (geo-wrong sources, no list)
deployment-agnostically — inject NO geo/country signal, since the engine
is self-hosted in arbitrary regions. Rank on the query's own tokens.

All gated, default-off (byte-identical until flipped post-benchmark):
- rerank_relevance: a max-coverage gate drops partial-match homonyms (a
  "pizza in REDMOND" row, coverage 1/2) once a full-match row ("pizza …
  belgrade", 2/2) is present. Degrade-safe — never empties a non-empty pool.
- expand_query/scout_followups: always retain place names in every rewrite
  so query expansion can't strip the geo qualifier.
- answer_list_format + is_list_intent: ranked-list answers for "best/top X
  in Y" queries; cite_sources moat and abstention rule preserved.
- multi_round deadline budget: skip the extra scout round when under 20s of
  the request deadline remains, capping worst-case latency.

Tests: new rerank relevance-gate, is_list_intent, and prompt-swap cases;
the frozen 56-query rerank benchmark is unchanged.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant