doubt-driven-development

Subjects non-trivial code decisions to adversarial fresh-context review before they stand.

Updated May 19, 2026
One-click install
npx skills add https://github.com/richardnguyen0715/agent-sharing --skill doubt-driven-development-richardnguyen0715
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: doubt-driven-development
Source: https://github.com/richardnguyen0715/agent-sharing/tree/main/.github/skills/doubt-driven-development
Command: npx skills add https://github.com/richardnguyen0715/agent-sharing --skill doubt-driven-development-richardnguyen0715

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Confident AI outputs are not always correct, and long sessions quietly turn assumptions into accepted facts. This Skill catches wrong decisions early by forcing every non-trivial decision through an adversarial fresh-context review while course-correction is still cheap. ## Core Features & Use Cases - Five-step doubt cycle: CLAIM the decision, EXTRACT the smallest reviewable artifact plus contract, DOUBT it with an adversarial reviewer, RECONCILE findings by precedence, and STOP within a bounded three-cycle loop. - Cross-model second opinions: Optionally escalate reviews to external CLI models like Gemini or Codex with read-only sandboxing, stdin piping, and explicit per-invocation user authorization. - Scope guardrails: Applies only to non-trivial decisions such as branching logic, cross-boundary changes, and irreversible operations, explicitly excluding mechanical edits and trivial changes. - Use Case: Before committing a new caching layer claimed to be thread-safe, extract the diff and its contract, hand them to a fresh-context reviewer with an adversarial prompt, classify the findings, and fix real issues before merging. ## Quick Start Ask the AI to apply doubt-driven development to review the thread-safety of the caching change you are about to commit.

Frequently Asked Questions about doubt-driven-development

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I verify AI-generated code before committing it?▼

Extract the diff and the contract it must satisfy, then hand them to a fresh-context reviewer with an adversarial prompt that asks it to find issues rather than validate. Classify each finding as actionable, trade-off, or noise before deciding.

What is the difference between doubt-driven development and code review?▼

Code review is a post-hoc verdict on a finished artifact like a pull request. Doubt-driven development is an in-flight posture that cross-examines individual non-trivial decisions while course-correction is still cheap, and the two are complementary.

When should I not apply adversarial review to a decision?▼

Skip it for mechanical operations like renaming or formatting, one-line changes with obvious correctness, reading or summarizing code, and pure tooling operations. The skill applies only to non-trivial decisions such as branching logic, cross-boundary changes, or irreversible operations.

Can I get a second opinion from a different AI model during review?▼

Yes, the workflow supports cross-model escalation through external CLIs such as Gemini or Codex. Each invocation requires a PATH check, a working-binary test, read-only sandboxing, stdin piping to avoid shell injection, and explicit user authorization.

Why does the reviewer not receive my original claim or reasoning?▼

Passing your conclusion biases the reviewer toward agreement, defeating the purpose of fresh-context review. The reviewer receives only the artifact and its contract so it independently determines whether the contract is satisfied.

What happens if the review loop keeps finding issues?▼

The loop is bounded at three cycles. If substantive issues remain after three cycles, that signals the artifact may not be ready or is too large, so escalate to the user or decompose the artifact rather than continuing to loop.