skills/tree-of-thoughts/SKILL.md
Explore multiple solution branches in parallel, evaluate each, and recommend the best path. Use when the user explicitly invokes /ideation tree-of-thoughts or asks for "tree of thought" / "branching exploration".
npx skillsauth add Thomashighbaugh/opencode tree-of-thoughtsInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Explore multiple distinct approaches to a problem in parallel, evaluate each against criteria, and recommend the best path forward.
Tree-of-Thoughts explores 3-5 branches simultaneously. Each branch requires multiple reasoning steps. This costs ~10× a normal API call. The user must explicitly confirm before proceeding.
/ideation tree-of-thoughtsShow warning — Present the cost warning to the user:
"Tree-of-Thoughts explores multiple solution branches in parallel. This costs ~10× a normal API call. Proceed? (yes/no)"
On confirmation — Identify the problem and generate 3-5 distinct approaches. Each branch should be genuinely different, not minor variations.
Explore each branch — For each approach:
Evaluate — Score each branch against:
Recommend — Rank the branches. State the best approach and why it outranks the alternatives. Acknowledge what's given up by not choosing the other branches.
Save — Write the exploration to .opencode/state/ideation/ for later
reference.
## Tree-of-Thoughts: [Problem]
**Branches explored:** N
| # | Approach | Feasibility | Impact | Risk | Cost | Rank |
|---|----------|-------------|--------|------|------|------|
| 1 | ... | High/Med/Low | High/Med/Low | High/Med/Low | High/Med/Low | 1st |
### Branch 1: [Name]
**Core idea:** [description]
**Pros:** [list]
**Cons:** [list]
**Assumptions:** [list]
### Branch 2: [Name]
...
### Recommendation
**Best approach:** [Branch X]
**Why:** [evidence-based justification]
**What's sacrificed:** [what the other branches offered]
**Saved to:** `.opencode/state/ideation/tree-of-thoughts-{topic}-{timestamp}.md`
tools
Create valid, type-safe TypeScript tools for OpenCode — generates correct boilerplate, typed interfaces, and handler stubs. Use when building new tools for global config or per-project .opencode/tools/.
testing
Run multiple independent reasoning passes and find consensus. Use when the decision is critically important, the stakes are high, or the user explicitly requests "run it multiple times" / "check consistency" / "self-consistency".
testing
Optimization by PROmpting — generate candidate prompt variations, test each against a benchmark, and report the best performer. Use when the user invokes /ideation opro or asks for "prompt optimization" / "OPRO".
development
Scan, validate, and auto-tag global OpenCode resources (skills, agents, rules, archetypes) for resource_tags filtering. Used by /init-project, config maintenance, and by stack-recommender for accurate mapping.