Prevent generation fallbacks from sticking in answer cache - #1831
Conversation
This pull request has been ignored for the connected project Preview Branches by Supabase. |
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit:0c96538c84
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Uh oh!
There was an error while loading. Please reload this page.
BigSimmo
commented
Aug 12, 2026
@codex resolve actionable Codex review findings for this pull request and current head using the repository instructions. This is the pull request's single automatic repair pass: do not perform a fresh review, create new standalone findings, or request another review. Work only the existing unresolved Codex threads on the current head. The only repository destination is BigSimmo/Database, and the only branch destination is the pull request head branch codex/rag-fallback-cache-231 at starting commit 0c96538; never publish fixes to a detached or synthetic work branch and never create a stacked pull request. Use the authenticated GitHub connector to commit each approved fix to BigSimmo/Database:codex/rag-fallback-cache-231, then verify that the pull request head contains the published commit before reporting success. Always fix P0 and P1 findings. For P2 and lower findings, fix only clear, scoped, low-risk issues; otherwise disposition them with a concise reason. For a fixed thread, reply with as the first line and as the second line. For a no-code disposition, use followed by . These result markers authorize the workflow to close that exact thread only after it verifies a fixed commit is the pull request head; a local-only commit is not a fix. If publication or verification fails, do not use either result marker, do not claim success, and leave the thread open with the blocker. If human input or new authorization is required, do the same. Finish only after every actionable thread is fixed or dispositioned and closed, or explicitly left open for a human decision. Do not update the branch from main, address unrelated reviews, broaden scope, or create more than one scoped fix commit. Do not use external APIs, paid services, credentials, dependency changes, or broad refactors unless explicitly authorized. Add targeted tests where behavior changes and run the narrowest relevant validation. |
Codex Review: Didn't find any major issues. Swish! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
BigSimmo
commented
Aug 12, 2026
Babysit PR summary
|
BigSimmo
commented
Aug 12, 2026
Babysit review (scope: exact babysit-pr)Snapshot (current GitHub head):
Outcome: dispositioned; merge left to you. |
BigSimmo
commented
Aug 12, 2026
Codex babysit snapshot (scope babysit)
No merge blockers are currently surfaced on this branch review sweep. |
BigSimmo
commented
Aug 12, 2026
Babysit review summary
No pushes made (no local modifications for this PR). |
Summary
rag_response_cache, including grounded extractive recovery answers, so a transient fallback cannot remain sticky after provider recoveryRAG impact: behaviour change — canary pair local-baseline-fb54b4dc3 -> local-final-0c96538c8; retrieval remained 36/36 with document/content recall 1.0, identical MRR/content-MRR, and zero per-case reciprocal-rank regressions. Final 44-case answer quality retained grounded-supported 1.0, citation failure 0, and numeric-grounding failure 0.
Verification
node scripts/run-vitest.mjs run tests/rag-route-budget.test.ts tests/rag-answer-fallback.test.ts— 96 passednpm run eval:rag:offline— 23 files, 574 passed; fixture/production contracts passednpm run check:rag:fixtures— 36 golden cases and 23 suites passednpm run typecheck— passed on the exact stacked branchnpm run check:production-readiness— source/config gate was run in the secret-free isolated worktree and correctly reported missing local env; the live canaries instead loaded the designated primary.env.localin process memory and succeededUI verification not run: no UI, routing, styling, or browser behavior changed.
Risk and rollout
Clinical Governance Preflight
Clinical KB Database(sjrfecxgysukkwxsowpy)Notes
Lithium dosing?probes showed the remaining fallback isgeneration_quality_failedwithroute_deadline_exceeded=false; timeout inflation was tested, rejected, and not shipped.codex/pr-workflow-safety-230-296.