estimate_tokens
Estimates how many LLM tokens a file or directory will consume before loading it, helping you budget context and avoid oversized reads.
Instructions
Estimate how many LLM tokens a file or directory would cost before you load it.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "estimate_tokens"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | File or directory, default repo root | |
| exclude | No | Glob patterns to exclude | |
| include | No | Glob patterns to include, e.g. ['*.py', 'src/**'] |