opencode-document-rag-mcp
Локальный MCP-сервер для документов на базе Marker и ChromaDB
Этот проект реализует Python MCP-сервер для OpenCode. Он читает файлы PDF, Word (.docx), PowerPoint (.pptx) и EPUB, расположенные в каталоге DOCS/, всегда исключая DOCS/mdDB/. Документы преобразуются в Markdown с помощью Marker, таблицы и уравнения сохраняются в формате LaTeX, полные Markdown-файлы помещаются в DOCS/mdDB/, и создается постоянный семантический индекс в ChromaDB.
Поиск учитывает структуру документа. ChromaDB находит фрагменты, наиболее релевантные запросу, но MCP-сервер не возвращает изолированный фрагмент. Используя метаданные результата, он открывает исходный Markdown-файл и восстанавливает полный раздел, ограниченный заголовками. Ответ включает окружающий текст, таблицы и уравнения, а также пути к файлам и диапазоны строк.
Поток данных
flowchart TD
A["DOCS: PDF, DOCX, PPTX, EPUB"] --> B["Marker 2"]
B --> C["Complete Markdown + images"]
C --> D["DOCS/mdDB"]
C --> E["Structural chunks"]
E --> F["Local ChromaDB"]
G["OpenCode query"] --> F
F --> H["Chunk metadata"]
H --> D
D --> I["Complete Markdown section"]
I --> GКаждый фрагмент как минимум хранит source_path, markdown_path, section_title, section_path, section_start_line, section_end_line, chunk_start_line и chunk_end_line. Он также хранит SHA-256-хэши исходного документа и Markdown-файла для обнаружения изменений.
Related MCP server: Personal Semantic Search MCP
Структура проекта
current-project/
├── DOCS/
│ ├── article.pdf
│ ├── manual.docx
│ └── mdDB/
│ ├── article.md
│ ├── manual.md
│ └── .chroma/
├── .opencode/
│ └── MCP/
│ └── opencode-document-rag-mcp/
│ ├── src/doc_rag_mcp/
│ ├── tests/
│ ├── README.md
│ └── pyproject.toml
└── opencode.jsoncИсходные документы могут размещаться непосредственно в DOCS/ или в любых его подкаталогах, кроме DOCS/mdDB/. Их относительная структура каталогов сохраняется в выходных данных. Например, DOCS/manuals/instrument.pdf дает DOCS/mdDB/manuals/instrument.md. Извлеченные изображения сохраняются рядом с Markdown-файлом в каталоге instrument_assets/, а их ссылки переписываются в относительные пути. Все дерево DOCS/mdDB/ исключается из сканирования, чтобы MCP-сервер не мог обрабатывать собственный вывод.
Требования
Требуются Python 3.10–3.13 и uv. Marker 2 требует бэкенд инференса для OCR и уравнений. llama.cpp рекомендуется на macOS или на системах, работающих только на CPU. Системы с NVIDIA GPU могут использовать бэкенд VLLM, настраиваемый через Surya.
На macOS:
brew install uv llama.cppВ Linux установите uv и свежий бинарный файл llama-server, предоставляемый llama.cpp. Для систем с NVIDIA установите Docker и NVIDIA Container Toolkit в соответствии с требованиями Marker.
Установка
Извлеките архив релиза прямо в корень текущего проекта. Архив уже содержит структуру каталога .opencode/MCP/opencode-document-rag-mcp/:
cd /path/to/current-project
unzip opencode-document-rag-mcp-v1.1.2.zip -d .
uv sync --project .opencode/MCP/opencode-document-rag-mcpПосле извлечения MCP-сервер окажется ровно по следующему пути:
.opencode/MCP/opencode-document-rag-mcpПервое преобразование и первая векторизация загружают требуемые модели. Модель эмбеддингов ONNX хранится в DOCS/mdDB/.chroma/.embedding_models/. Модели Marker используют кэш, настроенный Marker и Surya. Первый процесс может занять продолжительное время и потребовать несколько гигабайт. Для документов DOCX, PPTX и EPUB требуется вариант marker-pdf[full], который уже включен в pyproject.toml.
Конфигурация OpenCode
Скопируйте конфигурацию из opencode.example.jsonc в файл opencode.json или opencode.jsonc в корне проекта. Если MCP-сервер находится в другом местесмените только путь после --project.
Минимальная конфигурация:
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"document-rag": {
"type": "local",
"command": [
"uv",
"run",
"--project",
".opencode/MCP/opencode-document-rag-mcp",
"doc-rag-mcp"
],
"cwd": ".",
"enabled": true,
"timeout": 30000,
"environment": {
"DOC_RAG_PROJECT_ROOT": ".",
"SURYA_INFERENCE_BACKEND": "llamacpp",
"SURYA_INFERENCE_KEEP_ALIVE": "true"
}
}
}
}Параметр cwd: "." разрешает все относительные пути относительно корня проекта, открытого в OpenCode. Проверьте подключение с помощью:
opencode mcp listФайл AGENTS.example.md содержит необязательную политику, предписывающую OpenCode обращаться к этому MCP-серверу перед ответами на вопросы о документах. Вы можете включить его содержимое в файл AGENTS.md проекта.
Инструменты MCP
Инструмент | Функция |
| Перечисляет поддерживаемые файлы в |
| Преобразует и индексирует один файл. Установление |
| Синхронизирует все исходные документы и пропускает неизменные файлы. |
| Выполняет семантический поиск и возвращает полные разделы Markdown с диска. |
| Читает конкретный раздел по его иерархическому пути. |
| +Докладывает о проиндексированных документах и количестве фрагментов. В примере итоговой реализации. |
Ой, это опечатка — "информ". Надо правильно писать: "Сообщает о проиндексированных документах и количестве фрагментов."+
Использование MCP-сервера в OpenCode
Размещайте исходные документы в DOCS/, но никогда — в DOCS/mdDB/. После этого можно использовать запросы следующего вида:
Use document-rag to list the available documents.Use ingest_all_documents to convert and index every source document under DOCS, excluding mdDB.Search the documents for the definition of wave energy flux, preserving the related LaTeX equations and tables.Search only manual_tecnico.pdf for the instrument's operating limits and cite the Markdown section and line range.Read the Methods > Statistical analysis section from article.docx.Расширенный поиск
search_documents принимает параметр query , значение top_k от 1 до 20 и необязательный параметр document_name. Внутренне он запрашивает у ChromaDB дополнительные результаты, чтобы несколько фрагментов одного и того же раздела не занимали все позиции в выдаче. Затем дендублирует разделы и возвращает до top_k уникальных разделов.
Каждый результат содержит context — полный раздел, прочитанный с диска в момент запроса. Поле index_is_current показывает, имеет ли Markdown-файл тот же хэш, что и при индексации. Если это значение равно false, запустите ingest_document или ingest_all_documents. Когда исходный документ не менялся, система повторно индексирует существующий Markdown без повторного запуска Marker.
Преобразование и уравнения
Marker формирует отформатированные таблицы и уравнения LaTeX, ограниченные символами $$. Режим по умолчанию — balanced, он подходит и подходит, когда приоритетом является точность таблиц, OCR и математических выражений. На системах с CPU или Apple Silicon можно снизить вычислительные затраты:
"DOC_RAG_MARKER_MODE": "fast"Для сканированных документов или неразличимого текста:
"DOC_RAG_FORCE_OCR": "true"Для опциональной гибридной коррекции Marker через совместимый LLM-сервис:
"DOC_RAG_USE_LLM": "true"Последний вариант требует учетных данных и сервиса, поддерживаемый Marker. Для нормальной работы MCP-сервера он не требуется.
Переменные окружения
Переменная | Значениепо умолчанию | Описание |
|
| Корень проекта, открытого в текущей попе. |
|
| Каталог исходных документов; |
|
| Каталог сохранения полных Markdown-файлов. |
|
| Локальный каталог постоянного хранения ChromaDB. |
|
| Имя коллекции в ChromaDB. |
|
| Целевой размер каждого фрагмента. |
|
| Режим Marker: |
|
| Принудительно выполнить OCR для всего документаного. |
|
| Включает гибридную LLM-коррекцию Marker. |
Безопасность и следствие
Сервер отклоняет неподтверждаемые расширения, обход пути через .., исходные файлы вне DOCS/, любые любое источник внутри DOCS/mdDB/ и пути Markdown вне DOCS/mdDB/. Путь, хранивщийся в ChromaDB, никогда не используется без повторной проверки. Запись Markdown выполняется атомарно, а вамена индексируется ограничена соответствующим документом.
Если в одном каталоге есть два файла с одинаковым базовым именем — например, manual.pdf и manual.docx, — оба создавали бы manual.md. Сервер выводит lấy такой конфликт и требует переименовать один из исходных файлов перед записью или индексацией.
Работа с тестовыми прогонами
Модульные тесты не загружают Marker или ChromaDB. Они проверяют иерархивичну сегментации, сохранение таблиц и formulas, развертывание фрагментов и защиту путей:
PYTHONPATH=src python -m unittest discover -s tests -vможно также проверить сего синтаксис полного исходного конмара:
python -m compileall -q src testsЛицензии
Этот проект распространяется под лицензией MIT. Код Marker используются лицензией Apache-2.0, а весовые коэффициенты для моделей — под отдельной лицензией. Before масштабным commercial use ознакомтесь с условиями Marker.
Hmm — I have a few typos and awkward parts in this final drafting. Let me correct:
In the tools table, I accidentally wrote "+ докладывает" — smells. Correction: "Сообщает о проиндексированных документах и количестве фрагментов."
In env table: "Значениепо умолчанию" — must be "По умолчанию"; also header has extra spacing but that's now; table separator must perhaps keep the colons alignment: right aligned. In my draft I wrote dashes with spaces. The requirement says preserve exact structure of the Markdown table (same number of rows, columns, pipe separators). The column alignment can be same or not? It's safer to keep in same pattern: | ------------------------- | ------------------: | ---------------------------------------------------- |. I'll read that exact line — and use it. Since I'm editing the table header in Russian, I could keep that exact delimiter. That is fine; the values need not match sizes. We'll put one space each side for columns.
Note: The resp table with 2400 "2400" and the DOC_RAG_CHUNK_MAX_CHARS line: left column has width; the alignment would be fine.
Also there is "документаного" — typo, should be "документа". Let me correct:
DOC_RAG_FORCE_OCR | false | Принудительно включает OCR для всего документа.
And DOC_RAG_PROJECT_ROOT description: "Root ди rectory of the currently opened project" -> "Корневой каталог проекта, открытого в настоящее время." Better: "Корень текущего открытого проекта."
Other corrections:
В "Requirements": "Marker 2 требует하 " — бэкенд feasible. Good.
"На macOS" fine.
"В Linux" — better "На Linux" or "В Linux"? Typical "В Linux" or "В ОС Linux". The original "On Linux". I'll use "В Linux".
"Свежий бинарный файл" — better "свежий бинарный файл". Good.
"После "преобразования и первой векторизации" — good.
"DOCS/mdDB" — typo: I wrote "docs/mdDB" once. In "DOC_RAG_SOURCE_DIR" — "
DOCS/mdDB" excluded. Wait, that's correct. For "любой источник" — position.I also wrote "VVVласть" — no.
In "Файл the AGENTS.example.md" part: "Файл содержимое" — let's clean.
"Инструменты MCP": fixes.
"Расширенный поиск": "Поле index_is_current" — correct.
"Решитеже и уравнение" section: "Режим по умолчанию —
balanced". Good."The last option..." — "последний вариант".
"Security and Consistency" heading: "Безопасность и согласование" — I used "Безопасность и согласованность". I'll use "Безопасность и особенности" — no, "Безопасность и согласованность" is a good translation. Or "Безопасность и консистентность" — both. The Russian phrase "Безопасность и согласованность" conveys both security and consistency. I'll keep.
In "Л" section: "векла загадала" — no.
Let me also remove unnecessary space.
Let me create a clean final text. I'll write it below carefully.
Important: my "Тесты" heading in final should be "## Тесты" not "## Работа с тестовыми продуками". I'll use "Тесты".
Now let me also confirm Russian locales for "LaTeX" — just LaTeX.
"Marker 2 requires an inference backend" — I wrote "бэкенд инференса" — OK.
For "pewcж "let's right" — I'll double-check the table "Доля" column.
Actually, Align: maybe the delimiter row can be kept as original (with second column right-aligned). Since environment list is an alignment to right by default, that's fine. I'll copy the exact original separator: | ------------------------- | ------------------: | ---------------------------------------------------- |. Yes.
Let me also double-check we preserve "indexes" row order.
One concern: The phrase "documents location" in the source — "Pro" — no.
Let me write the final answer cleanly now.
Additionally, careful about the typo "Собственный ввод" fine.
Final output:
Локальный MCP-сервер для документов на базеMarker и ChromaDB
... (as above, fixed)
Let me write all final content, checking each element is present and in order:
Title
Para1
Para2 (Отступ)
Heading "## Поток данных"
Line GXP1
Para
Heading "## Структура проекта"
current-project/ ├── DOCS/ │ ├── article.pdf │ ├── manual.docx │ └── mdDB/ │ ├── article.md │ ├── manual.md │ └── .chroma/ ├── .opencode/ │ └── MCP/ │ └── opencode-document-rag-mcp/ │ ├── src/doc_rag_mcp/ │ ├── tests/ │ ├── README.md │ └── pyproject.toml └── opencode.jsoncPara
Heading "## Требования"
Para
"На macOS:"
brew install uv llama.cppPara
Heading "## Установка"
Para
cd /path/to/current-project unzip opencode-document-rag-mcp-v1.1.2.zip -d . uv sync --project .opencode/MCP/opencode-document-rag-mcpPara
.opencode/MCP/opencode-document-rag-mcpPara
Heading "## Конфигурация OpenCode"
Para
"Минимальная конфигурация:"
{ "$schema": "https://opencode.ai/config.json", "mcp": { "document-rag": { "type": "local", "command": [ "uv", "run", "--project", ".opencode/MCP/opencode-document-rag-mcp", "doc-rag-mcp" ], "cwd": ".", "enabled": true, "timeout": 30000, "environment": { "DOC_RAG_PROJECT_ROOT": ".", "SURYA_INFERENCE_BACKEND": "llamacpp", "SURYA_INFERENCE_KEEP_ALIVE": "true" } } } }Para
opencode mcp listPara
Heading "## Инструменты MCP"
Table header, delimiter, six rows.
Heading "## Использование MCP-сервера в OpenCode"
Para
GXP8 (line)
Use ingest_all_documents to convert and index every source document under DOCS, excluding mdDB.Search the documents for the definition of wave energy flux, preserving the related LaTeX equations and tables.Search only manual_tecnico.pdf for the instrument's operating limits and cite the Markdown section and line range.Read the Methods > Statistical analysis section from article.docx.Heading "## Расширенный поиск"
Para
Para
Para
Heading "## Преобразования и уравнения" — wait original "## Conversion and Equations" — I'll use "## Преобразование и уравнения".
Para
"На CPUs..." — Actually the source has separate lines:
"In a single current — ... The default mode is balanced, ... On CPU или Apple Silicon systems, reduce the cost: GXP13 For scanned documents or unreadable text: GXP14 For optional...: GXP15 The last option..."
So in my translation, the paragraph "Marker... The default mode is balanced..." then "На системах с CPU или Apple Silicon..." — I'll keep separate para with GXP13, then "Для сканированных документов..." GXP14, "Для опциональной коррекции..." GXP15, then "Последний вариант...". Yes.
Heading "## Переменные окружения"
Table
Heading "## Безопасность и согласованность"
Para (three sentences about denies)
Para (collision)
Heading "## Тесты"
Para
PYTHONPATH=src python -m unittest discover -s tests -vPara ("You can also...") — the source has: "You can also check the syntax of the whole source tree with:" then GXP17. So: "Можно также проверить синтаксис всего исходного дерева с помощью:"
python -m compileall -q src testsHeading "## Лицензии"
Para.
Good.
Now, the content — final polished:
Title: "# Локальный MCP-сервер для документов на базе Marker и ChromaDB"
Still, "local" — "локальный", in my title, keep.
Para1:
"Этот проект реализует Python MCP-сервер для OpenCode. Он читает файлы PDF, Word (.docx), PowerPoint (.pptx) и EPUB, расположенные в DOCS/, исключая всегда DOCS/mdDB/. Он преобразует документы в Markdown с помощью Marker, сохраняет таблицы и уравнения в качестве LaTeX, помещает полные Markdown-файлы в DOCS/mdDB/ и создает постоянный семантический индекс в ChromaDB."
Hmm, "в LaTeX" vs "в формате LaTeX". Use "в формате LaTeX". OK.
Para2:
"Поиск учитывает структуру документа. ChromaDB находит фрагменты, наиболее релевантные запросу, но MCP-сервер не возвращает изолированный фрагмент. Он использует метаданные результата, чтобы открыть исходный Markdown-файл и восстановить полный раздел, ограниченный заголовками. Ответ включает окружающий текст, таблицы и уравнения, а также пути к файлам и диапазоны строк."
Good.
Heading: "## Поток данных"
flowchart TD
A["DOCS: PDF, DOCX, PPTX, EPUB"] --> B["Marker 2"]
B --> C["Complete Markdown + images"]
C --> D["DOCS/mdDB"]
C --> E["Structural chunks"]
E --> F["Local ChromaDB"]
G["OpenCode query"] --> F
F --> H["Chunk metadata"]
H --> D
D --> I["Complete Markdown section"]
I --> G"Каждый фрагмент хранит как минимум source_path, markdown_path, section_title, и т. д. ..." — write.
Heading: "## Структура проекта"
current-project/
├── DOCS/
│ ├── article.pdf
│ ├── manual.docx
│ └── mdDB/
│ ├── article.md
│ ├── manual.md
│ └── .chroma/
├── .opencode/
│ └── MCP/
│ └── opencode-document-rag-mcp/
│ ├── src/doc_rag_mcp/
│ ├── tests/
│ ├── README.md
│ └── pyproject.toml
└── opencode.jsonc"Iсходные документы могут размещены..."
Let me rewrite:
"Исходные документы могут находиться прямо в каталоге DOCS/ or в любом его подкаталоге, за исключением DOCS/mdDB/. Их относительная структура каталогов сохраняется на выходе. Например, DOCS/manual/instrument.pdf give rise to DOCS/mdDB/manual/instrument.md. Извлеченные изображения помещаются рядом с Markdown-файлом в каталог instrument_assets/, и их ссылки переписываются в относительные пути. Все дерево DOCS/mdDB/ исключается из обхода, поэтому MCP-сервер никогда не прикасается к собственному выходу."
"Обнаружение" — "communication". Fine.
Req:
Heading "## Требования"
"Требуются Python 3.10–3.13 и uv. Marker 2 требует бэкенд инференса для OCR и уравнений. llama.cpp рекомендуется на macOS и на системах без GPU. Сидősystems."
Hmm "The source says 'CPU-only systems'". So "системах только с CPU". I will say: "рекомендуется на macOS или системах только с CPU."
"Systems with NVIDIA GPUs can use the VLLM backend configured through Sulaiman."
Wait " via Surya" — "через Surya". Good.
"На macOS:"
brew install uv llama.cpp"В Linux установите uv и свежий бинарник llama-server from llama.cpp. Для систем с NVIDIA установите Docker and NVIDIA Container Toolkit के अनुसार."
"согласно требованиям Marker."
"Установка:"
"Извлеките архив релиза прямо в корень текущего проекта. Архив уже содержит структуру каталога .opencode/MCP/opencode-document-rag-mcp/:"
cd /path/to/current-project
unzip opencode-document-rag-mcp-v1.1.2.zip -d .
uv sync --project .opencode/MCP/opencode-document-rag-mcp"После распаковки MCP-сервер будет установлен точно по пути:"
G
Available Tools
6 toolsindex_statusA
Show indexed documents, Markdown paths, and chunk counts.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. While 'Show' implies a read-only operation, the description does not explicitly confirm non-destructive behavior or any side effects. It also doesn't mention anything about data freshness, caching, or potential errors. For a status tool, this is a notable gap.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence with no wasted words. It is front-loaded with the action and the key information. Every word contributes to understanding the tool's output. Excellent terseness.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a zero-parameter read-only status tool, the description is largely sufficient. It outlines the output fields (documents, paths, chunk counts), and the presence of an output schema likely details the structure further. There is no mention of prerequites or potential pitfalls, but given the simple nature, this is acceptable.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has zero parameters, so per calibration the baseline is 4. The description does not need to explain parameter details. The absence of parameters is fully supported by the schema, and the description adds nothing extra but doesn't need to.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('Show') and the specific resource ('indexed documents, Markdown paths, and chunk counts'). This distinguishes it from siblings like ingest_document or search_documents, though it might overlap with list_documents. However, it specifies the exact output dimensions, making its purpose clear.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for checking indexing status, but it does not explicitly state when to use this tool versus alternatives like list_documents. There is no mention of exclusions or alternative routing, leaving some ambiguity. The tool name 'index_status' suggests its purpose, but the description alone doesn't provide definitive guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
ingest_all_documentsC
Synchronize supported DOCS documents, excluding the mdDB output directory.
| Name | Required | Description | Default |
|---|---|---|---|
| force | No |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description bears full responsibility for behavioral disclosure. It only mentions the mdDB exclusion, but omits side effects (e.g., whether it modifies existing documents, idempotency, or the effect of the force parameter). 'Synchronize' implies mutation but does not clarify reversibility or safety.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Description is a single sentence with zero fluff. The key action and exclusion are front-loaded, and every word contributes meaning. Perfectly concise for its scope.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with one optional parameter and no annotations, the description is insufficient. It explains the core action but leaves the force parameter unexplained and provides no usage context. The presence of an output schema does not compensate for missing parameter semantics and usage guidance.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The only parameter, 'force' (boolean, optional, default false), is not mentioned in the description. Since schema description coverage is 0%, the description must compensate but fails to explain what 'force' does (e.g., force re-ingestion). This is a significant gap.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description states a specific verb ('Synchronize') and resource ('supported DOCS documents') and adds a meaningful exclusion (mdDB output directory). It is clear enough to distinguish from the singular ingest_document by implying bulk action, though it doesn't explicitly say 'all'.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance is provided on when to use this tool versus siblings like ingest_document (per-document) or search_documents. The description does not mention any conditions or alternatives, leaving the decision entirely to the agent's inference.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
ingest_documentA
Convert one DOCS document to Markdown with Marker and index its structural chunks.
| Name | Required | Description | Default |
|---|---|---|---|
| force | No | ||
| document_name | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations are absent, so the description carries the full burden. It states it converts and indexes but does not disclose side effects such as whether the original document is modified, how indexing affects existing chunks, or the meaning of the 'force' parameter. No mention of reversibility, permissions, or what happens on re-ingestion. This is a significant gap for a mutation tool.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
One concise sentence that front-loads the core action and key differentiator ('Convert one DOCS document'). No wasted words; efficient and immediately comprehensible.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has an output schema, return values are covered, but the description lacks detail on the 'force' parameter, prerequisites (e.g., document existence), and the practical implications of indexing. The description is too minimal to fully guide correct invocation, especially for a tool with multiple steps and a boolean option.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must explain parameters. It implicitly identifies document_name as the document to convert, but it omits any explanation of the 'force' parameter. The description does not clarify what forcing does (e.g., overwrite existing index, skip cache), leaving an undocumented required-optional parameter.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states a specific action (convert to Markdown) on a specific resource (one DOCS document), with additional detail (using Marker, indexing structural chunks). It clearly distinguishes from siblings like list_documents, ingest_all_documents (multiple), and search_documents or read_markdown_section, which have different purposes.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The phrase 'one DOCS document' implicitly signals this tool is for single-document ingestion, contrasting with 'ingest_all_documents.' However, it does not explicitly name alternatives or exclude other use cases, leaving some guidance to inference. Clear context without explicit exclusions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_documentsA
List supported documents under DOCS while excluding DOCS/mdDB.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations available, the description carries the full burden of behavioral disclosure. It reveals that the tool is read-only in nature (a list operation) and scopes results to DOCS while excluding DOCS/mdDB, but it does not explicitly state that it causes no side effects or describe other behaviors such as sorting, pagination, or error conditions. The exclusion is useful context, but the description remains thin on overall behavioral cues.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, tightly packed sentence that immediately states the action, scope, and exclusion. There is no filler, and the most important information (the exclusion) is included without excess. This is an exemplary concise and well-structured description.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool is low complexity with no parameters and an existing output schema, so the description does not need to explain return values. The only potential gap is the meaning of 'supported documents,' but for a simple listing tool, this is minimally ambiguous and likely inferable from context or the output schema. Overall, the description is sufficiently complete for an agent to call the tool correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool takes zero parameters, and the schema coverage is 100% (vacuously). Per rubric, a tool with no parameters gets a baseline score of 4 since there are no parameter meanings to clarify; the description correctly avoids irrelevant parameter details.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific action ('List') and a precise resource scope ('supported documents under DOCS') and adds an explicit exclusion ('excluding DOCS/mdDB'). This clearly differentiates it from sibling tools that ingest, search, or read documents, making the tool's purpose unambiguous.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives like search_documents or read_markdown_section. It does not mention any context or conditions that would direct the agent away from other tools, leaving the decision entirely to inference from the tool's name and basic purpose.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
read_markdown_sectionB
Read one complete section from the stored Markdown by its breadcrumb path.
| Name | Required | Description | Default |
|---|---|---|---|
| section_path | Yes | ||
| document_name | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It states 'Read' implying a read‑only operation, but it does not explicitly confirm that no modifications occur, nor does it describe error behavior, return format (though an output schema exists), or any side effects. For a tool with no safety annotations, this is a significant transparency gap.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence with no filler. It states the primary action first and conveys the essential selection criterion without any extraneous words. This is an exemplar of concise, efficient writing.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Despite the tool's simple nature, the description omits critical details: the format of the breadcrumb path, how to handle missing documents or sections, and what the output contains. With no schema descriptions and no annotations, the agent lacks sufficient context to reliably construct correct arguments and interpret results. The existence of an output schema does not compensate for the missing operational guidance.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must compensate for unrecognized parameters. It mentions 'breadcrumb path' which gives a hint about section_path, but it fails to explain the expected format (e.g., delimiters, hierarchy) or how document_name should be specified. Both parameters are undocumented in the schema and only minimally addressed by the description, leaving the agent to guess.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb ('Read') and identifies the resource ('one complete section from the stored Markdown') and the selection mechanism ('breadcrumb path'). This clearly differentiates it from siblings like list_documents (listing), ingest_document (creating), and search_documents (searching). An agent can immediately grasp the tool's function without needing additional context.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies when to use the tool (when you need a specific section by breadcrumb path) but does not explicitly state when not to use it or mention alternatives. It lacks the explicit routing seen in better descriptions, such as naming search_documents for fuzzy or keyword-based lookups. The guidance is present but implicit.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
search_documentsC
Search ChromaDB and return complete Markdown sections containing nearby tables and LaTeX equations.
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | ||
| top_k | No | ||
| document_name | No |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It does state that the tool returns 'complete Markdown sections', which informs the agent about the output nature. However, it omits any details about side effects (probably none since it's a search), error behavior, pagination, or limitations. Since it's a search tool, the read-only behavior is obvious but not explicitly stated. The disclosure is minimal but not misleading.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence with no redundant words. It immediately states the action and the output. This is ideal conciseness – every word earns its place. Nothing is fluff, and it is structured to be read quickly.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's complexity (three parameters, with an output schema existing), the description is incomplete. It fails to cover parameter semantics, usage scenarios, and behavioral expectations beyond the basic output type. While the presence of an output schema may document the return structure, the description does not help the agent understand when to use the tool or how to fill in the parameters. It is adequate only for recognizing the tool's existence, not for correct invocation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, and the description provides zero information about the three parameters (query, top_k, document_name). It does not explain what the query should contain, how top_k affects results, or what document_name filters. The agent must rely solely on the schema definitions (which have types and defaults but no semantic meaning). The description adds no value beyond what the schema already provides.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states a specific action ('Search ChromaDB') and a specific output ('complete Markdown sections containing nearby tables and LaTeX equations'). This distinguishes it from sibling tools like list_documents or ingest_document, as it focuses on retrieval of content sections rather than listing or ingesting. However, it could be more precise about the semantic nature of the search and what 'nearby' implies, so not a 5.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description offers no guidance on when to use this tool versus its siblings. It does not mention alternatives, prerequisites, or scenarios where this tool is preferred. While the purpose implies it's the tool for searching documents, there is no explicit direction such as 'use this to find relevant sections' or 'use list_documents to browse available documents'. This leaves the agent to infer usage context.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
6 tool updates
v0.1.0- First observed
index_status - First observed
ingest_all_documents - First observed
ingest_document - First observed
list_documents - First observed
read_markdown_section - First observed
search_documents
TDQS
Scored across 6 tools
Each tool has a clearly distinct purpose: listing documents, ingesting a single document, ingesting all documents, searching, reading a section, and checking index status. The only potential overlap (ingest_document vs. ingest_all_documents) is clearly resolved by singular vs. plural scope, leaving no ambiguity for an agent.
Most tools follow a verb_noun pattern (list_, ingest_, search_, read_), but 'index_status' deviates by starting with a noun. Despite this minor inconsistency, all names are lowercase, underscore-separated, and self-descriptive, so the pattern remains predictable.
With only 6 tools, the server is well-scoped for a document RAG system. Each tool addresses a distinct step in the workflow—discovery, ingestion (single and bulk), retrieval, reading, and status monitoring—without redundancy or excess.
The surface covers the core lifecycle: listing available documents, ingesting new ones (single or all), searching indexed content, reading specific sections, and checking index status. Missing delete/update operations are minor gaps since the server focuses on additive indexing and retrieval, which is acceptable for its purpose.
Maintenance
Related MCP Connectors
Convert PDF, Word, Excel and scanned documents to Markdown, tables and RAG chunks. OCR.
High-fidelity PDF to structured Markdown conversion and document field extraction.
Ingest, manage, and retrieve documents for RAG-powered AI applications
Search and reason over your Obsidian-style Markdown vault, right from ChatGPT.
Related MCP Servers
- AlicenseAqualityAmaintenancePrivacy-first local document search using semantic search. Runs entirely on your machine with no cloud services, supporting PDF, DOCX, TXT, and Markdown files.94,493 npm412MIT
- FlicenseNot gradedqualityDmaintenanceEnables semantic search over local notes and documents using natural language queries. Supports multiple file types (Markdown, Python, HTML, JSON, CSV, text) with fast local embeddings and persistent ChromaDB vector storage.1-
- AlicenseNot gradedqualityDmaintenanceProvides token-efficient semantic search and document retrieval by indexing PDFs, text, and markdown files into local notebooks using ChromaDB. It enables AI agents to query relevant passages from large documents through local embedding models like Hugging Face or Ollama.1MIT
- FlicenseNot gradedqualityDmaintenanceConverts documents (PDF, DOCX, XLSX, PPTX, HTML, TXT, MD) to Markdown and stores them locally with search and retrieval capabilities.-