Available in
Marketplaces, most starred first
Tags
Add to README
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Claude loads one when your task matches it, or you run it by name.
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
mdlens is a Markdown retrieval CLI for AI agents.
The headline command is mdlens scout: give it a directory and a natural-language
question, and it returns a bounded evidence pack with likely files, section IDs,
highlights, table/context snippets, and enough structure for one precise follow-up
read.
mdlens scout docs/ "Which config option controls authentication timeout?" --max-tokens 1000
scout is meant to replace the common agent pattern of find, rg, cat, and
large raw file reads when the target corpus is Markdown. It works over arbitrary
English Markdown collections: READMEs, runbooks, model cards, generated docs,
experiment logs, tables, stale notes, and multi-file policy docs.
Run mdlens init to wire mdlens guidance into your AI coding harness. It writes a
small, idempotent instruction block into the files your tools already read
(CLAUDE.md, AGENTS.md, etc.), so you don't paste anything by hand.
mdlens init # project files in the current dir (CLAUDE.md + AGENTS.md)
mdlens init -g # user-level config (e.g. ~/.claude/CLAUDE.md)
mdlens init --gemini --cursor # pick specific harnesses
mdlens init --dry-run # preview without writing
Re-running init updates the block in place (it is managed by mdlens, so keep
any of your own edits outside the mdlens markers). Detailed guidance lives in
mdlens --help and mdlens scout --help, so harness prompts stay short while
future agents can still discover the workflow.
scout should be the first call for natural-language QA, multi-file comparison,
stale/current checks, table lookup, and policy/rationale questions.
The other commands are digging tools:
| Command | Use when |
|---|---|
read | scout found the right file and one exact section is missing |
search | you need a second independent lexical query |
tree | you only need Markdown structure and section IDs |
pack | you intentionally want selected sections under a hard token budget |
sections | you already have rg -nH hits and want section-aware excerpts |
stats | you need file-level size/token estimates |
Examples:
mdlens read docs/guide.md --id 1.2 --max-tokens 1200
mdlens search docs/ "rate limit"
mdlens tree docs/
rg -nH "rate limit" docs/ | mdlens sections --preview 3 --max-sections 8
All commands support --json for machine-readable output.
For scout, JSON includes schema_version, query expansions, selected
candidates, and the same rendered evidence pack in rendered_text.
mdlens gain)scout and read append a one-line usage record (baseline file tokens vs.
tokens returned) to ~/.local/share/mdlens/history.jsonl, and mdlens gain
sums it into a savings report (--json for machine output). This is the one
stateful feature; disable it with MDLENS_NO_GAIN=1.
The history is plain append-only text. Clear it with mdlens gain --reset --yes,
or truncate it directly, e.g. tail -n 1000 ~/.local/share/mdlens/history.jsonl | sponge ~/.local/share/mdlens/history.jsonl.
This is a Markdown QA/retrieval benchmark, not a claim about broad coding-agent performance. It measures whether agents answer from documentation with fewer irrelevant reads, fewer tool calls, and better recall.
The v0.1.3 eval runs 28 hard, low-lexical-overlap questions (needle,
multi-hop, abstention) over 673 real documentation files from six
open-source projects (FastAPI, DuckDB, Polars, Pydantic, uv, TRL), comparing
plain shell retrieval (rg/cat) against the mdlens scout workflow. To test
generalization it spans three harnesses and seven models: Claude Code
(Opus 4.8, Sonnet 4.6), Codex (GPT-5.4, GPT-5.4-mini), and three open-source
models run through Pi on OpenRouter (Kimi K2.7, GLM 5.2, DeepSeek V4 Flash).
Across all seven models, mdlens:
Per model (baseline -> mdlens):
Built from public signals: copy clicks on this site, GitHub stars and activity, the README and the manifest. Not a security audit or an endorsement.
Generated from the plugin's indexed repository (dreeseaw/mdlens) — no native marketplace selected
npx claudepluginhub p/dreeseaw-mdlensPlugins from other owners that cover similar ground