tree-sitting

tree-sitting is a skill for Claude Code from oaustegard/claude-skills. It costs 184 tokens per session (844 once invoked), scanned A, original, MIT.

A code-navigation tool that reads a project's syntax tree to locate functions, classes, definitions, references, and file symbols. A syntax tree is a structured representation of source code.

In plain words
What is it for?
Use it to find where a symbol is defined, what a file exposes, what a directory contains, or where a name is used.
Why use it?
It helps you find the relevant parts of a codebase without manually searching through every file or relying only on text matches.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the code-intelligence plugin — 5 skills shipped together

Good fit Use it to find where a symbol is defined, what a file exposes, what a directory contains, or where a name is used.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/oaustegard/claude-skills/tree-sitting
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add oaustegard/claude-skills --skill tree-sitting
Clone the repo
git clone --depth 1 https://github.com/oaustegard/claude-skills

Made for: Claude Code.

Or install code-intelligence, the plugin that ships this one along with the rest of its 5 skills.

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-sitting

README.md
[![agentmods](https://agentmods.dev/badge/skills/oaustegard/claude-skills/tree-sitting/github.svg)](https://agentmods.dev/skills/oaustegard/claude-skills/tree-sitting)
Your own site
<a href="https://agentmods.dev/skills/oaustegard/claude-skills/tree-sitting"><img src="https://agentmods.dev/badge/skills/oaustegard/claude-skills/tree-sitting/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-sitting

Your own site · 80×15
<a href="https://agentmods.dev/skills/oaustegard/claude-skills/tree-sitting"><img src="https://agentmods.dev/badge/skills/oaustegard/claude-skills/tree-sitting.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 184 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 844 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 pass 7 Sept 2026
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.00184 $0.00844
Opus 5.5 $0.00074 $0.00338
Sonnet 5.5 $0.00037 $0.00169
Haiku 4.5 $0.00018 $0.00084

Measured 1mo ago against content hash bec0e0ab9018, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

tree-sitting 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 1mo ago.

The scan reads SKILL.md. This mod also ships 11 executable files (scripts/build_grammars.py, scripts/engine.py, scripts/server.py, …), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

plugins/code-intelligence/skills/tree-sitting/SKILL.md · 62 lines

How it starts

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

tree-sitting

Tree-sitter symbol index over a local checkout. Every result carries line ranges, so the next step is a scoped Read.

Setup

Needs Python 3.10+ and pip install tree-sitter. On macOS, /usr/bin/python3 is 3.9 and will not work; use a Homebrew or uv Python. Grammars are bundled for Linux x86_64 (parsers/*.so) and macOS (parsers/*.dylib).

If a file's grammar doesn't load, the file is skipped and stderr prints WARNING: no grammar for … with the fix. Resolve that before trusting an empty result. On other platforms, run python3 scripts/build_grammars.py (needs git and cc). It writes to $TREESIT_PARSERS_DIR, or ~/.cache/tree-sitting/parsers/ when that is unset, and grammars there take precedence over the bundle. Installed tree-sitter-<lang> wheels are the last fallback.

Use

scripts/treesit.py in this skill's directory scans the repo on every call (cached on disk; invalidated when files or grammars change), prints a tree overview, then answers the queries. Batch queries so one scan serves them all.

python3 scripts/treesit.py REPO                                   # overview, depth 1
python3 scripts/treesit.py REPO --path=src/core --detail=full     # drill in
python3 scripts/treesit.py REPO --no-tree 'find:Parser*' 'source:parse_input' 'refs:ParseState'
Query Returns
find:PATTERN[:KIND[:LIMIT]] symbols by name, substring or glob
symbols:FILE every symbol in a file
source:SYMBOL[:FILE] the symbol's source
refs:SYMBOL[:LIMIT] textual references
imports:FILE a file's imports
dir:PATH directory overview

Flags: --depth N (-1 = all), --detail sparse|normal|full, --path DIR, --skip DIRS, --no-tree, --stats, --no-cache, --rebuild-cache. scripts/engine.py exposes CodeCache for use inside one Python process.

Languages: Python, JavaScript, TypeScript/TSX, Go, Rust, Ruby, Java, C, HTML, Markdown (heading outline), Mojo. Other languages get generic extraction if their tree-sitter-<lang> wheel is installed.

Read the full file on GitHub · 62 lines

Files

What ships with it

37 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 1mo ago Changed · -158 lines bec0e0ab9018
  2. 2mo ago First seen · 220 lines · 184 tokens per session scan A a6cc93ecb944

Subscribe to this mod's changes

tree-sitting is a skill published in the GitHub repository oaustegard/claude-skills (395 stars, last pushed today), licensed MIT. It adds 184 tokens to every session and 844 once invoked, about $0.0007 per session on Opus 5.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

tree-sitting compared with skills from other repositories

tree-sitting next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
tree-sittingoaustegard/claude-skillsSkill395todayMITA184Claude Code
aisense-free-toolsaisenseapi/aisense-free-public-rest-apisSkill13d agoMITA50Claude Code, Codex
aisense-toolsaisenseapi/aisense-free-public-rest-apisSkill13d agoMITA87Claude Code
handoff-by-caiokaragos/ai-skills-by-caioSkill27mo agononeA120Claude Code, Codex
scenario-zbrush-expertscenario-labs/skillsSkill3.8kyesterdayMITA124Claude Code
customer-journey-mapmohitagw15856/pm-claude-skillsSkill1.6ktodayMITA86Claude Code, Codex
feature-prioritisationmohitagw15856/pm-claude-skillsSkill1.6ktodayMITA103Claude Code, Codex