Skip to main content
Glama

list_documents

Inspect a directory to find files DocLens can read, with size and support status, so you can identify documents to process before batch operations.

Instructions

列出目录里 DocLens 能读的文件,附带大小和是否受支持。用于在批量处理前先摸清有哪些文档。

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": {
      "directory": "<directory>"
    },
    "name": "list_documents"
  }
}

Input Schema

NameRequiredDescriptionDefault
directoryYes要列出的目录路径
recursiveNo是否递归子目录

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.8/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full behavioral burden. It discloses the shape of a result entry (size and supported status), but says nothing about error behavior on a missing directory, hidden or symlinked files, or whether unsupported files are omitted or merely flagged.

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 short sentences with zero waste: what is listed first, purpose second. Fully front-loaded.

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 no explanation, and both parameters are documented in the schema. For a simple two-parameter read-only listing, the remaining gap is only edge-case behavior.

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 both parameters (directory, recursive) are already documented. The description adds only the notion of filtering to DocLens-readable files, which is not tied to any parameter and even sits ambiguously against the 'supported' flag it mentions.

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 (list files in a directory that DocLens can read) plus what each entry carries (size, supported flag). It does not explicitly name a sibling or contrast itself with the extraction/read tools, so it stops short of full differentiation.

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

Usage Guidelines4/5

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

Gives a clear usage context: survey which documents exist before batch processing. That tells the agent where this fits in a workflow, though it names no alternative tool or exclusion case.

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