Skip to content

Add --adversarial falsification persona to the document bounce - #49

Merged
alanshurafa merged 1 commit into
masterfrom
claude/adversarial-review-coevolution-eb0348
Jul 9, 2026
Merged

Add --adversarial falsification persona to the document bounce#49
alanshurafa merged 1 commit into
masterfrom
claude/adversarial-review-coevolution-eb0348

Conversation

@alanshurafa

@alanshurafa alanshurafa commented Jul 9, 2026

Copy link
Copy Markdown
Owner

What

Adds an opt-in --adversarial reviewer persona to co-evolve-bouncer.sh. Until now the reviewer seat ran a one-line "be adversarial" role regardless of stakes. This gives the document pipeline a structured falsification method — premise challenging, assumption surfacing, decision stress-testing, simplification pressure, alternative blindness — vendored as a repo-owned template so the pipeline stays free of any plugin runtime dependency.

Two usage modes:

  • Cross-AI bounce (default): --adversarial runs the persona on the claude reviewer seat, codex composes the resolution.
  • Internal same-model: --adversarial --agents claude,claude runs it single-vendor, with a logged warning that same-model loses cross-vendor disagreement.

Design

  • Persona is orthogonal to run mode — no new mode value (the scorer's baseline logic keys off mode).
  • Composes with existing controls: --lens becomes a focus line appended to the persona; --chain swaps only the pass-1 critique stage (chain-critique-adversarial.md); defend/tighten untouched.
  • New additive reviewer_persona field (light/adversarial/lens) in state.json, via an optional 8th arg to init_bounce_state defaulting to light — other callers unaffected, scorer ignores it.
  • Adaptation from the compound-engineering adversarial-document-reviewer: dropped the peer-persona deferrals (no peer personas exist in this single-seat pipeline), emit [CONTESTED]/[CLARIFY] markers instead of JSON, kept depth calibration with per-pass finding caps to limit marker flooding.

Files

  • templates/co-evolve/role-reviewer-adversarial.md, chain-critique-adversarial.md — new persona templates
  • co-evolve-bouncer.sh — flag, template validation, usage(), build_reviewer_preamble branch, chain swap, REVIEWER_PERSONA + banner + same-model warning
  • lib/co-evolution.sh — optional reviewer_persona in init_bounce_state
  • evals/BOUNCE-RUNNER-CONTRACT.md, skills/co-evolution/SKILL.md, README.md, CLAUDE.md — docs
  • tests/adversarial-persona-simulation.sh — new 6-scenario sim

Verification

  • tests/run-all.sh: 33/33 suites (incl. new sim at 6/6); bounce-scorer regression 7/7.
  • Dogfooded live end-to-end on a seeded-flaw plan: cross-AI bounce reached convergence_status: converged with reviewer_persona: adversarial. Head-to-head against the compound-engineering persona (same model) matched its coverage of all 7 seeded flaws.

🤖 Generated with Claude Code

The reviewer seat only had a one-line "be adversarial" role, so a
high-stakes plan got the same shallow critique as a quick draft. This
adds an opt-in structured falsification persona (premise challenging,
assumption surfacing, decision stress-testing, simplification pressure,
alternative blindness), vendored from the compound-engineering
adversarial-document-reviewer so the pipeline stays plugin-free.

It composes with existing controls rather than replacing them: --lens
becomes a focus line, --chain swaps only the critique stage, and
--agents claude,claude runs it single-vendor as an internal review
(with a warning that same-model loses cross-vendor disagreement). The
persona is recorded in state.json as an additive reviewer_persona field
that the scorer ignores.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

@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: 73d17ce304

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

Comment thread co-evolve-bouncer.sh
# --adversarial swaps only the critique stage; defend/tighten keep
# their templates (the persona is a critique method, not a chain).
if [[ "$ADVERSARIAL" == "true" ]]; then
role_preamble=$(cat "$TEMPLATE_DIR/chain-critique-adversarial.md")

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Preserve the lens focus in chain adversarial mode

When users combine --adversarial --chain --lens <name>, the chain critique prompt is built directly from chain-critique-adversarial.md, so the lens-specific focus line added by build_reviewer_preamble is skipped. That makes the documented composition silently ignore the requested lens in the high-stakes chain mode, e.g. --lens security auditor produces a generic falsification prompt instead of a security-focused review.

Useful? React with 👍 / 👎.

@alanshurafa
alanshurafa merged commit 0d53f57 into master Jul 9, 2026
6 checks passed
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.

1 participant