█

AI/TLDR

Buy me a coffee
Buy me a coffee

Xberg

Polyglot document intelligence: text, tables, and code from 106 formats

Parsing & IngestionOpen source
Language
Rust
License
MIT
$pip install xberg
IN SHORT

What is Xberg?

Xberg is an open-source document intelligence engine built on a Rust core. The project describes itself as the next iteration of Kreuzberg — the same engine, rebuilt and rebranded under a fresh v1 line. It sits in the Parsing & Ingestion category of the Retrieval & Knowledge (RAG) tools and is open-source, written in Rust and licensed MIT.

Overview

Xberg is an open-source document intelligence engine built on a Rust core. The project describes itself as the next iteration of Kreuzberg — the same engine, rebuilt and rebranded under a fresh v1 line. Point it at a PDF, a spreadsheet, a scanned image, an audio file, a URL, an archive, or a source tree and it returns clean text, tables, metadata, and structured data.

One core handles format detection, reading, OCR, and extraction, so you do not assemble a pipeline from a dozen libraries. It covers 106 document formats across 140 file extensions, adds code intelligence for 371 programming languages, and emits six output formats: plain text, Markdown, Djot, HTML, a JSON tree, or Docling DocTags.

The same engine is callable from 15 language bindings — Rust, Python, Node.js, Go, Java, C#, Ruby, PHP, Elixir, Dart, Swift, Zig, WASM, Kotlin, and C FFI — and runs as a library, a CLI, a REST API (`xberg serve`), an MCP server, a Docker image, or a Helm chart. It is MIT-licensed and runs on CPU by default, with no GPU required.

What it does

  • Reads 106 document formats across 140 file extensions, with MIME detection and bounded extraction controls
  • OCR on demand through Tesseract, PaddleOCR, Candle, or VLM backends, with fallback chains and confidence scores
  • ML layout models and table-structure models reconstruct reading order and cell grids for clean Markdown
  • Code intelligence for 371 programming languages: functions, classes, imports, symbols, docstrings, and syntax-aware chunking
  • Recursive archive traversal (.zip, .tar, .gz, .7z) guarded by zip-bomb, compression-ratio, and nesting-depth limits
  • Optional URL ingestion and crawling, audio/video transcription via Whisper ONNX, embeddings, and reranking
  • 15 language bindings plus library, CLI, REST API, MCP server, Docker, and Helm deployment modes

Getting started

Xberg ships prebuilt language packages that bundle the common feature set. Pick the binding that matches your stack, or run the container to use it as a service.

Install for Python

The PyPI package wraps the Rust core with the common features prebuilt.

bashbash
pip install xberg

Install for Node.js

The Node.js package is published under the xberg-io scope; a WASM build is also available as @xberg-io/xberg-wasm.

bashbash
npm install @xberg-io/xberg

Add to a Rust project

Use the core crate directly for feature-flag control over URL ingestion, transcription, reranking, and layout models.

bashbash
cargo add xberg

Run it as a service

The container image on GitHub Container Registry runs the CLI, the REST API, or the MCP server without installing a language binding. A Helm chart is documented for Kubernetes.

bashbash
docker pull ghcr.io/xberg-io/xberg:latest

Commands and code are distilled from the project's own documentation — always check the official repo for the latest.

When to use it

  • Building a RAG pipeline that needs clean text and metadata from mixed document types such as PDFs, Office files, and emails
  • Running OCR on scanned PDFs and images to recover searchable text without setting up a GPU
  • Indexing source code repositories by extracting functions, classes, and imports across hundreds of programming languages
  • Exposing a shared extraction service to many apps through the REST API or MCP server, callable from 15 languages

How Xberg compares

Xberg alongside other open-source parsing & ingestion tools AI/TLDR tracks, ranked by GitHub stars.

ToolStarsWhat it does
MarkItDown★ 199kA Microsoft Python utility that converts many file types, including Office docs and PDFs, into Markdown for LLMs.
MinerU★ 84.6kA document extraction tool that converts PDFs and Office files into clean Markdown or JSON, with strong handling of complex layouts and CJK content.
Docling★ 71.2kAn IBM-originated document conversion pipeline that turns PDF, DOCX, PPTX, HTML, and more into structured, LLM-ready Markdown or JSON.
Marker★ 41.1kA fast pipeline that converts PDFs and other documents to Markdown, JSON, or HTML while preserving tables, equations, and formatting.
OpenDataLoader PDF★ 30.4kOpenDataLoader PDF turns any PDF into structured Markdown, JSON, or HTML with bounding boxes, and auto-tags untagged files into screen-reader-ready Tagged PDFs.
Repomix★ 29.5kRepomix packs an entire repository into one file that is easy to feed to AI tools like Claude, ChatGPT, and Gemini.
Unstructured★ 15.8kA library for ingesting and preprocessing many document types into clean, chunked elements ready for RAG pipelines.
Xberg★ 9.6kPolyglot document intelligence: text, tables, and code from 106 formats