tree-of-thoughts

tree-of-thoughts is a skill for Claude Code from nguyenthienthanh/aura-frog. It costs 80 tokens per session (1,702 once invoked), scanned A, original, MIT.

A structured reasoning method that explores several possible solutions, evaluates them, and drops weaker paths before continuing. It is useful when a problem has multiple branches rather than one obvious sequence.

In plain words
What is it for?
Use it to compare architecture options, plan multi-step refactors, investigate competing bug hypotheses, or reason through complex decisions.
Why use it?
It reduces the chance of committing early to a weak approach during architecture decisions, refactoring, or complex debugging.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

Needs its repository: it reads a path above its own folder, which exists only inside the repository. The line is Human-readable explanation: see [docs/architecture/HIERARCHICAL_PLANNING.md](../../../docs/architecture/HIERARCHICAL_PLANNING.md).

Part of the aura-frog plugin — 43 skills, 24 commands, 15 agents, 10 hooks, 6 MCP servers shipped together

Good fit Use it to compare architecture options, plan multi-step refactors, investigate competing bug hypotheses, or reason through complex decisions.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/nguyenthienthanh/aura-frog
agentmods
npx agentmods add skills/nguyenthienthanh/aura-frog/tree-of-thoughts

Made for: Claude Code.

Or install aura-frog, the plugin that ships this one along with the rest of its 43 skills, 24 commands, 15 agents, 10 hooks, 6 MCP servers.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for tree-of-thoughts

README.md
[![agentmods](https://agentmods.dev/badge/skills/nguyenthienthanh/aura-frog/tree-of-thoughts/github.svg)](https://agentmods.dev/skills/nguyenthienthanh/aura-frog/tree-of-thoughts)
Your own site
<a href="https://agentmods.dev/skills/nguyenthienthanh/aura-frog/tree-of-thoughts"><img src="https://agentmods.dev/badge/skills/nguyenthienthanh/aura-frog/tree-of-thoughts/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for tree-of-thoughts

Your own site · 80×15
<a href="https://agentmods.dev/skills/nguyenthienthanh/aura-frog/tree-of-thoughts"><img src="https://agentmods.dev/badge/skills/nguyenthienthanh/aura-frog/tree-of-thoughts.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 80 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,702 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 3 findings, up to medium

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • medium Agent Snooping · line 188
    Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.
    Fix: Remove all code or instructions that list or read other skills' files or directories. Skills should operate independently; cross-skill access is a privilege escalation.
  • medium Agent Snooping · line 189
    Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.
    Fix: Remove all code or instructions that list or read other skills' files or directories. Skills should operate independently; cross-skill access is a privilege escalation.
  • medium Agent Snooping · line 190
    Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.
    Fix: Remove all code or instructions that list or read other skills' files or directories. Skills should operate independently; cross-skill access is a privilege escalation.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00080 $0.01702
Opus 5 $0.00040 $0.00851
Sonnet 5 $0.00016 $0.00340
Haiku 4.5 $0.00008 $0.00170

Measured 8d ago against content hash e7d2860aae71, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

tree-of-thoughts scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

aura-frog/skills/tree-of-thoughts/SKILL.md · 191 lines

How it starts

The opening of the file, as written. The whole thing — 191 lines — stays where its author put it; the contents beside it link to each section on GitHub.

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.

Tree of Thoughts

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)


When NOT to Use

  • Linear problems (one obvious path)
  • Quick/Standard complexity — too expensive
  • User said just do: / must do:
  • Token budget projects >120K for workflow

Default Parameters

  • Breadth: 3 (branches per node)
  • Depth: 3 (levels deep)
  • Pruning threshold: evaluation score < 6/10 → prune branch
  • Max leaves: 9 before pruning, typically 3–5 after

The Protocol

Step 1 — State the root

Write the problem as a single question or goal:

"Refactor the auth service without breaking existing tokens"

Step 2 — Generate Depth-1 branches

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

Step 3 — Evaluate each (rubric)

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.

Step 4 — Expand surviving branches (Depth 2)

For each survivor, propose 2–3 sub-steps. Score again. Prune again.

Step 5 — Expand to Depth 3 (leaves)

For each sub-step, propose concrete actions. Score. Prune.

Step 6 — Pick winning leaf

Highest-scoring leaf is the final plan. Show the entire path (root → branch → sub-step → action).

Read the full file on GitHub · 191 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago First seen · 191 lines · 80 tokens per session scan A e7d2860aae71

Subscribe to this mod's changes

tree-of-thoughts is a skill published in the GitHub repository nguyenthienthanh/aura-frog (24 stars, last pushed 7d ago), licensed MIT. It adds 80 tokens to every session and 1,702 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

openspec-plus-apply

MANDATORY skill that activates whenever the OpenSpec apply phase begins. Triggers: /opsx-apply runs, the openspec-apply-change vanilla skill is referenced or active, openspec instructions apply is invoked, or the user asks to implement, apply, execute, or build out an OpenSpec change ('implement the change', 'apply…

sudokar/openspec-plus · 110 tokens

openspec-plus-spec

MANDATORY skill that activates whenever the OpenSpec specification phase begins. Triggers: /opsx-new or /opsx-continue runs; openspec-new-change, openspec-continue-change, or openspec-explore is active; openspec instructions spec or openspec instructions specs is invoked; or the user wants to create, update, review…

sudokar/openspec-plus · 88 tokens

openspec-plus-tdd

MANDATORY skill that activates whenever code is written to implement an OpenSpec change task. Triggers: openspec-plus-apply is active, /opsx-apply is running, the user is implementing tasks from an OpenSpec change, an implementer subagent dispatched by openspec-plus-apply is starting work, or the user invokes phrases…

sudokar/openspec-plus · 190 tokens

openspec-plus-proposal

MANDATORY skill that activates whenever the OpenSpec proposal phase begins. Triggers: /opsx-new or /opsx-continue runs; openspec-new-change, openspec-continue-change, or openspec-explore is active; openspec instructions proposal is invoked; or the user wants to create, update, review, refine, or discuss an OpenSpec…

sudokar/openspec-plus · 82 tokens

openspec-plus-tasks

MANDATORY skill that activates whenever the OpenSpec tasks phase begins. Triggers: /opsx-new or /opsx-continue runs; openspec-new-change, openspec-continue-change, or openspec-explore is active; openspec instructions tasks is invoked; or the user wants to create, update, review, refine, or discuss an OpenSpec tasks.md…

sudokar/openspec-plus · 84 tokens

implement-type-annotations

Add comprehensive type hints to Python/TypeScript code to improve IDE support, catch errors early, and enable better AI code understanding.

ambient-code/agentready · 30 tokens