first-principles-adversarial-review

first-principles-adversarial-review is a skill for Claude Code, Codex from Zhangs-11/zs-skills. It costs 52 tokens per session (1,584 once invoked), scanned A, original, MIT.

A reasoning method that starts from the real problem and checks conclusions by looking for evidence that could disprove them. It is designed to expose unchecked assumptions and overlooked cases.

In plain words
What is it for?
Use it when analysing causes, reviewing code or plans, designing systems, interpreting data, or making recommendations and trade-offs.
Why use it?
It helps prevent polished answers to the wrong problem and reduces the risk of accepting an early conclusion without testing it.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when analysing causes, reviewing code or plans, designing systems, interpreting data, or making recommendations and trade-offs.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/zhangs-11/zs-skills/first-principles-adversarial-review
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add Zhangs-11/zs-skills --skill first-principles-adversarial-review
Clone the repo
git clone --depth 1 https://github.com/Zhangs-11/zs-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for first-principles-adversarial-review

README.md
[![agentmods](https://agentmods.dev/badge/skills/zhangs-11/zs-skills/first-principles-adversarial-review/github.svg)](https://agentmods.dev/skills/zhangs-11/zs-skills/first-principles-adversarial-review)
Your own site
<a href="https://agentmods.dev/skills/zhangs-11/zs-skills/first-principles-adversarial-review"><img src="https://agentmods.dev/badge/skills/zhangs-11/zs-skills/first-principles-adversarial-review/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for first-principles-adversarial-review

Your own site · 80×15
<a href="https://agentmods.dev/skills/zhangs-11/zs-skills/first-principles-adversarial-review"><img src="https://agentmods.dev/badge/skills/zhangs-11/zs-skills/first-principles-adversarial-review.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 52 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,584 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00052 $0.01584
Opus 5 $0.00026 $0.00792
Sonnet 5 $0.00010 $0.00317
Haiku 4.5 $0.00005 $0.00158

Measured 4d ago against content hash c196fee63317, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

first-principles-adversarial-review scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

The scan reads SKILL.md. This mod also ships 3 executable files (evals/grade_evals.py, evals/run_codex_evals.sh, evals/run_trigger_stability.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

first-principles-adversarial-review/SKILL.md · 88 lines

How it starts

The opening of the file, as written. The whole thing — 88 lines — stays where its author put it; the contents beside it link to each section on GitHub.

第一性原理与对抗式审查

把本 Skill 当作推理和交付门禁,不作为固定回答模板。目标是避免沿用错误前提、过早相信初步结论,以及为未来可能性堆叠当前并不需要的设计。

两个视角

第一性原理从真实结果重新推导解法:区分事实、硬约束、可协商约束、惯例和假设;建立输入、状态、过程、输出、反馈和失败条件的最小闭环;追踪真实生产者、消费者、上下游、权限和集成点;再与项目已有同类实现及至少一个不推翻有效硬约束的替代方案比较。

对抗式审查假设初步结论可能是错的:把主张拆成可核验事实、由事实推出的解释或因果推断,以及取决于目标的价值判断;定位真正的事实源,主动寻找反例、遗漏路径、环境差异、异常恢复和相反证据。

对抗的目标是寻找最强反证,不是为了反对而制造分歧。

参考他人或其他 Agent 的结论前,先基于原始事实形成初步判断;以证据而非一致票数裁决分歧,已有结论无法避开时,明确其可能造成的锚定影响。

两者可以往返:先建立候选机制,再用反证攻击;发现反证后返回机制层重推,而不是替旧结论打补丁。

工作流

1. 定义本轮交付

明确要交付的是事实判断、根因、设计、修改、建议还是决策,并判断错误代价和动作可逆性。调查和评审不授权修改;发现问题也不自动授权删除、提交、推送、部署、外部通知或数据库写入。

2. 建立事实与机制

先定位会改变结论的事实源。涉及原因、需求、设计、实现、优化或复杂决策时,再追踪:

  • 成功最终表现为什么可观察结果?
  • 哪些事实已由当前事实源证实,哪些仍是假设?
  • 谁产生和消费输入,状态在哪里变化,结果如何反馈?
  • 入口、调用方、下游、持久化、缓存、权限、配置、兼容、监控、测试和运维中哪些确实受影响?
  • 项目已有同类实现和最小替代方案分别是什么?

穷举真实链路,不罗列没有路径支撑的低概率风险。

对会改变结论的不确定项,记录“待核验主张 → 最短核验动作 → 未验证时的结论限制”;能自查的先查,只向用户报告剩余关键缺口。

3. 证伪关键主张

对会驱动答案或动作的主张检查:

  1. 它是事实、推断还是价值判断?
  2. 运行时真正读取哪个字段、配置、分支、接口或状态?
  3. 代码、远端、依赖、规则、人员、部署和数据是否需要刷新?
  4. 什么观察会推翻结论,能否直接查询、复现或测试?
  5. 是否遗漏另一入口、消费者、权限角色、异步流程或恢复路径?
  6. 正常对照和已有实现是否支持当前查询方法?
  7. 建议是否会破坏既有不变量或把问题转移给其他消费者?

证据通常按以下顺序降级:可重复运行结果 > 当前事实源和运行时配置 > 最新实现及调用链 > 官方当前文档 > 项目文档与注释 > 历史和记忆 > 常识推断。无法验证时标注“推断,未验证”。

4. 按风险取证

  • 轻量:低风险且可逆,检查前提、事实源和最可能的反例。
  • 标准:影响方案、代码、时间或协作,追踪关键上下游、比较替代方案并验证主要反例。
  • 深入:生产、不可逆、安全、隐私、法律、财务或重大成本,使用独立证据覆盖失败路径,并在行动前说明剩余不确定性。

证据成本应与错误代价相称;低风险任务不做仪式化调查,高风险结论不以“看起来合理”代替验证。

设计与实现的消融门禁

每次完成设计或实现后、交付前,对本次新增内容自动做一次消融实验:

  1. 在内部列出新增的抽象层、接口、wrapper、helper、配置、扩展点、状态、兜底和分支,以及各自声称解决的问题。
  2. 每次移除或合并一项,形成更简单的候选;不要一次删多项,否则无法判断是哪一项产生影响。
  3. 设计任务用代表性 Case 重走目标、约束、生产者、消费者、状态和失败路径;实现任务比较公开行为、契约、相关测试和真实调用链,必要时再比较性能或复杂度指标。
  4. 按奥卡姆剃刀选择:同样满足必需行为和保护性约束时,采用未经验证的假设更少、机制更简单的候选,而非单纯代码更短的方案;只有能指出当前需求、契约、测试或实测收益的抽象才保留。

没有新增抽象时,确认无可消融项即可,不为完成流程制造候选。消融不是顺手重构:默认只处理本批新增或改动中的设计,不能借此删除既有函数、文件、注释或改变既有接口、数据和用户行为。涉及这些对象时,先列明目标和理由并取得授权。无法安全构造或验证候选时,保留基线并明确“必要性未验证”,不把猜测包装成简化结论。

形成答案或行动

先给经过审查的结论,再给足以支撑判断的证据、主要反证和仍未验证项。明确要求事实核查时,逐条区分:

  • 事实:已证实、基本成立但需收窄、存在争议、证据不足或明显错误。
  • 解释或因果推断:链路成立、部分成立或不成立,并指出缺口。
  • 价值判断:说明服务的目标、受益者、代价和结论反转条件。

Read the full file on GitHub · 88 lines

Files

What ships with it

7 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago Changed · -87 tokens per session c196fee63317
  2. 8d ago Changed · -48 lines · -33 tokens per session bcf697d82a31
  3. 12d ago First seen · 136 lines · 172 tokens per session scan A 5662dccd9ab3

Subscribe to this mod's changes

first-principles-adversarial-review is a skill published in the GitHub repository Zhangs-11/zs-skills (2 stars, last pushed 5d ago), licensed MIT. It adds 52 tokens to every session and 1,584 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.