OpenParable
Skip to content
← Back to skills

Mdzilla

Research
mdzilla

Mdzilla is an Agent Skill for research published in the pi0/mdzilla repository on GitHub: a SKILL.md instruction file an AI agent can load to do this task.

Browse, search, and export documentation from any source using the mdzilla CLI. Use when Claude needs to: (1) Read or browse documentation for a library, framework, or project, (2) Fetch docs from GitHub repos, npm packages, or websites, (3) Export documentation to flat markdown files, (4) Look up API references, guides, or usage examples from doc sites. Triggers: user asks to "read the docs", "check the documentation", "browse docs for X", "fetch docs from", "export docs", or references a docs site URL, npm package docs, or GitHub repo docs.

View on GitHub ↗
QUICK START

How to use this skill

Bring this guide into your coding agent with a prompt tailored to the tool you use.

  1. Open your project in Codex.
  2. Copy and paste the prompt below.
  3. Review files and risks before approving any action.
Prompt to paste
Inspect the Agent Skill at https://github.com/pi0/mdzilla/blob/HEAD/skills/mdzilla/SKILL.md and all supporting files. Report provenance, permissions, scripts, dependencies, and security risks. Propose an exact installation into .agents/skills/mdzilla, but wait for my approval before writing files or running scripts.

Copying this prompt does not install or run the skill. Review third-party files before use.

mdzilla

Markdown documentation browser for terminal and agents. Fetches and renders docs from local dirs, GitHub, npm, HTTP, and llms.txt.

CLI

npx mdzilla <source> [query] [options]

Sources

SourceSyntaxNotes
Local dirmdzilla ./docsScan local docs directory
Filemdzilla README.mdRender single markdown file
GitHubmdzilla gh:owner/repoLooks for docs/ in repo
npmmdzilla npm:package-nameDownloads package, reads docs
HTTPmdzilla https://example.comTries /llms.txt, then markdown negotiation, then HTML→markdown

Options

  • --export <dir> — Export docs to flat .md files
  • --plain — Plain text output; auto-enabled for AI agents or non-TTY stdout

Smart Resolve

The second positional argument is smart-resolved:

  1. If it matches a navigation path → renders that page
  2. Otherwise → searches titles and content

Agent usage

npx mdzilla gh:unjs/h3 /guide/basics        # render a specific page
npx mdzilla gh:unjs/h3 router               # search for 'router'
npx mdzilla https://h3.unjs.io /guide       # render page from URL
npx mdzilla npm:consola --plain             # list all pages (plain)

Export docs for offline processing:

npx mdzilla <source> --export ./fetched-docs

Then read the exported .md files as needed.

Programmatic API

Export Docs

import { exportSource } from "mdzilla";

await exportSource("./docs", "./dist/docs");
await exportSource("gh:unjs/h3", "./dist/h3-docs");
await exportSource("npm:h3", "./dist/h3-docs", { plainText: true });
await exportSource("https://h3.unjs.io", "./dist/h3-docs");

Collection

import { Collection, resolveSource } from "mdzilla";

const docs = new Collection(resolveSource("./docs"));
await docs.load();

console.log(docs.tree); // NavEntry[] navigation tree
console.log(docs.flat); // FlatEntry[] flat list

const content = await docs.getContent(docs.flat[0]);
const results = docs.filter("query"); // fuzzy search