Skip to content

docs(#100): record that the incremental evidence browser proof already exists - #2545

Merged
BigSimmo merged 10 commits into
mainfrom
claude/incremental-evidence
Sep 3, 2026
Merged

docs(#100): record that the incremental evidence browser proof already exists#2545
BigSimmo merged 10 commits into
mainfrom
claude/incremental-evidence

Conversation

@BigSimmo

@BigSimmo BigSimmo commented Sep 2, 2026

Copy link
Copy Markdown
Owner

Summary

  • The scope this issue recorded is already finished on main. #100's ledger row (2026-08-21) says both incremental-evidence flags default false and that the remaining offline work is browser proof of the client render path. docs/verified-answer-incremental-delivery-design.md, updated six days later, records Phase 1 as shipped with both flags defaulting ON, and names tests/answer-progress-ui-smoke.spec.ts as closing that browser-proof gap.
  • Verified, not assumed. src/lib/env.ts declares RAG_INCREMENTAL_EVIDENCE_PREVIEW with .default("true"), and src/lib/client-env.ts returns value !== "false", so an unset NEXT_PUBLIC_RAG_INCREMENTAL_EVIDENCE_PREVIEW_RENDER renders the rail. The .env.example line is commented because unset means ON, not because the default is off.
  • Ran the proof that exists rather than writing a second one. Both browser tests pass here — result below.
  • Corrected a stale doc comment in src/components/clinical-dashboard/answer-status.tsx, which still told readers the preview "is off by default, so today the line and the prose placeholder are the whole wait". That contradicted src/lib/client-env.ts and would have misled the next person to touch the component.
  • Queued an immutable ledger correction narrowing #100 to the two things that genuinely are uncovered, with the distinction between them stated: the false rollback is inlined at build time and ClinicalDashboard calls the gate with no argument, so a browser assertion needs a second build and may be right to leave at unit level; the danger-level source-governance suppression in src/lib/answer-preview.ts is a server-only gate, and the browser spec drives the rail through a mocked SSE stream, so no Playwright test can observe it at all — that gap is route-level, not browser-level.

This PR ships no new product code. Its value is the accuracy of the record, so every claim in it is cited to a file and line and was checked against the tree.

Verification

  • npm run ensure — dev server started; the printed URL was used, no port assumed.
  • Browser proof, run in this container against a production Playwright server, tests/answer-progress-ui-smoke.spec.ts, chromium:
  ✓  1 [chromium] › tests/answer-progress-ui-smoke.spec.ts:623:5 › the sources arrive during the wait and hand over to the answer's own rail (7.1s)
  ✓  2 [chromium] › tests/answer-progress-ui-smoke.spec.ts:685:5 › the arriving sources are paced apart, and are simply present when motion is suppressed (3.6s)

  2 passed (12.4s)
  • npm run check:ledger-write-disciplineLedger write discipline passed for 45a3dcacb54a..HEAD.
  • npm run check:outstanding-issues[snapshot] in step with data/outstanding-issues-snapshot.json
  • npm run format — run, and the result is committed.
  • Reviewed by the rag-retrieval-reviewer subagent on this diff before push. It audited every file:line citation in the comment, the inbox record and the commit message; all resolved. Its two accuracy notes (a citation pointing at the governance call's arguments rather than the suppression itself, and the browser-vs-route framing of the residual gap) were both applied before this push, because a merged inbox record is immutable.

Note the spec does not match tests/ui-*.spec.ts, which is why earlier ui-* searches missed it. playwright.config.ts names it explicitly in both productionSpecPattern and testMatch, so it runs in verify:ui and in the full release matrix.

UI verification not run: npm run verify:ui in full was not run. The only source change is a block comment, which cannot alter rendering, and the two journeys that exercise the changed component's own surface were run directly and are quoted above.

The pr-policy classifier was run offline against this diff's real file list and returns clinicalRisk: false, operationalRisk: false, ragRanking: false, migration: false, ui: true, so no governance preflight section is required.

Risk and rollout

  • Risk: low. One block comment and two documentation records; no executable behaviour changes, and no migration.
  • Rollback: revert the single commit. Nothing is applied anywhere by merging it.
  • Provider or production effects: None.
  • RAG impact: no retrieval behaviour change — a ledger correction, a comment fix, and a run of browser proof that already existed; no retrieval, ranking, selection or answer-generation code is touched.

Notes

Do not merge this PR yet. It is a draft and is labelled hold and do-not-merge.

Approval still needed, and from whom: nothing for this PR's own content — it carries no migration, no provider call, and no behaviour change, so it is the one of these four that is technically merge-safe on its own. It is held only because this session was asked to leave all four for the owner (Josh) to review together. Josh is the approver.

Out of scope and still outstanding: the provider-backed Phase 2 acceptance gates in docs/verified-answer-incremental-delivery-design.md, which need his approval and provider spend.

After this lands, npm run issues:reconcile applies the queued inbox record to the canonical ledger from its own serialized branch.

🤖 Generated with Claude Code

https://claude.ai/code/session_01N8JUuufwbFHy8PsgbztmGN


Generated by Claude Code


Note

Low Risk
Documentation and comment-only changes with no runtime, API, or RAG behavior changes.

Overview
This PR updates the outstanding-issues inbox for #100 so the ledger matches what is already on main: incremental evidence preview flags default on, the UI journey in tests/answer-progress-ui-smoke.spec.ts already exercises the render path, and the remaining gaps are narrowed to offline work (mocked /api/answer route test for danger-level governance suppression) rather than incorrectly labeling that check provider-backed. It cancels superseded inbox records that carried the wrong provider claim or dangling references, in favor of one consolidated self-contained update.

The only code touch is a comment fix in answer-status.tsx on AnswerProgress: it no longer says the preview rail is off by default and instead documents that NEXT_PUBLIC_RAG_INCREMENTAL_EVIDENCE_PREVIEW_RENDER is on unless set to false, consistent with src/lib/client-env.ts.

Reviewed by Cursor Bugbot for commit edc784b. Configure here.

…y exists

The 2026-08-21 ledger row for #100 said both incremental-evidence flags default
false and that the remaining offline scope was verify:ui proof of the client
render path. Three of its statements are no longer true.

Both flags default ON, not off. src/lib/env.ts:225-228 declares
RAG_INCREMENTAL_EVIDENCE_PREVIEW with .default("true"), and
src/lib/client-env.ts:18-22 returns `value !== "false"`, so an unset
NEXT_PUBLIC_RAG_INCREMENTAL_EVIDENCE_PREVIEW_RENDER renders the rail. The
.env.example line is commented because unset means ON.
docs/verified-answer-incremental-delivery-design.md records Phase 1 shipped and
enabled by default on 2026-08-27.

The browser proof already exists and was run here:
tests/answer-progress-ui-smoke.spec.ts:623 and :685, chromium, 2 passed
(12.4s). That spec does not match tests/ui-*.spec.ts, which is why earlier
ui-* searches missed it; playwright.config.ts names it explicitly in both
productionSpecPattern and testMatch, so it runs in verify:ui and the full
release matrix.

So this change does not build a browser proof. It records the one that exists,
narrows the open item to the two things that genuinely are uncovered, and
corrects the AnswerProgress doc comment, which still told readers the preview
is "off by default".

On the two residual gaps, the record is deliberately precise about what kind of
coverage each one needs. The `false` rollback is inlined at build time
(client-env.ts:16) and ClinicalDashboard.tsx:1933 calls the gate with no
argument, so a browser assertion of it needs a second build and may be right to
leave at unit level. The danger-level source-governance suppression
(answer-preview.ts:40) is a server-only gate, and the browser spec drives the
rail through a mocked stream, so no Playwright test can observe it at all —
that gap is route-level, not browser-level.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01N8JUuufwbFHy8PsgbztmGN
@coderabbitai

coderabbitai Bot commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Team

Run ID: f9670196-3214-40a3-bde0-c03a1ce25911


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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@supabase

supabase Bot commented Sep 2, 2026

Copy link
Copy Markdown

This pull request has been ignored for the connected project sjrfecxgysukkwxsowpy because there are no changes detected in supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@BigSimmo
BigSimmo marked this pull request as ready for review September 2, 2026 05:58
@cursor

cursor Bot commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_f9a215d1-8cd3-4d58-85c2-1b5ebe0fc6ba)

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 98d33813ed

ℹ️ 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".

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 2, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-02T06:14:14.448220Z 98d3381 Manual request
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@BigSimmo

BigSimmo commented Sep 2, 2026

Copy link
Copy Markdown
Owner Author

@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 claude/incremental-evidence at starting commit 98d3381; 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:claude/incremental-evidence, 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.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Already looking forward to the next diff.

Reviewed commit: 98d33813ed

ℹ️ 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".

…ce suppression proof

Raised in review on PR #2545 and verified before acting on it.

The earlier record on this branch said closing the danger-level source-governance
suppression gap needs a real /api/answer stream over a danger-governed corpus,
and is therefore provider-backed. That is wrong in the direction that matters: it
would have parked an offline clinical-safety regression check behind approval and
provider spend.

docs/verified-answer-incremental-delivery-design.md places that exact fixture in
Phase 0 and states the phase is provider-free. The route is already reachable
offline -- tests/answer-stream-preview-order.test.ts drives the /api/answer stream
route with the RAG pipeline, public access context and Supabase admin client all
vi.mock'd -- so a route-level suppression fixture needs no provider.

Records are immutable, so this is a new superseding request rather than an edit
to the existing one. The remaining scope is restated as two offline items; Phase 2
acceptance stays provider-gated.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01N8JUuufwbFHy8PsgbztmGN
@cursor

cursor Bot commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_386b94f1-483b-413a-913a-848ac16beb53)

Static PR checks went red on 2650515: docs:check-links runs the ledger inbox
planner, and the branch carried two pending mutations for #100 -- the original
update and the correction layered on top of it -- which the planner refuses
without an explicit cancellation decision. That is the tool working as designed;
a delta record is the wrong shape here, because an update's detail replaces the
field wholesale rather than appending, so the correction would have landed a
detail whose 'everything else in the earlier update stands' pointed at a record
that had itself been superseded.

Both pending records are cancelled with reasons, and one consolidated,
self-contained #100 update replaces them. Its content is the earlier record's,
with the provider-backed claim about the danger-level governance suppression
proof corrected -- that fixture is Phase 0 and provider-free, and the stream
route is already driven with mocked dependencies in
tests/answer-stream-preview-order.test.ts.

Reproduced the exact CI failure locally with LEDGER_WRITE_BASE_SHA set to the
base sha from the failing run, then confirmed the same command passes:
'docs link check passed: 4789 repo path references resolve.'

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01N8JUuufwbFHy8PsgbztmGN
@BigSimmo
BigSimmo enabled auto-merge (squash) September 2, 2026 09:17
@BigSimmo
BigSimmo disabled auto-merge September 2, 2026 10:17
@cursor

cursor Bot commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_d6ceb4bd-a693-4fbe-8fa7-c6c1a3f8929d)

@cursor

cursor Bot commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_826e99c6-1c5e-4364-81ad-7469de493f63)

@cursor

cursor Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_f343d0f7-dcb0-4a3c-bbda-5b7049c8de01)

@cursor

cursor Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_0cdb4a25-28a0-41e0-a205-b2cc7851537b)

@BigSimmo
BigSimmo enabled auto-merge (squash) September 3, 2026 09:40
@BigSimmo
BigSimmo merged commit 9df92aa into main Sep 3, 2026
33 checks passed
@BigSimmo
BigSimmo deleted the claude/incremental-evidence branch September 3, 2026 09:43
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.

2 participants