Skip to main content
Glama
ragflow-kb-mcp
by feci

ragflow_download_document

Read-only

Retrieve a document's original file from a RAGFlow knowledge base by dataset and document ID; text files return content, while binary files return size and type.

Instructions

Read a document's original file. Text files come back as text; binary files only as size and type.

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": {
      "dataset_id": "<dataset_id>",
      "document_id": "<document_id>"
    },
    "name": "ragflow_download_document"
  }
}

Input Schema

NameRequiredDescriptionDefault
max_charsNo
dataset_idYesDataset (knowledge base) ID
document_idYesDocument ID

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.1

TDQS

B3.3/5.0
Behavior4/5

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

Annotations already declare this as a safe read-only operation, but the description adds meaningful behavior: text files return text while binary files return only size and type. It does not disclose truncation behavior from max_chars, which is a relevant operational caveat.

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, front-loaded with the action and followed by the important result-format distinction. No sentence is wasted.

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

Completeness3/5

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

Because an output schema exists and annotations cover safety, the core behavior is adequately described. However, the missing treatment of max_chars truncation and the lack of distinction from similar download tools leave meaningful gaps for correct invocation.

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

Parameters2/5

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

The schema documents dataset_id and document_id, but max_chars is entirely undocumented at the schema level. The description does not mention max_chars, truncation, or limits, so it fails to compensate for this meaningful parameter gap.

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?

The description states a specific action and resource: reading a document's original file, with a useful note on text versus binary results. It is clearly distinct from document-management siblings like upload_document or delete_documents, though it does not distinguish itself from ragflow_download_file.

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

Usage Guidelines2/5

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

It gives no explicit guidance on when to choose this over nearby alternatives such as ragflow_download_file or ragflow_get_commit_file_content. Usage is only implied by the phrase 'Read a document's original file,' leaving the agent to infer selection criteria.

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