feat(hooks): instructional recall banners for visible memory#526
Conversation
the per-prompt hook injected raw context ("consider it before
answering") with no instruction, so the model absorbed kb knowledge
invisibly and the user could not tell recall from silence — the single
most-reported "vouch isn't working" symptom. three changes:
- with relevant approved items, the banner now instructs the model to
open its reply with "From vouch memory:" and ground in the cited
items, citing each id. recall becomes visible on every turn.
- with no relevant items, the hook injects an explicit "found nothing
relevant — open with 'Nothing in vouch on this.'" banner instead of
nothing, so an empty kb reads as an empty kb, not a broken install.
- opt-in confidence short-circuit (retrieval.short_circuit.{enabled,
min_confidence}, default off): a high-confidence non-action lookup
may collapse to a verbatim vouched answer. scores squash to 0-1 via
1-exp(-score/5); a prompt whose first word is an imperative "do work"
verb never short-circuits, however confident the match — the action
gate, not the score, keeps it safe.
tests cover the three banners, the action gate, the opt-in default,
the threshold, and defensive config parsing; the no-hits test now pins
the explicit banner. readme documents the visible behaviour and drops
the stale "one-time approval" workaround note superseded by the
install-mcp auto-registration.
|
Warning Review limit reached
Next review available in: 10 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
the per-prompt recall hook injected raw kb context with no instruction ("consider it before answering"), so the model absorbed the knowledge invisibly — a user watching the reply cannot tell working recall from a dead install. that gap is the single most-reported "vouch isn't working" symptom: hooks fire, context flows, and nothing on screen ever says so.
this makes recall visible and verifiable on every turn:
retrieval.short_circuit.{enabled, min_confidence}, default off): a high-confidence non-action lookup may collapse to a verbatim vouched answer with the item ids. retrieval scores squash to 0-1 via1 - exp(-score/5); a prompt whose first word is an imperative "do work" verb (fix/build/deploy/…) never short-circuits, however confident the match — the action gate, not the score, is what keeps this safe.sixteen tests cover the three banners, the action gate, the opt-in default, the threshold, and defensive config parsing; the old no-hits-injects-nothing test now pins the explicit banner. the readme documents the visible behaviour ("what you'll see") and drops the stale "one-time approval" workaround note that the install-mcp auto-registration (#523) superseded.
make checkgreen: pytest (full suite minus embeddings), mypy 99 files clean, ruff clean.