tools-lsp-tree-sitter

tools-lsp-tree-sitter is a skill for Claude Code, Codex from alexei-led/architect. It costs 102 tokens per session (989 once invoked), scanned A, original, MIT.

A set of tools for finding definitions, references, callers, implementations, and syntax patterns in source code. A language server provides compiler-aware answers, while Tree-sitter parses code structure when that information is unavailable or unnecessary.

In plain words
What is it for?
It is for tracing calls and references, locating interface implementations, checking symbols and diagnostics, and finding functions or declarations by syntax.
Why use it?
It supports evidence-based claims about how code is connected instead of relying only on text searches. This helps confirm real coupling, boundary relationships, and compiler diagnostics.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit It is for tracing calls and references, locating interface implementations, checking symbols and diagnostics, and finding functions or declarations by syntax.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/alexei-led/architect/tools-lsp-tree-sitter
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 alexei-led/architect --skill tools-lsp-tree-sitter
Clone the repo
git clone --depth 1 https://github.com/alexei-led/architect

Made for: Claude Code, Codex.

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 tools-lsp-tree-sitter

README.md
[![agentmods](https://agentmods.dev/badge/skills/alexei-led/architect/tools-lsp-tree-sitter/github.svg)](https://agentmods.dev/skills/alexei-led/architect/tools-lsp-tree-sitter)
Your own site
<a href="https://agentmods.dev/skills/alexei-led/architect/tools-lsp-tree-sitter"><img src="https://agentmods.dev/badge/skills/alexei-led/architect/tools-lsp-tree-sitter/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 tools-lsp-tree-sitter

Your own site · 80×15
<a href="https://agentmods.dev/skills/alexei-led/architect/tools-lsp-tree-sitter"><img src="https://agentmods.dev/badge/skills/alexei-led/architect/tools-lsp-tree-sitter.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 102 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 989 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.
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.00102 $0.00989
Opus 5 $0.00051 $0.00495
Sonnet 5 $0.00020 $0.00198
Haiku 4.5 $0.00010 $0.00099

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

Security

Grade A, and why

tools-lsp-tree-sitter 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 9d 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.

src/skills/tools-lsp-tree-sitter/SKILL.md · 102 lines

How it starts

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

LSP and tree-sitter

A language server resolves symbols the way the compiler does: it knows the real definition, every reference, the implementations of an interface, and the diagnostics the toolchain reports. tree-sitter parses syntax without resolution — fast, language-agnostic, but it cannot tell you what a name resolves to. Reach for LSP when you need semantic truth; fall back to tree-sitter when no server is configured.

Evidence dimensions: semantic (LSP) and structural (tree-sitter).

When to use

Use LSP to confirm a real call/reference relationship before claiming coupling, to find every implementation of a boundary interface, to verify callers/callees at a seam, and to surface compiler diagnostics. Use tree-sitter syntax queries when LSP is unavailable or when the question is purely syntactic (find all functions, all type declarations) and a server would be overkill.

Commands

LSP access depends on the runtime's LSP integration; use only exposed runtime operations, and do not invent tool names. Operations to request:

definition <file>:<line>:<col>     # where a symbol is defined
references <file>:<line>:<col>     # every use of a symbol
implementations <symbol>           # implementors of an interface/abstract type
diagnostics <file|workspace>       # compiler/linter diagnostics
documentSymbols <file>             # outline of one file
workspaceSymbols <query>           # find a symbol across the project

tree-sitter syntax queries (no resolution, pattern over the parse tree):

# Function definitions (Python grammar)
tree-sitter query func.scm src/**/*.py

# Inline: capture all class declarations
tree-sitter parse src/foo.py            # inspect the tree to write a query

A .scm query file holds the capture patterns; run it across the target files.

Evidence output

Record:

  • dimension: semantic for LSP, structural for tree-sitter.
  • source: operation, file:line:col or query file, and project/build context.
  • facts: definitions, references, implementations, diagnostics, symbols, or syntax matches.
  • limits: missing server, non-building project, partial workspace, or syntax-only fallback.

Read the full file on GitHub · 102 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. 9d ago First seen · 102 lines · 102 tokens per session scan A 0c60b4f80cdc

Subscribe to this mod's changes

tools-lsp-tree-sitter is a skill published in the GitHub repository alexei-led/architect (2 stars, last pushed 1mo ago), licensed MIT. It adds 102 tokens to every session and 989 once invoked, about $0.0005 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-08-31.

Related

Other skills, from other repositories