skillfed

docling-core

A python library to define and validate data types in Docling.

docling-core v2.91.0 6.3M downloads/30d#1,928 on PyPI276
Permissive license MIT Active released

What it is and what it does

Docling Core is the foundational library for the Docling document processing framework. It defines DoclingDocument as a Pydantic model—a strongly-typed, validated data structure for representing structured documents—and provides a suite of APIs built around it. The library is designed to support generative AI workflows that need to ingest, transform, and analyze documents at scale.

The package centers on four main capabilities: the DoclingDocument model itself (with builders and exporters for formats like Markdown and HTML), a pluggable Serialization API for flexible output formats, a Chunking API for breaking documents into semantically meaningful pieces, and a Profiling API for extracting statistics and distributions from individual documents or collections. It depends on Pydantic for validation, Pillow for image handling, pandas for data operations, and several other utilities for LaTeX math, YAML, and XML processing.

Use it for:

  • Build a document ingestion pipeline that parses PDFs or scanned documents into a validated, queryable DoclingDocument structure for RAG systems.
  • Export extracted document content to multiple formats (Markdown, HTML, JSON) for downstream processing or API consumption.
  • Chunk large documents into semantically coherent segments for embedding and vector search in AI applications.
  • Analyze document collections to extract structural metrics (page counts, table distributions, image density) for quality assurance or dataset profiling.
  • Extend the serialization or chunking logic with custom implementations for domain-specific document processing requirements.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Docling Core defines the foundational DoclingDocument data model and provides APIs for serialization, chunking, and profiling of structured document data for generative AI applications.

Yes. Docling Core is actively maintained (release 8 days old), has no known vulnerabilities, uses a permissive MIT license, and offers low install friction. It is production-stable and well-suited for teams building document-centric AI applications. Install if you are working with the Docling framework or need a structured, validated document data model with built-in serialization and chunking.

Install

docling-core on PyPI

pip

pip install docling-core

uv

uv add docling-core

poetry

poetry add docling-core

Installing docling-core

Before you install

Low install friction; pure Python wheel with 13 runtime dependencies. Active maintenance with a release 8 days ago and commits through 2026-08-14. Supports Python 3.10 through 3.14.

License in practice

MIT license (permissive) allows commercial and private use with minimal restrictions—suitable for most projects.

Quickstart

pip install docling-core

from docling_core.types import DoclingDocument
from docling_core.transforms import serialize_document

# Create or load a DoclingDocument
doc = DoclingDocument(...)
markdown_output = serialize_document(doc, format='markdown')

Requires Python 3.10 or later; development setup requires the uv package.

Verify before relying

  • Whether the 13 runtime dependencies (including pandas, pillow, pyyaml) are all required for basic usage or only for specific features.
  • Performance characteristics and memory footprint when processing large document collections.
  • Concrete examples of how the profiling API scales with collection size.

Package facts

License MIT (permissive)
Python support supports the current Python release (<4.0,>=3.10)
Install friction low — pure-Python wheel
Runtime dependencies 13 — jsonschema, pydantic, jsonref, tabulate, pandas, pillow, pyyaml, typing-extensions, typer, latex2mathml, defusedxml, pydantic-settings, doclang
Maintenance actively maintained — 8 days since the last release
Last repo commit
First released
Downloads 6,339,614/month — #1,928 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: docling_core-2.91.0-py3-none-any.whl

Keywords: docling, discovery, etl, information retrieval, analytics, database, database schema, schema, JSON

Development Status :: 5 - Production/StableIntended Audience :: DevelopersIntended Audience :: Science/ResearchNatural Language :: EnglishOperating System :: OS IndependentProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Topic :: DatabaseTopic :: Scientific/Engineering :: Information AnalysisTopic :: Software Development :: Libraries :: Python ModulesTyping :: Typed

Tags

document data model pydanticdocument serialization chunkingdocling document processingdocument profiling statisticsstructured document extractiondocument to markdown htmldocument schema validation
document-processingpydantic-modelsgenerative-ai

More Python Modules packages