Към всички skills

adversarial-review

basicmachines-co · Разработка

Cross-vendor adversarial code review of the current branch. Two different model families (Claude + Codex/GPT) review the diff independently, then try to refute each other's findings; survivors are reported by confidence. Runs from either Claude Code or Codex. Use when the user asks for an adversarial review, a cross-model / second-opinion review, or wants high-confidence findings before merging. Report-only — never auto-applies fixes.

Оригинален текст · няма потвърден превод на български

Теми: ai · claude · knowledge-management · knowlege-graph · llm · local-first · markdown · mcp · obsidian · obsidian-md · open-source · privacy-first · privacy-first-ai · productivity · python

Първо прочетете инструкцията.

Файлът се зарежда от посочения източник само по ваше действие. Можете да го прочетете тук, да го копирате или да го запазите като .md.

Оригинален SKILL.md
GitHub хранилище
Звезди на репото
4015
Лиценз
AGPL-3.0
Последна проверка на записа
21.09.2026 г.

Добавете в своя инструмент.

Командата отваря избора на skills от репозитория. Прочетете файла и условията на автора преди изпълнение.

npx skills add basicmachines-co/basic-memory

Страницата копира текст. Не инсталира и не изпълнява нищо на устройството ви.

Откъс от SKILL.md

Началото на файла на автора, без превод.

Adversarial code review

Two reviewers from different model families — Claude and Codex/GPT — review the same diff independently, then each tries to refute the other's findings. A finding's confidence comes from whether it survives that cross-examination. This kills the two failure modes of solo LLM review: self-ratification (a model won't critique its own work) and confident false positives.

You are the orchestrator — and one of the two reviewers

This skill runs from either Claude Code or Codex. First, identify which model family you are (Claude or Codex/GPT). Then:

  • You are reviewer #1. You review natively, in this session, using your own tools.
  • The other family is reviewer #2. You invoke it as a subprocess CLI for an independent pass: a fresh process, no shared context — that independence is the point.

The CLI for "the other model":

If you are…Invoke the other via…
Claudecodex exec (GPT)
Codexclaude -p (Claude)

Everything else in the flow is symmetric. Resolve the prompts/ and schemas/ paths below relative to this skill's own directory (where this SKILL.md lives).

Inputs

Two independent, optional inputs:

  • BASE — the ref to diff against. Default main.
  • SCOPE — a pathspec to narrow the review (e.g. src/basic_memory). Default: none (whole diff).

These are separate: a ref and a pathspec are not interchangeable. Build the canonical diff command once in preflight and reuse it everywhere below — never re-spell the diff inline (the scattered, inconsistent spelling is what broke earlier). Build it as an argv array, not a string, so a $SCOPE containing spaces or glob characters survives intact:

BASE="${BASE:-main}"
DIFF=(git diff "$BASE...HEAD")          # argv array — never a scalar string
[ -n "$SCOPE" ] && DIFF+=(-- "$SCOPE")  # pathspec stays one argument even with spaces
DIFF_STR=$(printf '%q ' "${DIFF[@]}")   # shell-quoted rendering, for embedding in a prompt

To run it, use "${DIFF[@]}" (quoted, no word-splitting). To embed it as text inside a subprocess prompt, use $DIFF_STR.

Preflight

Целият SKILL.md в GitHub