Every operation runs on the user's machine. No file, text or field leaves it, so it is safe for health, legal and financial documents.
Setup (once)
Claude Code: claude mcp add sirdas -- npx -y @sirdaspdf/mcp Other MCP clients: {"mcpServers": {"sirdas": {"command": "npx", "args": ["-y", "@sirdaspdf/mcp"]}}} Without MCP: npx sirdas <file.pdf> (add --json for machine output).
Files must live inside the allowed root (default: the directory the server starts in; change it with SIRDAS_ROOT).
The default workflow
- Always start with
read_document. One call unlocks restricted PDFs, runs OCR on scans, identifies the type, extracts key fields with page citations, anonymizes personal data, finds tables and returns cited chunks plusnext_steps. - Tell the user what it is, in one line: type, pages, the 3–5 most useful fields (cite the page).
- Offer the
next_stepsproactively, as a short choice — don't run write operations without a yes. - If
statusisneeds_passwordorwrong_password, ask the user and call again withpassword. Never guess or brute-force.
Choosing the next tool
| The user wants… | Tool |
|---|---|
| Ask an AI about a sensitive document | prompt private_ai_answer (anonymize → answer → deanonymize_text) |
| Index for search / RAG | pdf_to_chunks (use id as vector id; store pages, section) or prompt index_pdf_for_rag |
| Invoice lines or statement movements in Excel | pdf_tables |
| Just the fields from text you already have | extract_fields |
| What changed between two versions | compare_pdfs |
| Password on / off | protect_pdf / unlock_pdf |
| Remove, keep or rotate pages | edit_pages |
| «Página X de Y», CONFIDENCIAL stamp | add_page_numbers, add_watermark |
| Join / split / shrink | merge_pdfs, split_pdf, compress_pdf_lossless |
| Training data from many PDFs | pdf_to_dataset, find_duplicates, check_contamination |
Honesty rules
- Type detection and field extraction are rule-based: say "looks like an invoice" and show the evidence when confidence is below 0.6.
- Anonymization can miss unusual formats: suggest a quick review before sharing outside.
- A watermark or copy restriction is not real protection; a password (AES-256) is.