← Back to Pull requests

Report the caller gate of every key-gated relation #246

Open
unknown opened this pull request with 140 lines diff across 1 files
View on GitHub
unknown unknown commented on Nov 22, 2026 20:20 UTC
Author

A relation gated on the caller's own value fills its records with the typed wildcard and puts the row's side of the comparison in the record's context, so the context key is the only part of a record that says whom it grants. That key was reported only inside RowDecision::RequestGated, which #240 rightly stopped producing for gates whose records travel as a Joined or WholeShape query. Since then no output names the key for those relations, and a consumer reading a replayed grant or withdrawal back can only take the wildcard at face value and treat it as reaching everyone.

RelationShapes now carries caller_gate, a CallerGate holding the context key, the request parameter and the comparison, for every relation one gate source fills, whatever decides its records. Clock-gated shares get it too, since their records carry the grantee under the same key and never had a decision either. RowDecision::RequestGated holds the same CallerGate in place of its three loose fields, so the decision and the relation entry cannot disagree, at the cost of a mechanical migration for code matching on those fields.

Diff: 140 lines (+105 / -35) across 1 files Reviewer: github-actions[bot] Review duration: 2m
All Vouch review confidence checks passed
Residual risk 0.20 = Change Risk (0.33) × (1 − Review Confidence (0.38)). Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.33 · 140 lines diff across 1 files
0.33
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 1 substantive comment(s)
0.02
Model 3 · Review Timing & Attention
Session adequacy: 64% · Reviewer familiarity: 35%
37%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Shallow Review Depth shallow_review_depth
0.344
Diff Size diff_size
0.296
Real PR Conversation Timeline
1 comments
"Review active on #246"
general weight: 0.35
Assignees
Unassigned
Labels
risk: low confidence: 37.8% reviewed
Vouch Risk Breakdown
AI-powered review risk analysis
Change Risk
Change Risk · Model 1 (XGBoost)
Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
Score: 32.6% (LOW) · Higher = larger blast radius
32.6%
Review Confidence
Review Confidence · Models 2 & 3
Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
Score: 37.8% · Lower = rushed or shallow review
37.8%
Residual Risk
Residual Risk · Core Equation
Residual = Change × (1 − Confidence)
Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
Score: 20.3% · Safe to merge
20.3%