diff --git a/docs/branch-review-ledger.md b/docs/branch-review-ledger.md index 20ed4fbdb..b12ebd09d 100644 --- a/docs/branch-review-ledger.md +++ b/docs/branch-review-ledger.md @@ -408,6 +408,72 @@ Use this ledger to prevent repeated branch and PR reviews when the reviewed HEAD | 2026-07-14 | codex/specifiers-design | c3e7024e15d2157bbc0b989276324cc6ad3eea5c | Specifiers UI, clinical decision-support, accessibility, and release-readiness review | One P2 WCAG contrast defect was reproduced and fixed across the builder, comparison, and map accent eyebrows. No remaining high-confidence defect was found in the changed scope; residual risk is clinical/manual governance of the original specifier summaries. | Focused Vitest 18/18; focused Chromium desktop/mobile 2/2 with serious/critical axe WCAG A/AA scanning and overflow checks; `npm run check:production-readiness:ci` READY; `npm run verify:cheap` 2,210 passed/1 skipped; `npm run verify:pr-local` 2,213 passed/1 skipped plus production build and client-bundle secret scan; `git diff --check`. Full advisory `verify:ui` exceeded the local 10-minute execution window; provider-backed checks were not run. | | 2026-07-14 | PR #633 / codex/specifiers-design | 03daca3bfdf86517b9956f3c7d91be27d9f1a751 | Review follow-up and failed UI regression | Eight distinct P2 behaviors across nine review threads were confirmed and fixed: initial selection normalization, duplicate query removal, clinical applicability mapping, canonical Specifiers routing, severity-neutral base wording, diagnostic-section ordering, base/specifier compatibility, and severe psychotic-features wording. The failed app-menu keyboard test was a stale order assertion and now covers the inserted Specifiers item. | Focused Vitest 6/6; focused Chromium 4/4; scoped ESLint and TypeScript; CI-mode production readiness READY; production build and client-bundle secret scan passed. Hosted required checks passed on the refreshed `main` merge before the final compatibility fixes; provider-backed Supabase/OpenAI checks were not run. | | 2026-07-14 | PR #634 / codex/global-answer-reliability | b411329ec5f181661e5d49276c398440aa928fa2 | review-followup | One late P2 fast-context defect was confirmed: Australian tier ordering could push a higher-ranked supplementary passage outside the four-chunk routine fast budget. Fixed by preserving the retrieval-ranked, crowding-capped candidate budget before applying the order-only Australian preference within that set. | GitHub connector review-thread inspection; focused RAG context-budget suite 22/22; ESLint; TypeScript; Prettier; `git diff --check`. | +| 2026-07-14 | claude/audit-ci-browser-gate-2026-07-13 | 09be064a09e8199e9359c50ea0dfceb25847cacf | branch-cleanup | Deleted local ref after confirming no patch-unique content remained; remote ref was left untouched. | Local cherry-pick-aware comparison to current `origin/main`; worktree/activity scan. | +| 2026-07-14 | claude/beautiful-hamilton-5df54c | 5e2e90f0a3af4039c7e15515151569228476a60c | branch-cleanup | Deleted local redundant ref; exact head was already represented on `origin/main`. | Local cherry-pick-aware comparison and prior exact-head ledger evidence. | +| 2026-07-14 | claude/canary-gate-fixes | 85411f5db736e111fdb278468787dc8b32bb5ebe | branch-cleanup | Deleted local ref after confirming no patch-unique content remained; remote ref was left untouched. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | claude/codebase-index-coverage | 258782c8426541f43e03009ccf6bb27b9ce90ca5 | branch-cleanup | Deleted local ref after confirming no patch-unique content remained; remote ref was left untouched. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | claude/design-elevation-e1e2 | b91437c9068b6dba2f25e831d360e2dbcbeeb75a | branch-cleanup | Deleted local ref after confirming no patch-unique content remained; remote ref was left untouched. | Local cherry-pick-aware comparison to current `origin/main`; detached head remained remotely anchored before worktree removal. | +| 2026-07-14 | claude/design-sync-fixes-p1 | 8103c560fb7e69dcadb1155cf9feb706aa8a8517 | branch-cleanup | Deleted local ref after confirming no patch-unique content remained; remote ref was left untouched. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | claude/docs-script-linter | 9f31fc5b62d4cd69cfe2ee92241d7e15e33d8de0 | branch-cleanup | Deleted local ref after confirming no patch-unique content remained; remote ref was left untouched. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | claude/hero-composer-hydration | eb7cc81c0513da46cd07b9fe1a189952914a5613 | branch-cleanup | Deleted local redundant ref; the separately named teardown branch and its locked worktree were preserved. | Local cherry-pick-aware comparison plus worktree lock scan. | +| 2026-07-14 | claude/lithium-search-issue-7903a2 | a6b2dbcd6e289ada4d8abb88861dc43063236058 | branch-cleanup | Deleted local ref using prior exact-head squash-merge evidence; remote ref was left untouched. | Prior PR #460 exact-source-head ledger evidence and fresh worktree scan. | +| 2026-07-14 | claude/observability-alerts-rollback-8d9b79 | 67144fe56b776fb58d2518d057d41612399f65b6 | branch-cleanup | Deleted local ref using prior exact-head squash-merge evidence; newer remote work remained untouched. | Prior PR #536 exact-source-head ledger evidence and fresh ref scan. | +| 2026-07-14 | claude/pt-audit-monitor-marker-fix | 7d41cbe5a42b9a7f90d15ad3e80cdca6596548e0 | branch-cleanup | Deleted local ref after confirming no patch-unique content remained; remote ref was left untouched. | Local cherry-pick-aware comparison to current `origin/main`; clean worktree removal. | +| 2026-07-14 | claude/pt-audit-pr2-variant-early-exit | ddd67ca4a05e259e68a57f36a840d6521d8dfc0c | branch-cleanup | Deleted local ref after confirming no patch-unique content remained; remote ref was left untouched. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | claude/pt-audit-pr4-trust-copy | 46574ca1c93996505fada8c5610a62dbb11a90a5 | branch-cleanup | Deleted local ref after confirming no patch-unique content remained; remote ref was left untouched. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | claude/pt-audit-pt17-live-monitor | b5b5ab680d707fba05de5a15adf0ae77713e16d0 | branch-cleanup | Deleted local ref after confirming no patch-unique content remained; remote ref was left untouched. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | claude/pwa-optimization-plan-4b7c4f | a180fb23b886e440f4bf839bc89c2c5085f7f5c3 | branch-cleanup | Deleted local redundant ref after its clean inactive worktree was unregistered. | Exact-head ancestry and local worktree/activity scan. | +| 2026-07-14 | claude/repo-agents-evaluation-8a41cd | b8b484398557231ce4ce05693b784dc3bac16299 | branch-cleanup | Deleted local ref after confirming no patch-unique content remained. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | claude/repo-productivity-ideas-2e8b98 | 7ecade0b4e4ee611f8a5b5f168b2061f9f3370d7 | branch-cleanup | Deleted local ref after confirming no patch-unique content remained. | Local cherry-pick-aware comparison; clean inactive worktree removal. | +| 2026-07-14 | codex/eval-canary-quota-handling | 8fe1be6d0c58c60afeeb82f720b03c90ce57c2cf | branch-cleanup | Deleted local ref after confirming no patch-unique content remained; remote ref was left untouched. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | codex/performance-prompt-audit | 66883b7c86f606e617db4bee2bab6f85fff59bdc | branch-cleanup | Deleted local redundant ref after confirming no patch-unique content remained. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | claude/canary-latency-recalibration | c27d87c1a5cc02721dbcb9fbdf9e0229b4c62a38 | branch-cleanup | Retained: patch-unique content remains and no merge disposition was inferred. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | claude/dependency-report | dbf1a8dbae3cab8ef5dfe54bcdf157709d752579 | branch-cleanup | Retained: patch-unique content remains; its inactive worktree was removed without deleting the ref. | Local cherry-pick-aware comparison and reachability check. | +| 2026-07-14 | claude/medspacy-assertion-eval | 0ebe88bdc893f362f2793f8062d48656a3d70302 | branch-cleanup | Retained: patch-unique content remains and no merge disposition was inferred. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | claude/process-hardening-consolidation | 2ecd302920b94a75d6031b54f61a4d058ad44a25 | branch-cleanup | Retained: patch-unique content remains and no merge disposition was inferred. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | claude/remove-client-sentry | 8d54ddc980a0c883d1f8013e05aa1f96a85e622a | branch-cleanup | Retained: new patch-unique work appeared during the cleanup pass. | Final local ref refresh after `origin/main` advanced concurrently. | +| 2026-07-14 | claude/sentry-client-capture | beaab0bf2f0b1d27c6253004d400ac7be3ade19e | branch-cleanup | Retained: patch-unique content remains and a live shell references its worktree. | Local patch comparison, clean status, and path-referencing process scan. | +| 2026-07-14 | codex/database-productivity-pack | d25f495a03b96d328874eee3eb2e78863f7611ef | branch-cleanup | Retained because its checked-out worktree is dirty and task-backed, despite no unique committed patch remaining. | Worktree status and Codex task-registry scan. | +| 2026-07-14 | codex/dsm-diagnosis-mode | abba3c7d2909017f1691041c2caa11d9716c565e | branch-cleanup | Retained because its checked-out worktree is dirty and task-backed, despite no unique committed patch remaining. | Worktree status and Codex task-registry scan. | +| 2026-07-14 | codex/eval-canary-structured-errors | f8b543e6b22c2979aa64b60748f31a5ef31e87d3 | branch-cleanup | Retained because an idle Codex task still owns the clean worktree; no local or remote deletion was attempted. | Codex task-registry and worktree scan; zero-unique patch check. | +| 2026-07-14 | codex/formulation-workspace | 0696ded585ff9611e5a1325bc6e6c85d0c74bb50 | branch-cleanup | Retained because its checked-out worktree has uncommitted work. | Fresh worktree status and Codex task-registry scan. | +| 2026-07-14 | codex/global-answer-reliability | eb6160a140e1d785340f171a534a9d74da267179 | branch-cleanup | Retained: patch-unique content remains; the inactive clean worktree was removed without deleting the ref. | Local cherry-pick-aware comparison and reachability check. | +| 2026-07-14 | codex/lithium-answer-recovery-pr | 5bc19c665b1d9d9069485bb871d7ddb566858ccd | branch-cleanup | Retained: patch-unique content remains; the inactive clean worktree was removed without deleting the ref. | Local cherry-pick-aware comparison and reachability check. | +| 2026-07-14 | codex/openai-gpt56-rag-upgrade | 7e4b535fc53fe61ace561facdb8c7a224c18d86f | branch-cleanup | Retained: patch-unique content remains and an idle Codex task owns the worktree. | Local patch comparison plus Codex task-registry scan. | +| 2026-07-14 | codex/rag-canary-completion | b6a092fc9712efe6cb2849c219b29ce4fe0c71ee | branch-cleanup | Retained: patch-unique content remains; its detached inactive worktree was safely removed. | Local patch comparison and commit reachability check. | +| 2026-07-14 | codex/rag-performance-followups | fa0a6178fbbbb50de2544b4ec6cbd3f6cc9da0ae | branch-cleanup | Retained: patch-unique content remains and a Codex task still references the worktree. | Local patch comparison plus Codex task-registry scan. | +| 2026-07-14 | codex/railway-deploy-filters | 435274bb2a567272b3abf0519fa45a82ba6d797d | branch-cleanup | Retained: patch-unique content remains and no merge disposition was inferred. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | codex/release-blocker-remediation | 0696ded585ff9611e5a1325bc6e6c85d0c74bb50 | branch-cleanup | Retained because its active checked-out worktree has substantial uncommitted work. | Active Codex task and fresh worktree status scan. | +| 2026-07-14 | codex/specifiers-design | 65d8f533f23ca59190b1f7ed0ad86fd050381805 | branch-cleanup | Retained: patch-unique content remains and no merge disposition was inferred. | Local cherry-pick-aware comparison to current `origin/main`. | +| 2026-07-14 | codex/universal-search-mode-ranking | 0696ded585ff9611e5a1325bc6e6c85d0c74bb50 | branch-cleanup | Retained because its active checked-out worktree has uncommitted work and a live Node process. | Active Codex task, worktree status, and process scan. | +| 2026-07-14 | origin/claude/canary-latency-recalibration | c27d87c1a5cc02721dbcb9fbdf9e0229b4c62a38 | branch-cleanup | Retained: patch-unique content remains; remote mutation requires provider confirmation. | Offline remote-tracking comparison only; no fetch or GitHub query. | +| 2026-07-14 | origin/claude/codebase-index-coverage | 258782c8426541f43e03009ccf6bb27b9ce90ca5 | branch-cleanup | Remote deletion candidate: no patch-unique content remains, pending live PR/provider confirmation. | Offline remote-tracking comparison only; no fetch or GitHub query. | +| 2026-07-14 | origin/claude/dependency-report | dbf1a8dbae3cab8ef5dfe54bcdf157709d752579 | branch-cleanup | Retained: patch-unique content remains; remote mutation requires provider confirmation. | Offline remote-tracking comparison only; no fetch or GitHub query. | +| 2026-07-14 | origin/claude/design-elevation-e1e2 | b91437c9068b6dba2f25e831d360e2dbcbeeb75a | branch-cleanup | Remote deletion candidate: no patch-unique content remains, pending live PR/provider confirmation. | Offline remote-tracking comparison only; no fetch or GitHub query. | +| 2026-07-14 | origin/claude/design-sync-fixes-p1 | 8103c560fb7e69dcadb1155cf9feb706aa8a8517 | branch-cleanup | Remote deletion candidate: no patch-unique content remains, pending live PR/provider confirmation. | Offline remote-tracking comparison only; no fetch or GitHub query. | +| 2026-07-14 | origin/claude/docs-script-linter | 9f31fc5b62d4cd69cfe2ee92241d7e15e33d8de0 | branch-cleanup | Remote deletion candidate: no patch-unique content remains, pending live PR/provider confirmation. | Offline remote-tracking comparison only; no fetch or GitHub query. | +| 2026-07-14 | origin/claude/document-image-viewer-review-ox7t11 | b874d857acfb32ec635332967e94d5bbc96ca68c | branch-cleanup | Remote deletion candidate: no patch-unique content remains, pending live PR/provider confirmation. | Offline remote-tracking comparison only; no fetch or GitHub query. | +| 2026-07-14 | origin/claude/github-actions-codex-issue-f4t4s5 | 1f4cdd51b0dfb98495fc293bf511c167071a217c | branch-cleanup | Retained: patch-unique content remains; prior open-PR state was not refreshed without provider approval. | Offline remote-tracking comparison only. | +| 2026-07-14 | origin/claude/medication-alerts-database-cb8o83 | c3b95239fba1b523ef7796a8fca0ef6dc7a271d8 | branch-cleanup | Retained: patch-unique content remains and no merge disposition was inferred. | Offline remote-tracking comparison only. | +| 2026-07-14 | origin/claude/medspacy-assertion-eval | 0ebe88bdc893f362f2793f8062d48656a3d70302 | branch-cleanup | Retained: patch-unique content remains; remote mutation requires provider confirmation. | Offline remote-tracking comparison only. | +| 2026-07-14 | origin/claude/process-hardening-consolidation | 2ecd302920b94a75d6031b54f61a4d058ad44a25 | branch-cleanup | Retained: patch-unique content remains; remote mutation requires provider confirmation. | Offline remote-tracking comparison only. | +| 2026-07-14 | origin/claude/pt-audit-monitor-marker-fix | 7d41cbe5a42b9a7f90d15ad3e80cdca6596548e0 | branch-cleanup | Remote deletion candidate: no patch-unique content remains, pending live PR/provider confirmation. | Offline remote-tracking comparison only; local ref and worktree were removed. | +| 2026-07-14 | origin/codex/eval-canary-quota-handling | 8fe1be6d0c58c60afeeb82f720b03c90ce57c2cf | branch-cleanup | Remote deletion candidate: no patch-unique content remains, pending live PR/provider confirmation. | Offline remote-tracking comparison only; local ref was removed. | +| 2026-07-14 | origin/codex/eval-canary-structured-errors | f8b543e6b22c2979aa64b60748f31a5ef31e87d3 | branch-cleanup | Retained because an idle Codex task still owns the branch worktree, despite zero unique patch content. | Offline remote-tracking comparison plus Codex task-registry scan. | +| 2026-07-14 | origin/codex/global-answer-reliability | eb6160a140e1d785340f171a534a9d74da267179 | branch-cleanup | Retained: patch-unique content remains; remote mutation requires provider confirmation. | Offline remote-tracking comparison only. | +| 2026-07-14 | origin/codex/lithium-answer-recovery-pr | 5bc19c665b1d9d9069485bb871d7ddb566858ccd | branch-cleanup | Retained: patch-unique content remains; remote mutation requires provider confirmation. | Offline remote-tracking comparison only. | +| 2026-07-14 | origin/codex/openai-gpt56-rag-upgrade | 7e4b535fc53fe61ace561facdb8c7a224c18d86f | branch-cleanup | Retained: patch-unique content remains and an idle task owns the local worktree. | Offline remote-tracking comparison plus Codex task-registry scan. | +| 2026-07-14 | origin/codex/rag-canary-completion | b6a092fc9712efe6cb2849c219b29ce4fe0c71ee | branch-cleanup | Retained: patch-unique content remains; remote mutation requires provider confirmation. | Offline remote-tracking comparison only. | +| 2026-07-14 | origin/codex/rag-performance-followups | fa0a6178fbbbb50de2544b4ec6cbd3f6cc9da0ae | branch-cleanup | Retained: patch-unique content remains and a Codex task references the local worktree. | Offline remote-tracking comparison plus Codex task-registry scan. | +| 2026-07-14 | origin/codex/railway-deploy-filters | 435274bb2a567272b3abf0519fa45a82ba6d797d | branch-cleanup | Retained: patch-unique content remains; remote mutation requires provider confirmation. | Offline remote-tracking comparison only. | +| 2026-07-14 | origin/codex/specifiers-design | 65d8f533f23ca59190b1f7ed0ad86fd050381805 | branch-cleanup | Retained: patch-unique content remains; remote mutation requires provider confirmation. | Offline remote-tracking comparison only. | +| 2026-07-14 | main | aef020797b91a1e6f3e2584e3d7b12e29ea54046 | branch-cleanup | Protected local base retained and safely fast-forwarded to the latest locally observed `origin/main`. | Ancestry check; confirmed `main` was unattached before `git branch -f main origin/main`. | +| 2026-07-14 | origin/main | aef020797b91a1e6f3e2584e3d7b12e29ea54046 | branch-cleanup | Protected remote-tracking base retained; snapshot only, with no provider fetch performed. | Final locally observed remote-tracking ref after concurrent repo activity. | +| 2026-07-14 | codex/release-blocker-remediation | aef020797b91a1e6f3e2584e3d7b12e29ea54046 | branch-cleanup | Retained because its active checked-out worktree continued moving during the cleanup pass and still contains uncommitted work. | Active Codex task and final worktree/ref refresh; deletion prohibited. | +| 2026-07-14 | local merged-ref deletion batch (40 refs) | f0eec3ec504bdbaa2a82e2a3f86876c05925a6c2 | branch-cleanup | Deleted 40 non-checked-out local branch refs after exact-head revalidation showed each ref was the exact head of, or an ancestor of, merged PR work; no candidate changed or became checked out during deletion. | Fresh `git fetch --prune origin`; authenticated all-PR inventory; exact SHA guard; worktree guard; merged-PR reachability and cherry-pick-aware comparison to `origin/main`; `git branch -D` completed for all 40 candidates. | +| 2026-07-14 | origin merged-ref deletion batch (26 refs) | f0eec3ec504bdbaa2a82e2a3f86876c05925a6c2 | branch-cleanup | Deleted 26 origin branch refs whose current remote SHA exactly matched a merged PR head. No checked-out branch, open-PR head, or changed remote ref was included. | Authenticated `gh pr list`; `git ls-remote --heads origin`; exact remote-SHA, open-PR, and worktree guards immediately before three non-force `git push origin --delete` batches; all 26 deletions succeeded. | +| 2026-07-14 | fix/accessibility-remaining-findings | e6e735d2668f7383acc45bdb7cc7dc183e7a73a8 | branch-cleanup and merge-readiness | Retained. PR #654 is mergeable and its scoped accessibility diff had no high-confidence review finding, but the required UI regression check remains in progress and GitHub reports the PR blocked. | Authenticated PR metadata and check rollup; five-file diff review; mergeability and exact-head confirmation. No merge attempted. | +| 2026-07-14 | codex/release-blocker-remediation | 1ca2f9f372e23f563de0bc4f823cd341d82a562a | branch-cleanup and merge-readiness | Retained. PR #655 has green completed checks but currently conflicts with `main`; its branch remains checked out in an active worktree. | Authenticated PR metadata and check rollup; exact-head, worktree, and mergeability confirmation. No merge, rebase, conflict resolution, or branch deletion attempted. | | 2026-07-14 | HEAD (detached) 570e6ba56ae60bea56a32801b9cc96c5a8dfde4f | 570e6ba56ae60bea56a32801b9cc96c5a8dfde4f | clinical governance + RAG full-repo audit (source governance/citations, answer verification/clinical safety, privacy/query-privacy/private-search-scope, generation failure modes/degradation, retrieval/ranking/selection, ingestion/OCR index quality) | No high-confidence P0/P1. Fail-closed governance chokepoint (`buildGovernedAnswerClientResponse`) applies to both `/api/answer` and `/api/answer/stream`; numeric/quote/citation verification, prompt-injection neutralization, owner-scope tenancy, and query/answer redaction all conservative. Two P3 observations: (1) `secondStageScore` demotion penalties can be floored away by `Math.max(hybrid_score, boosted)` at the tail of the list (rag.ts:663); (2) `outdatedPenalty` default-ON uses governance metadata to weight ranking (eval-gated, demotion-only) — in tension with the "no governance weighting" principle but conservative. D4/D5 (#649) levers verified default-OFF with tests. | Pure review, no mutations except this ledger append. Offline: focused Vitest governance/verification/privacy/scope suites 79/79 + 98/98 passed. Provider-backed (Supabase/OpenAI), browser, release, and live retrieval-quality checks not run (confirmation boundary). | | 2026-07-14 | HEAD (detached) 570e6ba56ae60bea56a32801b9cc96c5a8dfde4f | 570e6ba56ae60bea56a32801b9cc96c5a8dfde4f | full repo-structure audit (broken imports, dead files, redundant config, module dependency, structural debt) | No P0/P1. P2: `RAG_TEXT_WEAK_OR_RELAXATION=true` in `.env.example` contradicts `default("false")` in `env.ts` (process-hardening hardened this to off); `reindex-eval-gate.ts` (488 lines) has no production importer — test-only orphan; `bundle-budget.json` still has `enforce: false` + `totalGzipBytes: null` after first production build window passed. P3: `client-env.ts` duplicates `isLocalNoAuthMode`/`publicUploadsEnabled` from `env.ts` using raw `process.env` (intentional server-only split, but divergent implementations); `OPENAI_PRICE_*`, `SPEND_ALERT_DAILY_USD` env vars undocumented in `.env.example`; `rag.ts` → extracted-module architecture still has acknowledged runtime back-edges in `rag-extractive-answer` but no import cycles detected by `architecture-boundaries.test.ts`; several `mockup`-named component files not removed from `src/components/` (production use gated via `mockupsEnabled()`). | `npm run verify:cheap` green (2,290 passed/2 skipped, 0 lint errors, typecheck clean, sitemap aligned, type-scale 0 hits, runtime Node 24/npm 11). `npm run check:env-parity` clean. `npm run docs:check-scripts` passed 266 refs. Architecture-boundaries suite (no cycles, server modules isolated, scripts not imported). Provider-backed (Supabase/OpenAI), browser, release, and live-eval checks not run (confirmation boundary). | | 2026-07-14 | HEAD (detached) 570e6ba56ae60bea56a32801b9cc96c5a8dfde4f | 570e6ba56ae60bea56a32801b9cc96c5a8dfde4f | RAG retrieval/ranking/selection/answer-generation audit (fresh scoped pass; PR #649 D4/D5 governance levers safe-by-default focus, token/effort waste, provider routing) | No P0/P1. Both #649 levers verified safe-by-default and fail-safe: D4 `unknownCurrentnessPenalty` default 0 (no-op, clamped non-negative, activated only via `RAG_RANKING_CONFIG`); D5 `NEXT_PUBLIC_RAG_TRUST_CAP_ALL_CLAIMS` unset=false (only tightens display trust high→medium, never exposes more; `NEXT_PUBLIC` correct as `buildAnswerRenderModel` runs client-side in `ClinicalDashboard.tsx`). Reasoning-effort defaults correct (`OPENAI_STRONG_REASONING_EFFORT`=medium, fast=low; `strongReasoningEffortForQueryClass` never raises, caps routine at medium, keeps dose/threshold at configured). Provider mode default `auto`. P3 (reaffirmed): (1) `Math.max(hybrid_score, boosted)` floor at rag.ts:663 can nullify demotion penalties (outdated/unknown/poor/lowIndex) at the list tail, making D4 partly inert when activated; (2) `document_status` defaults to `"unknown"` (source-metadata.ts:34) for unenriched docs, so activating D4 penalizes the corpus-wide fallback status, not a curated signal — same mechanism that dropped selection doc-recall@5 1.0→0.76 (retrieval-selection.ts:340) — eval gate is the safeguard. | Pure review, no mutations except this ledger append. Offline focused Vitest: answer-render-policy + ranking-config + answer-responsiveness-gate 54/54 passed. Provider-backed (Supabase/OpenAI), `eval:retrieval:quality`, browser, and release checks not run (confirmation boundary). |