feat(continual-learning): derive wasRealCollision from git overlap (RSI step 3)
Backend becomes authoritative for the verifier signal. recordOutcome now overrides the client-supplied wasRealCollision with deriveWasRealCollision(): a flagged collision counts as REAL only if BOTH named engineers currently have the collided file in their git changedFiles (getGitStates, 120s freshness TTL). Conservative false when the collision is orphaned/missing or git state is stale. Restores the (accepted x wasReal) 2x2 the spec assumes instead of the hardcoded 107/107 true. frontend/useInterventions.ts stops sending a hardcoded `true` (now a backend-overridden placeholder). Spec: continual-learning/spec.md:98-108, policy.md:35-42. backend+frontend typecheck + eslint pass. PLAN.md P0.5 rung 3 added. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -66,7 +66,9 @@ export function useInterventions(room: Room | null) {
|
||||
interventionId: active.id,
|
||||
collisionId: active.collisionId,
|
||||
podId: active.podId,
|
||||
wasRealCollision: true,
|
||||
// Placeholder only — the backend derives the authoritative value from
|
||||
// git overlap at outcome time (the client cannot know). (RSI Step 3)
|
||||
wasRealCollision: false,
|
||||
accepted,
|
||||
recordedAt: new Date().toISOString(),
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user