use-blz

A coding helper that searches locally cached documentation stored in llms.txt files and returns matching passages with citations.

In plain words
What is it for?
Use it to add documentation sources, search for topics, retrieve passages with surrounding context, and browse a source’s heading structure.
Why use it?
It avoids repeatedly searching full web pages and gives the agent smaller, locally available pieces of documentation to use as evidence.

Agent

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.

agentmods
npx agentmods add agents/outfitter-dev/blz/use-blz
Clone the repo
git clone --depth 1 https://github.com/outfitter-dev/blz
Per session 23 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,574 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00023 $0.01574
Opus 5 $0.00012 $0.00787
Sonnet 5 $0.00005 $0.00315
Haiku 4.5 $0.00002 $0.00157

Measured 2d ago against content hash 784da6a12dce, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

use-blz 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 2d 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.

docs/agents/use-blz.md · 145 lines

How it starts

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

Use the blz CLI to keep documentation local, search it in milliseconds (P50 ≈ 6ms), and return grounded spans with exact citations. Keep payloads lean so agents spend fewer tokens per query compared to traditional page-level search.

TL;DR

blz add bun https://bun.sh/llms.txt -y              # Add source
blz query "test runner" --json                       # Search
blz get bun:41994-42009 -C 5 --json                 # Retrieve with context
blz query "error handling" -H 2,3 --context all --json  # Filter headings + expand section
blz map bun --tree -H 1-2 --json                    # Browse structure

Instructions

  1. Verify the CLI: blz --version
  2. Use explicit commands: blz query for search, blz get for retrieval
  3. Prefer --json outputs: Set export BLZ_OUTPUT_FORMAT=json for session-wide JSON output
  4. Choose llms-full.txt when available: Provides complete docs with best search quality; fall back to llms.txt if -full variant doesn't exist
  5. Control context: Use -C <N> for line context, --context all to expand to the containing heading section (falls back to requested lines if no heading), --max-lines <N> to cap output
  6. Filter by heading level: Use -H 1,2,3 or -H <=2 to target specific section depths

Setup & Sources

# Add source non-interactively
blz add bun https://bun.sh/llms.txt -y

# List indexed sources
blz list --json

# Check source health before heavy retrieval
blz info bun --json

Search & Retrieve

Use blz query for text search and blz get for citation retrieval:

# Search mode: text queries find relevant sections
blz query "test runner" --json
blz query "authentication" -H 2 --json               # Filter to h2 headings only
blz query "error handling" -H 3 --headings-only --json  # Match headings, not body text

# Retrieve mode: citations fetch exact line ranges
blz get bun:41994-42009 -C 5 --json                          # Add 5 lines of context
blz get bun:41994-42009 --context all --max-lines 80 --json  # Expand to heading section, capped
# Note: --context all expands to the containing heading section.
# If no heading encompasses the range, returns only the requested lines.

# Mix multiple citations from different sources
blz get bun:41994-42009 turbo:2656-2729 -C 2 --json

# Control snippet length (default: 200 chars, range: 50-1000)
blz query "api documentation" --max-chars 300 --json   # Longer snippets
blz query "quick reference" --max-chars 100 --json     # Shorter snippets to save tokens

# Seamless workflow: search then retrieve
span=$(blz query "test runner" --json | jq -r '.results[0] | "\(.alias):\(.lines)"')
blz get "$span" -C 10 --json

Read the full file on GitHub · 145 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. 2d ago First seen · 145 lines · 23 tokens per session scan A 784da6a12dce

Subscribe to this mod's changes

use-blz is an agent published in the GitHub repository outfitter-dev/blz (27 stars, last pushed 21d ago), licensed MIT. It adds 23 tokens to every session and 1,574 once invoked, about $0.0001 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-30.