Skip to main content
Glama
io.github.tidybytetools/md-chunk-lite

io.github.tidybytetools/md-chunk-lite

Official

List Markdown headings

outline_markdown
Read-onlyIdempotent

Lists every Markdown heading with its level, path, anchor, line number, and size to map a long document before reading, chunking, or retrieving a section by heading.

Instructions

List every heading in a Markdown file or text, with its level, path, anchor, line number and size.

Use this when you want a quick map of a long document before you read or chunk it, or to find the exact heading or anchor to pass to get_section. Headings inside code blocks and YAML front matter are ignored. Both "# Title" and underlined (=== / ---) headings are found.

Do not use it to get the text itself (use get_section or chunk_markdown).

Returns {"source", "count", "headings": [{"level", "title", "path", "anchor", "line", "end_line", "chars"}]}. chars is the size of that heading's own text, not counting the sections under it.

Input Schema

NameRequiredDescriptionDefault
pathNoFull path to a local Markdown or text file (UTF-8, up to 10 MB). Leave empty if you pass text.
textNoMarkdown text to use instead of a file. Leave empty if you pass path.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

A4.4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnly/idempotent/non-destructive, so the safety profile is covered; the description earns credit by adding real edge-case behavior that annotations cannot express — headings inside code blocks and YAML front matter are ignored, and both ATX and underlined headings are supported. It also documents the return shape because no output schema exists, including the non-obvious semantics of "chars" (own text only, excluding subsections). It does not say what happens when neither path nor text is supplied, which is the one behavioral gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Purpose and use case come first, exclusions second, return shape last, each in its own paragraph. The inline return object is verbose in form but justified because there is no output schema, and every sentence conveys distinct information with no repetition of the name or title.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a read-only two-parameter tool with full schema coverage and no output schema, the description covers purpose, routing, parsing edge cases, and the full return contract. The only missing piece is default behavior when both optional parameters are empty and how errors (missing file, oversized file) surface, which is minor but not nothing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, and the schema already explains the path/text mutual exclusion and the 10 MB UTF-8 limit. The description adds no further meaning to either parameter, so the baseline 3 applies — the schema is doing all the parameter work.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ("List every heading in a Markdown file or text") and immediately enumerates the fields returned (level, path, anchor, line, size), so an agent knows exactly what it gets. It is clearly distinguished from siblings get_section and chunk_markdown, which are named in the same paragraph.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives an explicit positive trigger ("quick map of a long document before you read or chunk it, or to find the exact heading or anchor to pass to get_section") and an explicit exclusion ("Do not use it to get the text itself") with the correct alternatives named. There is no ambiguity about routing between outline_markdown and its siblings.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.