three-brain
Skill4 starsChanged 6 months agoMITView on GitHub
Auto-routes work to GPT-5.5 (Codex) or Gemini 2.5 Pro when the task fits their unique capabilities better than Claude alone. Claude stays the driver — the others are tools it calls.
- Reads credentials
4 other projects use a version of this, 1 of them edited.
Adopted by
Most recently taken up by
- jaron-goh-centr/claude-skillsedited, first seen Oct 11, 2026
- thiagofinch/mega-braintheir own version, first seen Oct 8, 2026
- jacobdcook/claude-skillstheir own version, first seen May 15, 2026
- zaka33333-hash/claude-skillstheir own version, first seen May 14, 2026
Other versions4 projects use a version of this.
Word for word · 0
None found.
Edited · 1
- jaron-goh-centr/claude-skills★ 019% same
Wrote their own version · 3
- thiagofinch/mega-brain★ 95same name
- jacobdcook/claude-skills★ 0same name
- zaka33333-hash/claude-skills★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository79 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- 21st-magicSkill
- alpacaSkill
- ask-mattSkill
- autoresearchSkill
- auto-stage-commitSkill
- browser-harnessSkill
- codebase-designSkill
- codeburnSkill
- codex-reviewSkill
- compact-memorySkill
- connect-recommendSkill
- connect-required-verification-informationSkill
- decision-mappingSkill
- delegate-taskSkill
- design-an-interfaceSkill
- design-mdSkill
- diagnosing-bugsSkill
- domain-modelingSkill
- edit-articleSkill
- extract-designSkill
- ffmpegSkill
- find-skillsSkill
- firecrawlSkill
- generateSkill
- git-guardrails-claude-codeSkill
- grillingSkill
- grill-me-codexSkill
- grill-meSkill
- grill-with-docs-codexSkill
- grill-with-docsSkill
- gwSkill
- handoffSkill
- implementSkill
- improve-codebase-architectureSkill
- kie-aiSkill
- lightragSkill
- llmfitSkill
- loop-meSkill
- migrate-to-shoehornSkill
- notebooklmSkill
- obsidian-vaultSkill
- openspaceSkill
- playwrightSkill
- prototypeSkill
- qaSkill
- request-refactor-planSkill
- resolving-merge-conflictsSkill
- reviewSkill
- roastSkill
- scaffold-exercisesSkill
- session-handoffSkill
- setup-matt-pocock-skillsSkill
- setup-pre-commitSkill
- site-teardownSkill
- skill-discoverySkill
- skilluiSkill
- spline-3dSkill
- stripe-appsSkill
- stripe-best-practicesSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
10 rules. 0 are common, 7 are distinctive, and 3 are very specific to this project.
0
Common
Most of the 3 edited versions we read keep these.
7
Distinctive
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 85
Before the first route fires in a session, verify the tooling.
- Very specific: line 92
If codex is missing → Codex routes unavailable.
- Very specific: line 94
If gemini is missing → Gemini routes unavailable.
- Distinctive: line 119
When invoking rescue, send full context: the failing output, what's been tried, the relevant files.
- Distinctive: line 163
Always demand timestamps, page numbers, or file:line citations in the output — don't accept a flat summary.
- Distinctive: line 198
Only when explicitly invoked: *"ask all three / before I commit to this / cross-architecture consensus."*
- Distinctive: line 200
All three answer the SAME question.
- Very specific: line 252
Prefer the plugin slash commands (/codex:review, etc.) when the calling context is interactive — they have prompt engineering baked in.
- Distinctive: line 256
Do not fire on:
- Distinctive: line 264
When uncertain: stay asleep.
“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Three-Brain Auto-Router
A single skill that routes work invisibly. Three brains, one terminal:
- Claude = builder, driver, IDE harness — stays in front of the user the whole time
- Codex (GPT-5.5) = reviewer, second brain, rescue
- Gemini 2.5 Pro = eyes, ears, long-context — handles anything Claude literally cannot see or hear
Startup self-check (run once per session, before first route)
Before the first route fires in a session, verify the tooling. If anything's missing, announce it once, fall back gracefully, and don't retry every turn.
codex --version 2>&1 | head -1 # expect: codex-cli 0.125+
gemini --version 2>&1 | head -1 # expect: 0.39+If codex is missing → Codex routes unavailable. Tell the user: "Codex CLI not found — review/rescue routes off until installed." Continue without those routes.
If gemini is missing → Gemini routes unavailable. Tell the user the same way. Continue without those routes.
Announcement protocol (REQUIRED for all forced routes)
Whenever the skill fires a route the user did NOT explicitly request — i.e. risk-path detection or failure-counter rescue — announce it in one line BEFORE running. The user must be able to interrupt with one word.
Format:
[three-brain] routing to Codex (adversarial-review) — risk path: src/auth/
[three-brain] handing off to Codex rescue — Claude failed same test 2× in a rowFor routes the user explicitly asked for ("yo check this") — no announcement needed. They asked, just do it.
Failure-detection rule (HARD)
This is a deterministic counter, not a vibe. After Claude attempts the same operation and fails:
- 2× same test failure on same code path → MUST invoke Codex rescue. Not optional. Announce it.
- 2× same error on same shell command → MUST invoke Codex rescue. Announce it.
- 2× same edit re-tried with no progress → MUST invoke Codex rescue. Announce it.
Reset the counter only when (a) the test/build passes, (b) the user changes the goal, or (c) the user explicitly says "keep trying."
When invoking rescue, send full context: the failing output, what's been tried, the relevant files. Use:
cat <context-bundle> | codex exec --skip-git-repo-check "rescue: [task]. Claude has tried 2x and failed. Full context attached."Gemini preprocessing contract
Long media must be prepped before sending to Gemini — raw 2-hour videos blow rate limits and produce noise.
Video pipeline:
# 1. Acquire (if YouTube URL)
yt-dlp -f "best[ext=mp4][height<=720]" "<url>" -o /tmp/three-brain/in.mp4
# 2. Cap duration (default: 120s for demos, 600s for analysis)
ffmpeg -t 120 -i /tmp/three-brain/in.mp4 /tmp/three-brain/clip.mp4 -y
# 3. Extract audio for transcript (parallel track)
ffmpeg -i /tmp/three-brain/clip.mp4 -vn -ac 1 -ar 16000 /tmp/three-brain/audio.wav -y
# 4. Send with explicit ask for TIMESTAMPED findings
gemini -p "Analyze frame-by-frame. Return findings as a timestamped list: [MM:SS] event. Cover: graphics, lower-thirds, transitions, on-screen text, speaker actions. Cap output at 800 words." @/tmp/three-brain/clip.mp4Audio pipeline: same as above without the video step.
PDF pipeline:
# Cap page count for very long docs
qpdf --pages input.pdf 1-100 -- /tmp/three-brain/doc.pdf 2>/dev/null || cp input.pdf /tmp/three-brain/doc.pdf
gemini -p "Extract: key claims, data tables, chart findings, page-numbered. Cap at 1000 words." @/tmp/three-brain/doc.pdfWhole-codebase scan:
# Use the plugin which handles directory packaging
/cc-gemini-plugin:gemini --dirs <comma-separated-paths> "Find every place X. Return file:line list."Always demand timestamps, page numbers, or file:line citations in the output — don't accept a flat summary.
Risk-path detection (path-based, not keyword-based)
Codex's review is forced — without the user asking — when an active edit touches any of these:
src/auth/** # authentication flows
src/billing/** # payments, subscriptions
**/migrations/** # DB schema changes
**/deploy/** # deployment scripts
**/.env* # env handling
**/secrets/** # credentials
**/policy/** # ACLs, permissions
infra/** # Terraform, k8s, IaC
**/Stripe* **/Plaid* # payment integrations
**/jwt* **/oauth* # token handlingKeywords alone (auth, payments, prod) in casual chat do NOT trigger forced review — it has to be an active edit on the file paths.
This avoids false positives on docs/comments/test fixtures, and false negatives on code that uses domain names like billingFlow or policy.ts instead of generic words.
Risk-by-reversibility rule
Even task verbs that normally don't fire (refactor/plan/explain/design) DO fire if the target is irreversible or high-blast-radius:
- "Refactor the auth middleware" → fires Codex review (auth path)
- "Plan the Stripe migration" → fires Codex review (billing + migration path)
- "Design the deployment pipeline" → fires Codex review (deploy path)
Verb is irrelevant if the target is risky.
Parallel consensus mode (high-stakes)
Only when explicitly invoked: "ask all three / before I commit to this / cross-architecture consensus."
All three answer the SAME question. Claude does not summarize a vibe-consensus — it forces structured output:
Recommendation: <one line>
Blocking risks: <bullet list>
Assumptions: <bullet list>
Confidence: low / medium / high
Tests required to verify: <bullet list>Each model returns this template. Claude diffs them: where they agree, where they disagree, and adjudicates by evidence, not by averaging.
Output filing
Anything the skill produces goes to ./three-brain-out/<YYYY-MM-DD>-<slug>/:
./three-brain-out/2026-04-27-alex-graphic/
├── input.txt # what the user asked
├── gemini-analysis.md # Gemini's output
├── claude-build.html # what Claude built
├── codex-review.md # Codex's review
└── log.md # one-line summary, datedAppend to ./three-brain-out/log.md (root-level) every time the skill runs:
[2026-04-27 16:24] route=video-build target=alex-clip duration=187s files=4That's the compounding ledger.
Calling pattern (Bash, since slash commands aren't issuable from inside a skill)
# Codex review
git diff | codex exec --skip-git-repo-check "Review this diff. Flag bugs, risks, missing tests. Be specific."
# Codex adversarial
git diff | codex exec --skip-git-repo-check "Adversarial review. Challenge the design. Find what's wrong. Prove it's broken."
# Codex rescue
cat <bundle> | codex exec --skip-git-repo-check "Rescue mode. Claude tried 2x and failed. Solve it from scratch."
# Gemini multimodal
gemini -p "<focused ask with output format>" @./file
# Gemini whole-codebase
/cc-gemini-plugin:gemini --dirs <paths> "<focused question>"Prefer the plugin slash commands (/codex:review, etc.) when the calling context is interactive — they have prompt engineering baked in. Fall back to the raw CLI when the slash commands are not available or when piping context.
Stay-asleep rules (explicit)
Do not fire on:
- Casual conversation, greetings, status checks
- Any question Claude can answer directly without external help
- "Recall / what did we decide / look up" → that's the
recallskill's job - "Save this / wrap up / log this" → that's
wrap-up's job - "What's my strategy on X" → that's
strategy-awareness - Any task already in another skill's territory
When uncertain: stay asleep. Under-firing is fine. Over-firing breaks trust.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

