AGENT SKILL

audit-review-fanout

Review a code change with several cheap reviewers, each given a different lens, then verify every finding before reporting it. The deliverable is verified defects only, each with its evidence; none found is a valid result. USE WHEN review this PR, review the diff, code review, review my changes, audit this change, check before merge, second opinion on code. NOT FOR proving a test can fail (test-strength), or the merge decision (gate-merge).

License 许可
Apache-2.0
最近更新
2026-11-15
Stars
★ 0
Forks
0

01 前言 Front Matter

name
audit-review-fanout
description
Review a code change with several cheap reviewers, each given a different lens, then verify every finding before reporting it. The deliverable is verified defects only, each with its evidence; none found is a valid result. USE WHEN review this PR, review the diff, code review, review my changes, audit this change, check before merge, second opinion on code. NOT FOR proving a test can fail (test-strength), or the merge decision (gate-merge).
architecture
code-review

02 资源文件 6

03 SKILL.md 正文

audit-review-fanout — distinct lenses, then verification

Done looks like: a findings list where every item is confirmed. It was either reproduced by a command, or the exact line is quoted beside the text or contract it breaks. Items are deduplicated and ordered most severe first. Each says whether it is fixed (a review fixes nothing unless asked: CONSTITUTION №5). Anything unconfirmed is listed separately as unconfirmed, never as a defect. No findings is a valid result.

Architecture: this skill is code-review in contracts/agent-architectures.tsv: review lens agents (haiku/medium), an audit verifier per finding (sonnet/medium), and a verify adjudicator (opus/high) only when two verifiers disagree. A lens never verifies; a verifier never raised the finding.

Why this shape: in the harbor#818 trial, a single reviewer of any tier found every planted defect. The extra real bugs came from different runs noticing different things. Copies of one prompt mostly repeat each other. Every added reviewer also adds false positives, and a false positive is a defect (№2.11), so the verify step is the half that makes the fan-out safe.

1. Scope

Get the diff and its file list: gh pr diff <N>, or git diff <base>...HEAD. Pick the tier. No tier is a single agent. Every tier runs at least one lens subagent, then a separate verifier subagent that did not raise the finding, then the merge (§3).

Tier Lenses Verify
quick (one-line or docs-only) the one lens that fits (docs: Contracts) one Sonnet verifier per finding
standard all six one Sonnet verifier per finding
deep (security-critical, or a verifier disagrees) all six two Sonnet verifiers per finding, so they can disagree (§5)

2. Lenses — one subagent each, in parallel, in waves of 5 at most

The six briefs are in lenses/ beside this file; each holds its question, rules and reply format.

Lens Brief The question it answers
Correctness lenses/correctness.md Wrong results, edge cases, broken callers
Failure handling lenses/failure-handling.md Errors swallowed, fallbacks that hide failure
Security and privacy lenses/security.md Injection, secrets, paths or identity leaking, egress, CONSTITUTION §3 and §4
Contracts lenses/contracts.md Code that contradicts its own comments, docs, usage text or CONTRACTS
Tests lenses/tests.md Would the tests fail if this change were reverted?
Surroundings lenses/surroundings.md Existing defects in the code the change touches

Every lens is subagent_type: general-purpose, model: haiku, effort: medium. No plugin is needed. Pass model always (context-rules/user/agent-model-required).

Restate every constraint in each brief. A rule that sits only in a skill is not followed; the same rule in the request is. Paste the lens brief into the prompt and add:

  • the diff (PR number or base ref);
  • read-only, change nothing;
  • report only real defects, and [] when there are none;
  • reply with only a JSON array (schema: contracts/finding.md, "The review-tier finding").

A lens that errors, runs out of turns or returns non-JSON is failed, never "none": re-run it once, then report the lens as failed.

3. Merge

Deduplicate yourself. Two findings are one when they name the same file, lines within ±2 of each other, and the same claim. Keep the strongest evidence and record every lens that raised it. Give each finding its raised_by (the lens agent id). This step also runs when no lens raised anything: the report then says none were found.

4. Verify — every finding, by an agent that did not raise it

One new subagent per finding (model: sonnet, effort: medium; batch up to 5 findings per agent when there are more than 10). A verifier is never a lens agent and never the agent that raised the finding: record its agent id beside the finding. The verdict is one of three:

  • CONFIRMED, with a command that reproduces it and its output, or the quoted line beside the quoted text it contradicts;
  • REFUTED, with the reason;
  • UNVERIFIABLE.

Only a CONFIRMED finding is a defect.

5. Escalate

Run the deep tier on a finding when it is security-critical, or when its verifier says UNVERIFIABLE. Deep means a second Sonnet verifier, independent of the first and given no verdict from it. If the two verdicts differ, opus adjudicates as a third subagent that raised and verified nothing. Record all agent ids.

6. Report

List confirmed findings, most severe first. Each one gives file:line, the claim, the evidence, the lens agent id, the verifier agent id(s), and FIXED / NOT FIXED. Then list the unconfirmed findings under their own heading. Then one line: lenses run (and failed), findings raised, confirmed, refuted.

Keeping it honest

This shape is not measured yet. After each review, add one row to #818: findings raised, confirmed, and whether a single Sonnet reviewer would have caught them. That comparison is a measurement only: the shipped skill has no single-agent path at any tier.

04 同仓库更多 Skills

VytCepas
VytCepas/harbor-core

systems-thinking

For a problem where the obvious fix has already failed or made things worse. The cause usually lives three or four layers below the events that keep appearing; this finds that structure, matches it against the ~10 known archetypes to get the canonical intervention, and checks second-order effects before you commit. Event-level fixes are what it exists to replace. USE WHEN systems thinking, causal loop, feedback loops, archetypes, leverage points, iceberg model, fix the system, why does this keep happening, recurring problem, second-order effects, the fix made it worse, this keeps coming back. NOT FOR incident causal chains (use root-cause-analysis).

★ 0
VytCepas
VytCepas/harbor-core

red-team

Adversarial analysis deploying parallel expert agents to stress-test ideas, strategies, and plans — decomposes into atomic claims, attacks them, then steelmans and counter-argues, producing severity-ranked findings with remediation. USE WHEN red team, attack idea, counterarguments, critique, stress test, devil's advocate, find weaknesses, break this, poke holes, strongest objection. NOT FOR collaborative debate to find best path (use council).

★ 0
VytCepas
VytCepas/harbor-core

first-principles

Physics-based reasoning framework (Musk methodology) that deconstructs a problem to irreducible fundamental truths, classifies every element as hard constraint, soft constraint, or assumption, then reconstructs the optimal solution from fundamentals alone. USE WHEN first principles, fundamental truths, challenge assumptions, real constraint, rebuild from scratch, start over, physics first, question everything, reasoning by analogy. NOT FOR structural feedback loops (use systems-thinking).

★ 0
VytCepas
VytCepas/harbor-core

company-help

Explains this laptop's safety settings in plain words: why a step was stopped, asked about or is waiting for an admin, where work files belong, and how to get a website allowed. USE WHEN a step is refused or blocked, a permission question appears, a site or download fails, or someone asks what Harbor is or where to save files. NOT FOR changing a setting: nobody here can.

★ 0
VytCepas
VytCepas/harbor-core

test-strength

Prove a load-bearing test can actually fail, and that it fails for the right reason. Break the thing it guards, watch it go red, restore — then check it stays green on a valid-but-unusual input, because red on a mutant proves discrimination, not correctness. USE WHEN a suite is written or changed, a guard is trusted, a gate reports zero, or a green result is about to be cited as evidence. NOT FOR reviewing a diff for defects (audit-review-fanout), or running a suite to see it pass (`bin/test-suite-run.sh`).

★ 0
VytCepas
VytCepas/harbor-core

status-suggest-scan

Runs the repeated-work scan and says in plain words what a person keeps doing by hand. USE WHEN a person asks what they repeat or what Harbor could take over. NOT FOR building what it finds.

★ 0