No slash command · from archon-os
Uses tree-of-thoughts and chain-of-thought reasoning for architecture decisions, refactor planning, and complex debugging with branch evaluation and pruning.
Ships in archon-os. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
AI-consumed reference. Optimized for Claude to read during execution. Human-readable explanation: see docs/architecture/HIERARCHICAL_PLANNING.md or docs/getting-started/ depending on topic.
For problems with a branching solution space where some paths become clearly weaker as you explore.
Governed by: rules/workflow/tree-of-thoughts.md (when / why)
just do: / must do:Write the problem as a single question or goal:
"Refactor the auth service without breaking existing tokens"
Propose 2–3 high-level approaches:
Branch A: Big-bang rewrite, feature-flag rollout
Branch B: Strangler fig — new code alongside old, migrate routes one by one
Branch C: Adapter layer — new interface wrapping old implementation
For each branch, score 0–10 on:
| Criterion | Weight | Score |
|---|---|---|
| Feasibility with current team | 30% | /10 |
| Token/implementation cost | 20% | /10 |
| Rollback safety | 25% | /10 |
| Preserves existing tokens (constraint) | 25% | /10 |
Total = weighted sum. Prune any branch < 6/10.
For each survivor, propose 2–3 sub-steps. Score again. Prune again.
For each sub-step, propose concrete actions. Score. Prune.
Highest-scoring leaf is the final plan. Show the entire path (root → branch → sub-step → action).
## Plan: [winning leaf]
**Path:**
1. [Root]: Refactor auth without breaking tokens
2. [Branch B — strangler fig] (8.5/10)
3. [Sub-step B2 — route-by-route migration starting with read-only endpoints] (9/10)
4. [Action B2.3 — migrate GET /users, GET /sessions first; POST endpoints last] (9/10)
**Pruned:**
- Branch A (big-bang rewrite): rollback safety 3/10, feasibility 5/10
- Sub-step B1 (all-at-once migration): rollback safety 4/10
**Risks:** [any surviving concerns from pruned branches]
ToT is especially useful for debugging. Each branch is a hypothesis.
Root: "Login fails intermittently in production, works locally"
├── Branch A: Session store issue → score 7/10
│ ├── A1: Redis connection pool exhausted → score 8/10 ← EXPAND
│ └── A2: Cookie domain mismatch → score 5/10 (pruned)
├── Branch B: Load balancer sticky session → score 4/10 (pruned)
└── Branch C: Clock drift in JWT validation → score 6/10
└── C1: Server NTP misconfigured → score 7/10
Winning leaf: A1 (Redis pool exhausted)
Verification: Check Redis CONFIG GET maxclients + monitor pool stats
Full tree search is not always worth its cost. When there is one plausible path and the work is ordered analysis rather than choosing between genuinely different approaches, drop the branch/prune machinery and run a single ordered chain of thoughts. This is the cheaper mode — reach for it first, escalate to the full tree only when real alternatives appear.
Use linear mode when: the problem needs structured exploration before a solution, but the branches would be cosmetic (see Anti-Patterns) — e.g. tracing one bug's root cause, walking a performance investigation, or laying out a refactor whose sequence is clear. Triggers: sequential thinking, step by step reasoning, structured thinking, revise reasoning.
Use the full tree instead when: there are 2+ genuinely different approaches to weigh, or debug hypotheses that fan out and need scoring/pruning.
Thought 1/N: [Initial analysis — observations, assumptions]
Thought 2/N: [Build on previous — deeper analysis, connections]
Thought 3/N [REVISION of 1]: [Correct earlier assumptions — what was wrong, corrected view]
Thought 4/N [BRANCH A]: [Alternative angle, if one genuinely appears — trade-offs]
Thought 5/N [FINAL]: [Synthesize solution — recommended approach, key decisions]
A linear chain is still adjustable — a mid-chain BRANCH is the moment to consider
whether you've actually crossed into tree territory.
use_cases[5]{scenario,thoughts}:
Architecture design,5-8
Bug root cause,3-5
Performance optimization,4-6
Security analysis,5-7
Refactoring strategy,4-6
Use linear mode for problems requiring exploration before solution. Not for straightforward tasks — those need neither mode.
rules/workflow/tree-of-thoughts.md — policyrules/workflow/self-consistency.md — vote-based technique; ToT is structured searchskills/chain-of-verification/SKILL.md — verify the ToT winning leaf's factsskills/bugfix-quick/SKILL.md — uses ToT for hypothesis trees (debugging merged into bugfix-quick in v3.5)skills/refactor-expert/SKILL.md — uses ToT for refactor planningWhat SKILL.md sets; muted values are Claude Code's defaults
architecture decision with branching, refactor planning, debug hypothesis tree, reason: tot, deep complexity multi-step design, sequential thinking, step by step reasoning, structured thinking, revise reasoning
highnpx claudepluginhub nguyenthienthanh/archon --plugin archon-os45 skills in this plugin
/agent-detectorCRITICAL: MUST run for EVERY message. Detects agent, complexity, AND model automatically. Without this, tasks route to wrong agents and use wrong models, degrading quality and wasting tokens./api-designerDesigns RESTful APIs with endpoint naming, versioning strategies (URL path, header-based), pagination (offset and cursor), error response schemas, and OpenAPI conventions. Use when the user asks about REST API design, creating endpoints, URL structure, API versioning, status codes, Swagger, or OpenAPI specs./bugfix-quickFast bug fixes with root cause investigation + TDD. Enforces 'no fix without root cause' discipline and verification protocol. Without this skill, fixes are applied at symptoms instead of sources, and bugs return./chain-of-verificationDraft → generate verification questions → answer independently via tools → revise. Catches hallucinated facts in reports and reviews. MANDATORY for Phase 4 security/test claims. Paper: Dhuliawala et al. 2023./code-mapReverse-dependency lookup — "I am about to change this file, what breaks?" Use when assessing the blast radius of an edit, finding every importer of a module (including the ones that never name it), or checking what the startup code-map digest was derived from. Not for finding text: grep is better at that./code-reviewer8-aspect evidence-based code review/audit (security, correctness, compatibility, architecture, error handling, test gaps, type safety, simplicity) built on Google eng-practices, OWASP Top 10:2025, CWE Top 25, SemVer. Every finding needs file:line + a concrete failure scenario. Use when the user asks to review/audit code, check a PR, review before merge, in TDD Phase 4, via /check review or /run review.Other plugins' skills for the same job