back to home

kreuzberg-dev / kreuzberg

A polyglot document intelligence framework with a Rust core. Extract text, metadata, and structured information from PDFs, Office documents, images, and 88+ formats. Available for Rust, Python, Ruby, Java, Go, PHP, Elixir, C#, R, C, TypeScript (Node/Bun/Wasm/Deno)- or use via CLI, REST API, or MCP server.

6,735 stars
320 forks
32 issues
RustHTMLTypeScript

AI Architecture Analysis

This repository is indexed by RepoMind. By analyzing kreuzberg-dev/kreuzberg in our AI interface, you can instantly generate complete architecture diagrams, visualize control flows, and perform automated security audits across the entire codebase.

Our Agentic Context Augmented Generation (Agentic CAG) engine loads full source files into context on-demand, avoiding the fragmentation of traditional RAG systems. Ask questions about the architecture, dependencies, or specific features to see it in action.

Source files are only loaded when you start an analysis to optimize performance.

Embed this Badge

Showcase RepoMind's analysis directly in your repository's README.

[![Analyzed by RepoMind](https://img.shields.io/badge/Analyzed%20by-RepoMind-4F46E5?style=for-the-badge)](https://repomind.in/repo/kreuzberg-dev/kreuzberg)
Preview:Analyzed by RepoMind

Repository Overview (README excerpt)

Crawler view

Kreuzberg Extract text and metadata from a wide range of file formats (88+), generate embeddings and post-process at native speeds without needing a GPU. Key Features • **Extensible architecture** – Plugin system for custom OCR backends, validators, post-processors, and document extractors • **Polyglot** – Native bindings for Rust, Python, TypeScript/Node.js, Ruby, Go, Java, C#, PHP, Elixir, R, and C • **88+ file formats** – PDF, Office documents, images, HTML, XML, emails, archives, academic formats across 8 categories • **OCR support** – Tesseract (all bindings, including Tesseract-WASM for browsers), PaddleOCR (all native bindings), EasyOCR (Python), extensible via plugin API • **High performance** – Rust core with native PDFium, SIMD optimizations and full parallelism • **Flexible deployment** – Use as library, CLI tool, REST API server, or MCP server • **Memory efficient** – Streaming parsers for multi-GB files **Complete Documentation** | **Installation Guides** Installation Each language binding provides comprehensive documentation with examples and best practices. Choose your platform to get started: **Scripting Languages:** • **Python** – PyPI package, async/sync APIs, OCR backends (Tesseract, PaddleOCR, EasyOCR) • **Ruby** – RubyGems package, idiomatic Ruby API, native bindings • **PHP** – Composer package, modern PHP 8.4+ support, type-safe API, async extraction • **Elixir** – Hex package, OTP integration, concurrent processing • **R** – r-universe package, idiomatic R API, extendr bindings **JavaScript/TypeScript:** • **@kreuzberg/node** – Native NAPI-RS bindings for Node.js/Bun, fastest performance • **@kreuzberg/wasm** – WebAssembly for browsers/Deno/Cloudflare Workers, full feature parity (PDF, Excel, OCR, archives) **Compiled Languages:** • **Go** – Go module with FFI bindings, context-aware async • **Java** – Maven Central, Foreign Function & Memory API • **C#** – NuGet package, .NET 6.0+, full async/await support **Native:** • **Rust** – Core library, flexible feature flags, zero-copy APIs • **C (FFI)** – C header + shared library, pkg-config/CMake support, cross-platform **Containers:** • **Docker** – Official images with API, CLI, and MCP server modes (Core: ~1.0-1.3GB, Full: ~1.0-1.3GB with OCR + legacy format support) **Command-Line:** • **CLI** – Cross-platform binary, batch processing, MCP server mode > All language bindings include precompiled binaries for both x86_64 and aarch64 architectures on Linux and macOS. Platform Support Complete architecture coverage across all language bindings: | Language | Linux x86_64 | Linux aarch64 | macOS ARM64 | Windows x64 | |----------|:------------:|:-------------:|:-----------:|:-----------:| | Python | ✅ | ✅ | ✅ | ✅ | | Node.js | ✅ | ✅ | ✅ | ✅ | | WASM | ✅ | ✅ | ✅ | ✅ | | Ruby | ✅ | ✅ | ✅ | - | | R | ✅ | ✅ | ✅ | ✅ | | Elixir | ✅ | ✅ | ✅ | ✅ | | Go | ✅ | ✅ | ✅ | ✅ | | Java | ✅ | ✅ | ✅ | ✅ | | C# | ✅ | ✅ | ✅ | ✅ | | PHP | ✅ | ✅ | ✅ | ✅ | | Rust | ✅ | ✅ | ✅ | ✅ | | C (FFI) | ✅ | ✅ | ✅ | ✅ | | CLI | ✅ | ✅ | ✅ | ✅ | | Docker | ✅ | ✅ | ✅ | - | **Note**: ✅ = Precompiled binaries available with instant installation. WASM runs in any environment with WebAssembly support (browsers, Deno, Bun, Cloudflare Workers). All platforms are tested in CI. macOS support is Apple Silicon only. Embeddings Support (Optional) To use embeddings functionality: • **Install ONNX Runtime 1.24+**: • Linux: Download from ONNX Runtime releases (Debian packages may have older versions) • macOS: • Windows: Download from ONNX Runtime releases • Use embeddings in your code - see Embeddings Guide **Note:** Kreuzberg requires ONNX Runtime version 1.24+ for embeddings. All other Kreuzberg features work without ONNX Runtime. Supported Formats 88+ file formats across 8 major categories with intelligent format detection and comprehensive metadata extraction. Office Documents | Category | Formats | Capabilities | |----------|---------|--------------| | **Word Processing** | , , , , , | Full text, tables, lists, images, metadata, styles | | **Spreadsheets** | , , , , , , , , , | Sheet data, formulas, cell metadata, charts | | **Presentations** | , , , , , | Slides, speaker notes, images, metadata | | **PDF** | | Text, tables, images, metadata, OCR support | | **eBooks** | , | Chapters, metadata, embedded resources | | **Database** | | Table data extraction, field type support | | **Hangul** | , | Korean document format, text extraction | Images (OCR-Enabled) | Category | Formats | Features | |----------|---------|----------| | **Raster** | , , , , , , , | OCR, table detection, EXIF metadata, dimensions, color space | | **Advanced** | , , , , , , , , , | Pure Rust decoders (JPEG 2000, JBIG2), OCR, table detection | | **Vector** | | DOM parsing, embedded text, graphics metadata | Web & Data | Category | Formats | Features | |----------|---------|----------| | **Markup** | , , , , | DOM parsing, metadata (Open Graph, Twitter Card), link extraction | | **Structured Data** | , , , , , | Schema detection, nested structures, validation | | **Text & Markdown** | , , , , , , , | CommonMark, GFM, Djot, MDX, reStructuredText, Org Mode, Rich Text | Email & Archives | Category | Formats | Features | |----------|---------|----------| | **Email** | , | Headers, body (HTML/plain), attachments, UTF-16 support | | **Archives** | , , , , | Recursive extraction, nested archives, metadata | Academic & Scientific | Category | Formats | Features | |----------|---------|----------| | **Citations** | , , , , | BibTeX/BibLaTeX, RIS, PubMed/MEDLINE, EndNote XML, CSL JSON | | **Scientific** | , , , , , | LaTeX, Typst, JATS journal articles, Jupyter notebooks | | **Publishing** | , , , | FictionBook, DocBook XML, OPML outlines | | **Documentation** | , , | Perl POD, man pages, troff | **Complete Format Reference →** Key Features OCR with Table Extraction Multiple OCR backends (Tesseract, EasyOCR, PaddleOCR) with intelligent table detection and reconstruction. Ex…