Skip to content

test(#030): generalize the alias-slot disjointness guard + open #081#1215

Merged
cursor[bot] merged 8 commits into
mainfrom
cursor/alias-slot-disjointness-guard-6273
Jul 25, 2026
Merged

test(#030): generalize the alias-slot disjointness guard + open #081#1215
cursor[bot] merged 8 commits into
mainfrom
cursor/alias-slot-disjointness-guard-6273

Conversation

@BigSimmo

Copy link
Copy Markdown
Owner

Summary

Follow-up to #1204. The #30 contracts that landed there pin the admission/discharge pair by name, so the defect could return through a different alias tier or a future multi-slot case with nothing going red. Open PR #1196 is a live example: it re-adds "Admission to Discharge for Community Mental Health" and "Referral Admission and Discharge Mental Health Hospital in the Home" to wide-tier AdmissionCommunityPts, where both already sit on the Discharge tier.

  • Generalized alias-slot disjointness. Driven off ragEvalCases + answerQualityEvalCases, not hardcoded names: no expectation of a multi-slot case may share alias values with another slot of the same case. New multi-slot cases are covered automatically.
  • Table-independent structural guard. No single document may satisfy every slot of any multi-slot case, even when its text contains every expectation and alias. This holds regardless of what the alias tables say, so it stays meaningful if the tables are widened again — which keeps Harden document-mode smoke switching follow-up #80 a safe decision to revisit.
  • fix(api): owner-scope caller-supplied FKs in eval-cases + interaction… #81 opened in docs/outstanding-issues.md recording how to reconcile fix: remediate P2 audit findings (Phases 1 and 2) #1196: take main's admission-only list for eval-document-matching.ts, and treat its protected-RAG-surface conflicts (semantic-rerank.ts, rag/rag.ts, rag-route-budget.ts, scripts/eval-retrieval.ts) through the RAG flagging path rather than a mechanical rebase.

RAG impact: no retrieval behaviour change — test-only plus a ledger entry; no source file changes at all.

Verification

  • npm run verify:cheap — pass (3405 passed, 5 skipped)
  • Focused Vitest 32/32: tests/eval-document-matching.test.ts, tests/rag-eval-cases.test.ts
  • Fail-closed proof, regression shape 1 — simulating fix: remediate P2 audit findings (Phases 1 and 2) #1196's alias re-addition fails the new generalized contract (keeps the alias values of every multi-slot case's expectations pairwise disjoint) alongside the existing named one
  • Fail-closed proof, regression shape 2 — reverting expectedFileCoverage to pre-Potential fix for code scanning alert no. 1: Workflow does not contain permissions #30 matching fails the new structural contract (never lets a single document satisfy every slot of a multi-slot case) alongside the two behavioural ones
  • UI verification not run: no UI, routing, or styling change
  • Live evals / provider-backed gates not run: test-only offline change, and they require explicit approval

Risk and rollout

  • Risk: minimal — no source file is modified. The only way these contracts fail is if the invariants they encode are actually broken.
  • Rollback: revert 784a1420.
  • Provider or production effects: None.

Notes

Open in Web Open in Cursor 

cursoragent and others added 2 commits July 25, 2026 15:19
The existing contracts pin the admission/discharge pair by name, so a
future multi-slot case -- or a widening of a different alias tier --
could reintroduce the #30 defect without any test going red.

Drive both invariants off the real eval cases instead: no expectation
of a multi-slot case may share alias values with another slot of the
same case, and no single document may satisfy every slot of any
multi-slot case. The second holds independently of the alias tables,
so it stays meaningful if the tables are widened again.

RAG impact: no retrieval behaviour change -- test-only.

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
PR #1196 re-adds two admission-to-discharge titles to the wide-tier
AdmissionCommunityPts list, which would revert the #30 tightening. Its
other conflicts include protected RAG surfaces, so record how to
reconcile it rather than leaving that in chat context.

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.

@supabase

supabase Bot commented Jul 25, 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 ↗︎.

@coderabbitai

coderabbitai Bot commented Jul 25, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

@cursor[bot], you've reached your PR review limit, so we couldn't start this review.

Next review available in: 5 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

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 configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: e46ca576-eadc-49c8-a46f-82c87fdb4737

📥 Commits

Reviewing files that changed from the base of the PR and between 3dae971 and 406cf21.

📒 Files selected for processing (2)
  • docs/outstanding-issues.md
  • tests/eval-document-matching.test.ts
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch cursor/alias-slot-disjointness-guard-6273

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.

cursoragent and others added 6 commits July 25, 2026 15:23
…jointness-guard-6273

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
…uard-6273' into cursor/alias-slot-disjointness-guard-6273

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
…jointness-guard-6273

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
…uard-6273' into cursor/alias-slot-disjointness-guard-6273

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
@cursor
cursor Bot merged commit b2d794c into main Jul 25, 2026
18 checks passed
@cursor
cursor Bot deleted the cursor/alias-slot-disjointness-guard-6273 branch July 25, 2026 15:35
cursor Bot pushed a commit that referenced this pull request Jul 25, 2026
…ng check (#1229)

* docs(ledger): record prlanded outcomes for PRs #1204, #1215, #1220

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>

* docs(prlanded): compare trees against the squash commit, not three-dot main

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
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