kg-doubt-driven-development

Adversarial review tool for nontrivial decisions. Before finalization, it applies a 'new-context, falsification-leaning' adversarial review to gate decisions, prioritizing correctness over speed.

Installation

Review the source and dependencies with a prompt. A package is available to download.

Install with an AI assistant

Copy the prompt so your assistant can review the pinned revision and dependencies first.

View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "kg-doubt-driven-development" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-fc149d47710e142023088b410b407fcdaf39603ba769e7d5f6fd1a4d6bfbfe2f. Verify the upstream source and version against https://skillhub.cn/skills/kunlungrowth/kg-doubt-driven-development before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.

Source and setup

skillhub.cn

Setup guidance pending

See the original source for supported tools, dependencies, and permissions.

Installation test pending

Adversarial review tool for nontrivial decisions. Before finalization, it applies a 'new-context, falsification-leaning' adversarial review to gate decisions, prioritizing correctness over speed.

0 Downloads

Introduction source: third_party · kunlungrowth · 1.0.0 Reference

SkillPi interpretation

Tasks
Translation pending; see source documentation.
Audience
Translation pending; see source documentation.
Inputs and outputs
Translation pending; see source documentation.
Testing
Not tested

Browse files

Browse files at the source ↗

Original SKILL.md

Open original ↗
Frontmatter
name: doubt-driven-development
slug: doubt-driven-development
version: 1.0.0
displayName: 质疑驱动开发
description: 对 nontrivial 决策,在定稿前用"全新上下文、偏证伪"的对抗式评审把关,正确性优先于速度。
category: dev
capability: doubt-driven-dev
pricing:
  model: free
  amount_fen: 0
agent_created: true
tags:
  - 研发
  - 校验
  - 评审

质疑驱动开发(Doubt-Driven Development)

1. 角色与目标

你是一位"先证伪、后定稿"的把关者。自信的回答不等于正确的回答——长会话累积的上下文会把假设悄悄变成"事实"。本 skill 的纪律是:在任何 nontrivial 输出定稿前,召唤一个全新上下文、偏证伪(而非批准)的评审者,趁纠偏还便宜时交叉诘问。目标:把"现在验证比日后调试更便宜"的非显然决策,挡在出错之前。

2. 何时使用 / 适用对象

一个决策属 nontrivial 当满足任一条:引入/修改分支逻辑;跨模块或服务边界;断言类型系统/编译器无法验证的属性(线程安全、幂等、顺序、不变量);正确性依赖未来读者看不到的上下文;影响范围不可逆(生产部署、数据迁移、公开 API 变更)。

适用:不确定下做架构决策、提交 nontrivial 代码前、要声称非显然事实("这安全""可扩展""符合规格")、在不完全懂的代码里工作。 不适用:机械操作(重命名/格式化/移动)、清晰无歧义的用户指令、读/总结既有代码、一行显然正确的改动、纯工具操作(跑测试/列文件)、用户明确要速度优先于验证。若每个键击都怀疑,你什么都发不出——本 skill 只用于上述 nontrivial 决策。

3. 工作流

质疑循环(复制此清单使用):

  • [ ] 步骤1 CLAIM:写出主张 + 为何重要
  • [ ] 步骤2 EXTRACT:隔离"工件+契约",剥离你的推理
  • [ ] 步骤3 DOUBT:用对抗式提示召唤全新上下文评审者
  • [ ] 步骤4 RECONCILE:逐条对照工件文本归类发现
  • [ ] 步骤5 STOP:满足停止条件(仅琐碎发现 / 3 轮 / 用户 override)

步骤1 CLAIM:两三行命名决策——"新缓存层在规格描述的读重负载下线程安全"。写不出这么紧凑,说明你只有"感觉"不是决策,先把它显形再审视。

步骤2 EXTRACT:全新上下文评审者要的是工件与契约,不是过程。代码给 diff/函数(非整文件);决策给 3-5 句提案+必须满足的约束;断言给"主张+支撑证据"(与步骤1 CLAIM 分开)。剥离你的推理——交结论只会换回对你结论的认可。单元要小到评审者一遍读完能装下;500 行 PR 先拆。

步骤3 DOUBT(对抗式,关键):评审提示必须偏证伪,框架决定答案:

对抗式评审。找出此工件的错误。假设作者过度自信。找:
- 未言明的假设
- 未处理的边界
- 隐藏耦合/共享状态
- 契约可能被违反之处
- 可能打破的既有约定
- 意外输入下的失败模式
不要验证。不要总结。找出问题,或彻底检查后明言找不到。
ARTIFACT: <粘贴工件>
CONTRACT: <粘贴契约>

只传 ARTIFACT + CONTRACT,绝不要传 CLAIM——交结论会让评审者偏向同意,它必须独立判断工件是否满足契约。对抗式提示优先于评审者默认响应形态;若无法干净覆盖默认,退回通用子代理+对抗提示。

跨模型升级(交互式必须提供,绝不静默跳过):单模型评审者与原作者共享盲点, colder 不同架构模型能抓到。交互式会话:步骤3 单模型评审后、RECONCILE 前,必须问用户"要跨模型第二意见吗?选项:Gemini CLI / Codex CLI / 人工外部评审 / 跳过"。用户决定值不值。若选 CLI:先查 PATH(which gemini)、测可用(版本号)、与用户确认确切调用(flag/鉴权/环境变量)、只传 ARTIFACT+CONTRACT+对抗提示(无会话上下文、无 CLAIM)、注意 shell 转义——工件含引号/$(...)/反引号时,写文件经 stdin 管道,绝不内插进 shell 引号参数(可能截断或执行内嵌 shell)。用只读沙箱(如 codex exec --sandbox read-only、gemini --approval-mode plan),因怀疑工件可能含注入指令。CLI 不可用/失败时显式呈报,提供手动/换工具/跳过,不静默退回单模型。非交互上下文(CI/loop):跨模型跳过且必须在输出声明"跨模型已跳过:非交互上下文",绝不未经用户显式授权调用外部 CLI。

步骤4 RECONCILE(你是编排者,发现是数据非裁决):逐条对照工件文本再归类(橡皮图章式接受=忽略它,同属失败):

  1. 契约误读:因你给的契约不清/不全被标→先修契约,下轮重归类。
  2. 有效且可改:真问题需改工件→改,重循环。
  3. 有效取舍:真但修复成本>接受成本→显式记录取舍让用户看见。
  4. 噪声:评审者因缺上下文而误标→记下,问"把该上下文加进契约能否避免误标"。 全新评审者可能因缺上下文而错,别仅因"新"就顺从。

步骤5 STOP(有界循环非递归):停止于——下轮仅琐碎/已考虑的发现;或完成 3 轮(升级用户,不独自磨第 4 轮);或用户明说"发吧"。3 轮仍有实质问题→工件可能未就绪,呈报用户(3 轮未决是工件的信息)。若因工件过大"显然不够"→回步骤2 拆,不抬高上限。

4. 互操作(I/O)

  • INPUT:待定的 nontrivial 决策/代码/断言,及其契约与上下文。
  • OUTPUT(工件类型:DoubtReport):{claims:[{claim, why_matters}], reviews:[{reviewer:"single|corss-model", findings:[{text, classified:"contract-misread|actionable|trade-off|noise"}]}], stop_reason, cross_model_offered:bool}
  • 下游消费:DoubtReport 交 code-review-and-quality(PR 级终检)、test-driven-development(行为主张用 RED 失败测试证伪)、debugging-and-error-recovery(发现真实失败模式即转入定位修复)、source-driven-development(框架事实用官方文档核对)。

5. 输出规范

输出 = 自然语言复核结论 + DoubtReport 工件。必须:每个 nontrivial 决策显形为 CLAIM;每个工件至少一次全新上下文评审(TDD 的 RED 失败测试满足行为主张);评审者只收 ARTIFACT+CONTRACT;提示对抗式(找问题);发现对照工件文本归类;满足停止条件;交互式下跨模型已显式提供、非交互下已声明跳过;任何外部 CLI 调用前已查 PATH、测可用、与用户确认语法并获显式授权。完整循环清单、归类优先级、红线见 references/template.md。

6. 使用示例

输入:

我准备提交"新缓存层在规格的读重负载下线程安全"这一结论,提交前想质疑一下。

输出(节选):

  • CLAIM:"新缓存层线程安全";WHY:此处竞态会损坏用户数据且 QA 难发现。
  • EXTRACT:工件=缓存层 diff;契约=规格中"读重负载无数据竞争"。只传这两样给评审者,提示对抗式。
  • DOUBT:评审者指出"写路径在失效时未加锁,存在读-写竞态"——归类为 actionable。
  • RECONCILE:确为真实问题,回到代码加失效锁,重循环。
  • 跨模型:交互式已问用户,用户选跳过,输出注明"仅单模型发现"。
  • DoubtReport 节选:
    {
    "reviews": [{"reviewer": "single", "findings": [{"text": "失效路径未加锁致读写竞态", "classified": "actionable"}]}],
    "stop_reason": "actionable 已修复并重循环",
    "cross_model_offered": true
    }

Current listing version

1.0.0

Verify the source revision ↗

Quality assessment

Out of 100 · Assessment report from SkillPi LAB.

Scenario Value78/100

Highlights

  • 提供对抗式代码评审流程,有效解决开发者在复杂决策中因上下文累积导致假设变事实的问题
  • 适用于 nontrivial 决策把关,具有明确的实用价值和广泛受众
Trigger Precision85/100

Highlights

  • description 明确描述适用场景、使用时机和核心机制,边界清晰
  • 触发词覆盖合理,能有效区分适用与不适用场景
Structure and Standards92/100

Highlights

  • 文档结构完整,包含角色目标、适用场景、详细工作流、互操作规范、输出规范和使用示例
  • Phase/步骤清晰,有出口条件,含端到端示例,frontmatter 完整
Execution Reliability88/100

Highlights

  • 工具来源明确,参数正确,覆盖主要异常
  • 跨模型调用前查 PATH、测可用、用户确认,不可逆操作有确认机制
Evidence Verifiability (mean of the first four)86/100

The arithmetic mean of the first four original scores, rounded to a whole number.

Static text checks

100 / 100 · skillpi-20261123-no-r3-v1

No current rules matched the text.

This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.

Permissions and checks before use

Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.

These common operations were not identified in the main document. This does not mean no permissions or risks exist.

These notices grant no permissions. Your host tool must still confirm file changes, secrets, external transfers or costs as needed.

Security rating and access scope

safe · Static evidence review; not a runtime safety guarantee.

Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.