Skip to main content
Glama

distill_files

Convert up to 20 PDF, Word, Excel, or PowerPoint files into token-lean Markdown for LLM use, paging oversized content and skipping files beyond the output cap while isolating per-file failures.

Instructions

Convert up to 20 documents to token-lean Markdown; a failing file does not fail the call. Output is capped: a file that does not fit is returned in part and later files are skipped

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "paths": "<paths>"
    },
    "name": "distill_files"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathsYesAbsolute path, or relative to the server's working directory, one per file
linguaNoCompress further with LLMLingua-2 when installed
boostersNoBoosters to apply: dedupe, media, tables, ws

Output Schema

NameRequiredDescriptionDefault
noteNo
totalYes
resultsYes
continuationNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.6/5.0
Behavior3/5

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

With no annotations provided, the description carries the full burden, and it does disclose two important traits: partial-failure tolerance and a capped output where oversized files are truncated and later files skipped. It omits whether the operation reads or writes anything, what the truncation signal looks like, and why later files are skipped (ordering matters), so a mutation/side-effect or recovery picture is not complete.

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?

Two clauses, front-loaded with the core action and cap, then the failure and truncation semantics. Every phrase carries information; nothing is repeated from structured fields beyond a harmless restatement of the limit.

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?

An output schema exists, so return values need not be described, and the key risk behaviors (partial failure, truncation, skipped files) are covered. The remaining gap is routing guidance against distill_file and any note on permission or read-only expectations, which matters given zero annotation coverage.

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%, so paths, lingua, and boosters are already documented in the schema, including the enum values. The description adds only the aggregate 20-file cap, which restates the schema's maxItems, and says nothing about how boosting or lingua interacts with the output cap.

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

Purpose4/5

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

States a specific verb and resource ('Convert ... documents to token-lean Markdown') plus the batch bound of 20, which implicitly distinguishes it from the single-file sibling distill_file. It never names that sibling explicitly, so differentiation is inferable rather than stated.

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

Usage Guidelines3/5

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

Usage is implied by the batch framing ('up to 20 documents'), but the definition never says when to prefer this over distill_file, nor when one should split a large job into multiple calls. The reader must infer the batch-vs-single decision from the tool name and the count limit.

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

Deploy Server

Other Tools