/ Annuaire / Playground / Kreuzberg
● Communauté kreuzberg-dev ⚡ Instantané

Kreuzberg

par kreuzberg-dev · kreuzberg-dev/kreuzberg

Extrayez du texte, des tableaux et des métadonnées propres à partir de PDF, de documents Office, d'images et de plus de 97 autres formats — via un MCP Rust-core.

Kreuzberg est un cadre d'intelligence documentaire polyglotte. Le serveur MCP enveloppe le pipeline Rust de base : Claude l'appelle pour extraire du contenu structuré de n'importe quel format de document sans que vous ne déboursiez vers Unstructured/Tika/pdfplumber. Gère l'OCR pour les PDF numérisés, la détection de table et les métadonnées en un seul appel.

Pourquoi l'utiliser

Fonctionnalités clés

Démo en direct

Aperçu en pratique

kreuzberg.replay ▶ prêt
0/0

Installer

Choisissez votre client

~/Library/Application Support/Claude/claude_desktop_config.json  · Windows: %APPDATA%\Claude\claude_desktop_config.json
{
  "mcpServers": {
    "kreuzberg": {
      "command": "uvx",
      "args": [
        "kreuzberg-mcp"
      ]
    }
  }
}

Ouvrez Claude Desktop → Settings → Developer → Edit Config. Redémarrez après avoir enregistré.

~/.cursor/mcp.json · .cursor/mcp.json
{
  "mcpServers": {
    "kreuzberg": {
      "command": "uvx",
      "args": [
        "kreuzberg-mcp"
      ]
    }
  }
}

Cursor utilise le même schéma mcpServers que Claude Desktop. La config projet l'emporte sur la globale.

VS Code → Cline → MCP Servers → Edit
{
  "mcpServers": {
    "kreuzberg": {
      "command": "uvx",
      "args": [
        "kreuzberg-mcp"
      ]
    }
  }
}

Cliquez sur l'icône MCP Servers dans la barre latérale Cline, puis "Edit Configuration".

~/.codeium/windsurf/mcp_config.json
{
  "mcpServers": {
    "kreuzberg": {
      "command": "uvx",
      "args": [
        "kreuzberg-mcp"
      ]
    }
  }
}

Même format que Claude Desktop. Redémarrez Windsurf pour appliquer.

~/.continue/config.json
{
  "mcpServers": [
    {
      "name": "kreuzberg",
      "command": "uvx",
      "args": [
        "kreuzberg-mcp"
      ]
    }
  ]
}

Continue utilise un tableau d'objets serveur plutôt qu'une map.

~/.config/zed/settings.json
{
  "context_servers": {
    "kreuzberg": {
      "command": {
        "path": "uvx",
        "args": [
          "kreuzberg-mcp"
        ]
      }
    }
  }
}

Ajoutez dans context_servers. Zed recharge à chaud à la sauvegarde.

claude mcp add kreuzberg -- uvx kreuzberg-mcp

Une seule ligne. Vérifiez avec claude mcp list. Supprimez avec claude mcp remove.

Cas d'usage

Usages concrets : Kreuzberg

Extraire les tableaux d'un PDF en désordre dans un markdown propre

👤 Analystes traitant des rapports PDF ⏱ ~10 min beginner

Quand l'utiliser : Vous avez un PDF avec des tables qui pdftotext mangles et vous ne voulez pas les retaper.

Prérequis
  • MCP installeduvx kreuzberg-mcp — or add via claude mcp add
Déroulement
  1. Extract
    Use kreuzberg to extract /docs/2025-annual-report.pdf. Give me the tables as markdown and the body text separately.✓ Copié
    → Clean markdown tables with preserved headers
  2. Verify
    For the "Revenue by Segment" table, reconcile the column totals. Flag any OCR misreads.✓ Copié
    → Arithmetic check with flagged cells

Résultat : Markdown tables you can paste into a doc without rework.

Pièges
  • Scanned PDF — OCR mistakes 6 for 8 — Use the OCR confidence output and re-scan low-confidence cells manually
Combiner avec : filesystem

Ingest a folder of mixed-format docs for downstream indexing

👤 Engineers building RAG pipelines ⏱ ~30 min intermediate

Quand l'utiliser : Client drops you a zip with PDFs, Word docs, PowerPoints, and you need clean text for embedding.

Prérequis
  • Filesystem MCP scoped to the folder — Launch fs MCP with the ingest dir as root
Déroulement
  1. Inventory
    List every file under /ingest/. For each, call kreuzberg.detect_format and report.✓ Copié
    → Format-per-file table
  2. Bulk extract
    For each file, extract text + metadata. Write cleaned .txt next to the original and a manifest.json with metadata.✓ Copié
    → All files processed; manifest contains every entry
  3. Quality check
    List every file where extraction returned <100 chars — those are likely scanned or corrupt. Re-run with OCR forced.✓ Copié
    → Low-content files identified and retried

Résultat : A folder of cleaned text files ready for embedding, with a metadata manifest.

Pièges
  • Encrypted PDF — Kreuzberg returns an error — decrypt with qpdf or ask for the unlocked copy
Combiner avec : filesystem · memory

Combinaisons

Associez-le à d'autres MCPs pour un effet X10

kreuzberg + filesystem

Walk a folder and extract every doc in place

For each PDF under /docs, extract text and save as .md next to it.✓ Copié
kreuzberg + memory

Ingest extracted content into a knowledge graph

Extract /contracts/*.pdf and store key terms in memory for cross-doc querying.✓ Copié

Outils

Ce que ce MCP expose

OutilEntréesQuand appelerCoût
extract_text path: str, ocr?: bool Primary extraction call free
extract_metadata path: str Just want metadata without body text free
extract_tables path: str Table-focused extraction free
detect_format path: str Confirm format before extraction free

Coût et limites

Coût d'exécution

Quota d'API
Unlimited — local
Tokens par appel
Proportional to doc size; a 20-page PDF ≈ 8k tokens of output
Monétaire
Free (open source)
Astuce
Use extract_metadata first on large files to avoid processing irrelevant ones

Sécurité

Permissions, secrets, portée

Stockage des identifiants : None for local mode
Sortie de données : None — all processing is local

Dépannage

Erreurs courantes et correctifs

ModuleNotFoundError: tesseract

Install Tesseract system binary: brew install tesseract / apt install tesseract-ocr

Vérifier : `tesseract --version`
Empty output on PDF

Likely image-only PDF — re-run with ocr=true

Vérifier : Check output.metadata.has_text_layer
XLSX tables come out jumbled

Pass sheet name explicitly: tool supports sheet arg

Alternatives

Kreuzberg vs autres

AlternativeQuand l'utiliserCompromis
markdownify-mcpYou want a lighter, Node-based converter without OCRFewer formats, no table preservation
Unstructured.ioYou need enterprise PDF parsing and accept the cloud costPaid; cloud-hosted

Plus

Ressources

📖 Lire le README officiel sur GitHub

🐙 Voir les issues ouvertes

🔍 Parcourir les 400+ serveurs MCP et Skills