Skip to content

Quickstart

Install

doc-processing-std-tools needs Python 3.10 or newer. It is not published to PyPI: install it from Git at a release tag (this needs access to the repository).

Source code

The source code is in a private repository. These pages document every tool, setting and API. To review the code, message Rounak Zoeb on LinkedIn with your GitHub username.

pip install "doc-processing-std-tools @ git+https://github.com/rzoeb/doc-processing-std-tools.git@v0.6.1"

The base install covers the File System, Memory, Code Execution and Skills servers. The other servers need optional dependencies, installed as extras:

Extra Installs Needed for
docs pdfplumber, python-docx, openpyxl, python-pptx, Pillow, pymupdf the Documents readers and renderers, and Image Tools
ocr llmwhisperer-client 2.x ocr_pdf and ocr_image (also needs LLMWHISPERER_API_KEY)
web httpx, Pillow the Web server
extract trafilatura optional: main-content extraction and better Markdown in fetch_webpage
screenshot mss, Pillow the Screenshot server
browser Playwright, Pillow the optional Browser server; then run playwright install chromium
computer mss, Pillow, pynput (not on Linux) the optional Computer (Desktop) server; its virtual backend also needs Xvfb, xdotool and a window manager from the system's package manager
all all seven above everything (Chromium and the desktop's system packages are still installed separately)
pip install "doc-processing-std-tools[docs,web] @ git+https://github.com/rzoeb/doc-processing-std-tools.git@v0.6.1"

A missing extra never breaks an import. The tool that needs it returns an Error: ... message naming the extra to install.

Two things are not Python packages and come from the operating system or a provider:

  • LibreOffice, on PATH as libreoffice or soffice (or named in DPTTOOLS_SOFFICE_BIN), for convert_document and to render Word, Excel and PowerPoint pages as images. PDFs render without it.
  • An LLMWhisperer API key in LLMWHISPERER_API_KEY, for OCR.

Installing alongside doc-processing-toolkit

Resolve your application's requirements, the toolkit and std-tools in one pip install command, so pip sees every constraint at once. See Compatibility for the versions that work together.

Attach servers to a toolkit agent

Each server is a FastMCP object. Pass the ones you need straight to the toolkit's Agent:

from doc_processing_toolkit import Agent
from doc_processing_std_tools import document_processing_server, file_system_server

agent = Agent(
    model="claude-sonnet-5",
    instructions="You read documents in the workspace and answer questions about them.",
    tools=[file_system_server, document_processing_server],
)

result = agent.run_sync("List the PDFs in ./reports and summarise the newest one.")
print(result.output)

The tools run inside your process and read the DPTTOOLS_* variables from its environment. (Skills are the exception with toolkit 0.5.2 and earlier: see Compatibility.)

To expose only some of a server's tools (toolkit 0.5.1 or later), use the toolkit's dict form:

tools = [
    {
        "type": "fastmcp",
        "server": document_processing_server,
        "allowed_tools": ["read_pdf", "read_image"],
    },
]

Image-returning tools in-process need toolkit 0.5.1+

read_image, the page renderers and take_screenshot return images. Attached in-process to toolkit 0.5.0 or older, they reached the model as the text <...Image object at 0x...>. Use toolkit 0.5.1 or later, or run the servers out of process.

Run the composed launcher

To serve all eight servers as one MCP endpoint, run the package:

python -m doc_processing_std_tools                                # stdio (default)
python -m doc_processing_std_tools --transport http --port 8000   # streamable HTTP on 127.0.0.1

That serves 56 tools. The two optional servers join only when enabled: set DPTTOOLS_ENABLE_BROWSER=true for the browser (75 tools with its core profile), DPTTOOLS_ENABLE_COMPUTER=true for the computer server (73), or both (92).

The launcher checks the DPTTOOLS_* settings before serving and exits with a message naming any invalid one. Each server can also run on its own over stdio, for example python -m doc_processing_std_tools.file_system.

A toolkit agent can start the launcher itself:

import sys

agent = Agent(
    model="claude-sonnet-5",
    tools=[
        {
            "type": "mcp_command",
            "command": sys.executable,
            "args": ["-m", "doc_processing_std_tools"],
            "name": "std-tools",
        }
    ],
)

A launched server does not see your environment variables

The MCP Python SDK starts a stdio server with only a short list of safe variables (such as PATH and HOME) unless the client passes an explicit env, and the toolkit's mcp_command and mcp_script configs pass none (toolkit 0.5.2 and earlier). So DPTTOOLS_* and LLMWHISPERER_API_KEY set in your application do not reach a launcher the toolkit starts, and skills auto-injection sees an empty catalog. Open the stdio session yourself with an explicit env and pass it to the agent as a pre-built session — the code is in Using with the Toolkit.

First calls

With the servers attached, a model calls tools by name. A few calls that work on a fresh install with the docs extra:

Call Returns
list_directory(path=".") JSON list of entries with name, type and size
get_file_overview(path="report.pdf") JSON summary: page count, dimensions, text preview per page
read_pdf(path="report.pdf", pages="1-3") Text with --- Page N --- headers
read_document_pages_as_images(path="report.pdf", pages="1-2") One image per page, for the model to look at
execute_command(command="python --version") JSON with stdout, stderr, exit_code, timed_out

Every tool returns a string (or an image) and reports failures as a string that starts with Error:, rather than raising.

Next steps