Skip to main content
Glama
graphgrow

root-ext-docs

by graphgrow
README.md
# root-ext-docs

Document-engineering MCP tool server for ROOT Workspace (and any MCP
host). Twelve tools across four surfaces:

- **PDF** — `pdf_info` (which pages are text, which are scans),
  `pdf_extract_text` (page-ranged), `pdf_pages_to_images` (render to
  `derived/` — where the workspace viewer and the model's image-read
  path pick them up), `ocr_pdf` (local tesseract).
- **Office** — `docx_extract`, `pptx_extract`: structure-keeping
  markdown (headings, tables, slide notes).
- **Images** — `ocr_image`, `image_convert`, `image_crop`,
  `image_annotate` (labelled rectangles for pointing at drawings).
- **Archives** — `archive_list`, `archive_extract` (zip-slip refused
  by name, size/entry caps).

**Charter, binding and tested: extract and derive, never mutate
sources.** No tool overwrites, deletes, or edits a user's file in
place; write tools refuse output paths that collide with inputs and
default to `derived/` beside the source.

OCR needs the system `tesseract` binary (`brew install tesseract`) and
refuses by name without it. Nothing in this pack reaches the network.

## Develop

```sh
uv venv && uv pip install -e ".[dev]"
.venv/bin/pytest
```

## Package (signed .rootx, ADR-0018)

```sh
uv build
.venv/bin/python tools/build_pack.py   # --unsigned for a test build
```

TDQS

A4.2/5.0

Scored across 12 tools

Disambiguation5/5

Each tool targets a distinct resource or operation: archives, PDF (with clear separation between info, text extraction, rendering, and OCR), DOCX, PPTX, and images. The descriptions explain precisely when to use each, minimizing overlap.

Naming Consistency4/5

Most tools follow a resource_action pattern (e.g., pdf_extract_text, image_crop), but ocr_pdf and ocr_image invert this to action_resource. pdf_info uses a noun as a verb. The pattern is largely consistent with minor deviations.

Tool Count5/5

At 12 tools, the set is well-scoped for a document extraction server. Each tool has a clear role, covering archives, multiple document formats, and image processing without unnecessary duplication.

Completeness4/5

The surface covers core extraction workflows: listing/extracting archives, reading PDFs (text, renders, OCR), extracting DOCX/PPTX, and image processing. Minor gaps exist (no archive creation, no PDF metadata extraction) but do not hinder primary use.

Maintenance

ActivitySlowing
ResponsivenessNo issues