From 4511ca569242e51a0f9e109cb47fb96bfaee907d Mon Sep 17 00:00:00 2001 From: ejclaw Date: Tue, 7 Apr 2026 02:13:22 +0900 Subject: [PATCH] Clarify reviewer verification limits --- prompts/arbiter-paired-room.md | 2 ++ prompts/claude-paired-room.md | 2 ++ .../codex-runner/test/reviewer-runtime.test.ts | 18 +++++++++++++++++- 3 files changed, 21 insertions(+), 1 deletion(-) diff --git a/prompts/arbiter-paired-room.md b/prompts/arbiter-paired-room.md index 48af0bd..f620a39 100644 --- a/prompts/arbiter-paired-room.md +++ b/prompts/arbiter-paired-room.md @@ -34,6 +34,8 @@ You may receive reference opinions from external models appended to your prompt. ## Rules - Base your verdict on evidence (code, test output, logs), not on who said what first +- Distinguish reviewer snapshot limits from real product bugs. Reviewer workspaces may intentionally omit heavy artifacts like `node_modules`, `dist`, and `build`; inability to run direct local test/typecheck/build there is not, by itself, a blocker if dedicated verification evidence exists +- When verification evidence exists from the dedicated verification path, judge that evidence on its merits instead of requiring the reviewer to reproduce the same result from the lightweight reviewer snapshot - Your verdict is final for this deadlock cycle — after it, work resumes normally - You do NOT implement or review code — you only judge the disagreement - Keep your verdict concise — state the decision, the evidence, and the required action diff --git a/prompts/claude-paired-room.md b/prompts/claude-paired-room.md index e357773..8205400 100644 --- a/prompts/claude-paired-room.md +++ b/prompts/claude-paired-room.md @@ -30,6 +30,8 @@ Push back with evidence when the owner is wrong. Hold your ground when you are r ## Rules - Judge completion only by verification output. "It should work now" means run it. "I'm confident" means nothing — confidence is not evidence. "I tested earlier" means test again if code changed since. "It's a trivial change" means verify anyway +- Reviewer workspaces may intentionally exclude heavy runtime artifacts such as `node_modules`, `dist`, and `build`. Do not treat the inability to run direct local test/typecheck/build from the reviewer snapshot as a product bug by itself +- When test/typecheck/build evidence is needed, prefer the dedicated verification path (`run_verification`) over assuming the reviewer snapshot can execute the full project locally - Stagnation: **Spinning** (same error 3+), **Oscillation** (alternating approaches), **Diminishing returns** (shrinking improvement), **No progress** (discussion without change) — name the pattern and report: **Status**, **Attempted**, **Recommendation** - Implementation, commits, and pushes require agreement from both sides. Either can veto - Keep reviews concise — approve quickly when there is nothing to critique diff --git a/runners/codex-runner/test/reviewer-runtime.test.ts b/runners/codex-runner/test/reviewer-runtime.test.ts index 27f6f40..fb54d88 100644 --- a/runners/codex-runner/test/reviewer-runtime.test.ts +++ b/runners/codex-runner/test/reviewer-runtime.test.ts @@ -3,7 +3,7 @@ import fs from 'fs'; import os from 'os'; import path from 'path'; -import { describe, expect, it } from 'vitest'; +import { afterEach, beforeEach, describe, expect, it } from 'vitest'; import { assertReadonlyWorkspaceRepoConnectivity, @@ -11,6 +11,22 @@ import { isReviewerRuntime, } from '../src/reviewer-runtime.js'; +const ORIGINAL_UNSAFE_HOST_PAIRED_MODE = + process.env.EJCLAW_UNSAFE_HOST_PAIRED_MODE; + +afterEach(() => { + if (ORIGINAL_UNSAFE_HOST_PAIRED_MODE == null) { + delete process.env.EJCLAW_UNSAFE_HOST_PAIRED_MODE; + } else { + process.env.EJCLAW_UNSAFE_HOST_PAIRED_MODE = + ORIGINAL_UNSAFE_HOST_PAIRED_MODE; + } +}); + +beforeEach(() => { + delete process.env.EJCLAW_UNSAFE_HOST_PAIRED_MODE; +}); + function createTempRepo(prefix: string): string { const cwd = fs.mkdtempSync(path.join(os.tmpdir(), prefix)); execFileSync('git', ['init'], {