IBM Granite Docling V2 2B: From PDF to Structured AI-Ready Data

IBM Granite Docling V2 2B: From PDF to Structured AI-Ready Data

Granite Docling V2 2B AI Document Parsing Guide

TL;DR

Granite Docling V2 2B is a compact, open source vision language model that converts a document page image into a structured, machine readable representation called DocLang. Unlike traditional OCR, it preserves headings, paragraphs, tables, formulas, code, images, captions, reading order, and element positions in one pass. It is designed for organizations that need high fidelity document conversion for retrieval augmented generation, compliance workflows, research automation, and enterprise AI agents.

ELI5 Introduction

Imagine you have a stack of PDFs: contracts, invoices, research papers, insurance forms, financial reports, and scanned letters. A person can look at a page and instantly understand what is a title, what is a paragraph, which numbers belong in a table, and what order to read the information.

Traditional OCR is like a machine that reads the words but often loses the map. It may recognize text, yet struggle to know whether a number belongs to a table cell, a footnote, a chart label, or a paragraph.

Granite Docling V2 2B is designed to solve that problem. It looks at a page image and produces a structured document record that includes both the content and the layout. It identifies headings, paragraphs, lists, tables, formulas, code, pictures, captions, headers, and footers. It also records where each element appears on the page and the order in which a reader should encounter it.

The output format is called DocLang. Think of it as a precise blueprint of the page. It can later be exported into Markdown, HTML, or JSON, making the information easier to search, analyze, store, and use in AI applications.

For a business, this means documents no longer need to remain static files. They can become reliable inputs for search, analytics, compliance review, customer service, and intelligent automation.

Detailed Analysis

What Is Granite Docling V2 2B?

Granite Docling V2 2B is a compact vision language model developed by the Docling team at IBM. It takes a page image as input and generates DocLang, a structured markup vocabulary that captures the type, position, reading order, and content of document elements.

It is the larger and more accuracy focused member of the Granite Docling V2 family. Its sibling model, Granite Docling V2 500M, is designed for higher throughput and uses a density router that allocates additional vision processing only to dense pages.

The 2B model is particularly suited to complex, information dense documents where structural fidelity matters. Examples include scientific papers, financial filings, technical manuals, legal agreements, insurance forms, engineering drawings, and scanned business records.

What “2B” Means

The label “2B” refers to the model’s approximate parameter scale. The base model has about 2.48 billion parameters, while the checkpoint with multi token prediction heads totals about 2.68 billion parameters. The MTP heads support speculative decoding and are used to accelerate generation rather than to change the core document conversion task.

What It Produces

A single conversion pass can produce:

  • Headings and paragraph text
  • Nested lists
  • Tables with header cells, merged cells, and full cell structure
  • LaTeX formulas
  • Inline math, superscripts, and subscripts
  • Code blocks
  • Pictures, captions, and text embedded within images
  • Page headers and footers
  • Bounding boxes for document elements
  • Reading order information

This makes Granite Docling V2 2B more than an OCR engine. It is a document understanding and conversion system.

Why Document Structure Matters

Most enterprise AI initiatives fail not because models cannot generate language, but because they receive poorly structured inputs. A retrieval system fed by flat, fragmented OCR text may return the right words without preserving the relationships that give those words meaning.

Consider a financial report. A traditional OCR pipeline may extract every number correctly, but it may not preserve whether a value belongs to a revenue line, a footnote, a table header, or a chart. That ambiguity creates downstream risk.

Granite Docling V2 2B addresses this by making structure part of the output. Every element carries a type and bounding box. Tables retain their cell structure. Formulas remain represented as LaTeX. Captions stay connected to the images or tables they describe.

This structural awareness is especially valuable for:

  • Retrieval augmented generation, where answers should cite the correct source context
  • Regulatory review, where traceability and provenance are essential
  • Financial analysis, where tables and footnotes must remain connected
  • Scientific research, where equations and figures carry essential meaning
  • Contract intelligence, where clauses, schedules, and defined terms need reliable boundaries
  • Claims processing, where form fields and handwritten entries must be interpreted in context

Need to turn your document estate into structured, AI ready data? Our AI Document Processing Service converts PDFs, scans, and complex tables into clean, structured inputs for RAG, analytics, and enterprise AI.

Explore AI Document Processing Service

From OCR to Document Intelligence

Traditional OCR answers a narrow question: “What text appears on this page?”

Granite Docling V2 2B answers a broader question: “What is on this page, how is it organized, and how should it be interpreted?”

Capability Traditional OCR Granite Docling V2 2B
Text extraction Yes Yes
Layout preservation Limited Strong
Table structure Often fragmented Preserved with cell structure
Reading order Often inferred Explicitly captured
Formulas Usually lost or distorted Converted to LaTeX
Images and captions Often separated Captured with context
Output format Plain text DocLang, exportable to Markdown, HTML, or JSON
AI readiness Requires extensive postprocessing Designed for downstream systems

The distinction matters because enterprise value comes from context. A document conversion model that preserves relationships enables more reliable automation, more accurate search, and more trustworthy AI generated answers.

Inside DocLang

DocLang is an XML style vocabulary for documents. It records each element’s type, location, content, and position in the reading order.

For example, a heading is not merely a line of text. It is identified as a heading, assigned a bounding box, and placed in the document’s reading sequence. A table is not a loose collection of words and numbers. It is represented with its rows, columns, headers, merged cells, and cell values.

DocLang uses compact tokens for tags and coordinates. Coordinates use a 512 by 512 grid measured from the top left of the page. Tables use OTSL cell tokens, while formulas use LaTeX. This compact representation reduces the token cost of representing a page compared with more verbose formats such as HTML.

Why DocLang Is Useful

DocLang provides a common intermediate representation between raw documents and enterprise systems. It can be validated mechanically and converted losslessly into a DoclingDocument, then exported to Markdown, HTML, or JSON.

That creates several practical advantages:

  • Consistent ingestion: Different document types can enter a common structured pipeline.
  • Better retrieval: Chunks can respect semantic boundaries such as sections, tables, and captions.
  • Auditability: Element positions make it easier to trace an extracted value back to its source.
  • Flexible delivery: Teams can export to the format their applications require.
  • Lower processing overhead: Compact markup reduces the number of tokens needed to represent page structure.

Model Architecture and Performance

Granite Docling V2 2B combines a vision encoder with a language decoder. The vision encoder has 468 million parameters, while the language decoder, including token embeddings, has 1.734 billion parameters. A separate output head adds 274 million parameters.

Related service: AI Adoption Agency offers automation, web development, AI design, and manufacturing services. Fixed pricing from $100. Fast delivery. Browse Our Services →

The model is built from Granite 4.0 1B and has been pruned and distilled for faster decoding.

Accuracy

In IBM’s evaluation across 16,205 pages from nine benchmarks, Granite Docling V2 2B achieved a pooled content score of 96.5 using content one minus normalized edit distance. This metric measures character level similarity across the full page, including table cells, formulas, and code. Missing or invented text counts as an error.

The model card reports that its edit distance fell from 20.6 percent with Granite Docling 258M to 3.5 percent, a sixfold reduction.

These results should be interpreted carefully. IBM states that its benchmark scores use ground truth converted to DocLang and revised by hand, with one scorer and one conversion path for all systems. Therefore, the results are not directly comparable with scores published on original benchmarks or external leaderboards.

Speed

On one H100 80GB GPU, the model card reports throughput of 6.8 pages per second without multi token prediction speculative decoding and 10.1 pages per second with MTP speculative decoding using three draft tokens.

IBM’s launch blog reports a different figure of 3.8 pages per second for the 2B model on one H100. The difference reflects different reporting contexts and deployment configurations, so teams should benchmark the model under their own workload, hardware, batching strategy, and latency requirements.

Multilingual and Handwriting Support

Granite Docling V2 2B offers stronger multilingual performance than its predecessor, particularly for Chinese, Japanese, Korean, Hindi, Russian, and Arabic, as well as mixed Chinese and English pages. It also improves handwriting recognition, although printed text remains more accurate.

For global enterprises, this matters because document estates are rarely monolingual. Supplier invoices, regional contracts, customer correspondence, and technical documentation often combine languages, scripts, layouts, and formatting conventions.

Where Granite Docling V2 2B Fits

Granite Docling V2 2B is most valuable when accuracy and structural fidelity outweigh the need for maximum throughput.

High Value Use Cases

Use case Why the 2B model fits
Financial document processing Preserves tables, footnotes, formulas, and report hierarchy
Scientific and technical research Handles equations, figures, captions, code, and dense layouts
Legal and compliance workflows Maintains clause structure, reading order, and source traceability
Insurance claims Processes forms, handwritten entries, tables, and supporting evidence
Enterprise knowledge retrieval Creates structured context for RAG and semantic search
Back office automation Converts invoices, purchase orders, and statements into actionable data
Historical archive digitization Captures complex layouts and mixed media content
AI agent workflows Supplies agents with reliable, structured page level evidence

When to Consider the 500M Model

Granite Docling V2 500M may be preferable when teams process very large volumes of comparatively simple pages and prioritize throughput. It delivers close accuracy to the 2B model while operating at higher speed, aided by a density router that spends extra compute only on dense pages.

A practical approach is to use the 2B model as the accuracy benchmark and deploy the 500M model where its quality meets the required threshold. Organizations can route dense, high risk, or high value pages to the 2B model while sending simpler pages to the 500M model.

Implementation Strategies

Successful adoption requires more than installing a model. Enterprises should treat document conversion as a production data pipeline with clear quality controls, ownership, and feedback loops.

Start With a Document Inventory

Begin by classifying the document estate. Identify document families, page layouts, languages, scan quality, regulatory sensitivity, and downstream use cases.

A useful starting inventory includes:

  • Document type and business owner
  • Source format, such as PDF, scan, image, or office export
  • Language distribution
  • Page complexity and layout variability
  • Table, formula, chart, and handwriting frequency
  • Required downstream output format
  • Accuracy and latency requirements
  • Privacy, retention, and access control requirements

This inventory prevents teams from treating all documents as if they have the same processing needs.

Build a Conversion Pipeline

A robust pipeline should include the following stages:

  1. Ingest: Collect files from repositories, email, scanners, cloud storage, or business applications.
  2. Preprocess: Normalize image quality, orientation, resolution, and page segmentation where needed.
  3. Convert: Send each page image to Granite Docling V2 2B and generate DocLang.
  4. Validate: Check schema compliance, table integrity, coordinate validity, and confidence indicators.
  5. Export: Transform DocLang into Markdown, HTML, JSON, or a custom enterprise schema.
  6. Enrich: Apply classification, entity extraction, metadata tagging, or business rules.
  7. Index: Store structured content and embeddings for retrieval.
  8. Monitor: Track accuracy, exceptions, throughput, cost, and downstream task outcomes.

The model can run with Hugging Face Transformers, vLLM, MLX, and the Docling library. IBM also provides deployment guidance for vLLM, including settings for batched inference and speculative decoding.

Design for Human in the Loop

No document AI system should operate without exception handling. Build review queues for low confidence pages, unusual layouts, rejected tables, unreadable handwriting, and business critical fields.

The goal is not to eliminate human review everywhere. It is to focus human attention where errors create the greatest business risk.

Ready to wire document AI into your real operations? Our AI Workflow Automation Service designs the routing, validation, and human in the loop layers that make document pipelines reliable in production.

Explore AI Workflow Automation Service

Best Practices and Case Studies

Benchmark on Your Own Documents

Public benchmarks are useful for orientation, but they cannot replace internal evaluation. Build a representative test set from real production documents, including difficult cases such as poor scans, rotated pages, dense tables, handwritten annotations, multilingual content, and complex diagrams.

Evaluate the model against the outcomes that matter:

  • Table cell accuracy
  • Reading order correctness
  • Formula fidelity
  • Field extraction accuracy
  • Retrieval quality
  • Downstream automation success rate
  • Human review rate
  • Cost per page
  • End to end latency

Preserve Source Traceability

Store the original page image, generated DocLang, exported representation, model version, prompt, and processing metadata. This makes it possible to audit why a system extracted a particular value and to reproduce results after model or pipeline changes.

Traceability is especially important in regulated industries. A parsed value should always be traceable to a page, bounding box, and source document.

Use Task Specific Prompts

Granite Docling V2 2B allows teams to request only the output they need, such as tables, formulas, or text with bounding boxes. This can reduce unnecessary generation and make outputs easier to integrate.

For example, an invoice workflow may request tables and key value pairs, while a research workflow may request full page structure, formulas, and figure captions.

Control Decoding Settings

The model card recommends temperature zero for deterministic document conversion. Teams should also use consistent prompts, version pinning, and controlled decoding settings to reduce variability across production runs.

Separate Conversion From Reasoning

Use Granite Docling V2 2B for conversion and structure extraction. Use a separate language model for reasoning, summarization, classification, or answering questions. This separation improves maintainability and makes it easier to upgrade either component independently.

IBM positions Granite Docling as the conversion layer within a broader document AI stack that also includes Granite Vision for visual extraction and Granite Embedding Vision for page retrieval.

Financial Services

A financial services firm processing quarterly reports can use Granite Docling V2 2B to preserve income statements, balance sheets, footnotes, and narrative sections as connected structures. Instead of treating a table as disconnected text, the system can retain row and column relationships, enabling more reliable analysis and audit trails.

Life Sciences

A pharmaceutical organization reviewing clinical study documents can convert dense pages containing protocols, tables, formulas, figures, and references into structured records. Preserving equations and figure captions helps researchers locate evidence and maintain scientific context.

Insurance

An insurer processing claim packets can use the model to interpret forms, policy documents, photographs, handwritten notes, and supporting correspondence. Structured output allows claims systems to route information, validate required fields, and provide reviewers with page level evidence.

Public Sector

A government agency digitizing archived records can preserve the layout of historical documents while making them searchable. The ability to retain reading order and element positions is particularly useful for records with complex columns, annotations, stamps, and mixed media.

Want agents that read, reason, and act on your documents? Our Custom AI Agent Development Service builds agents that consume parsed documents, apply business rules, and trigger downstream actions.

Explore Custom AI Agent Development Service

Risks and Governance

Granite Docling V2 2B is released under the Apache 2.0 license, which supports broad adoption and integration.

However, open licensing does not remove operational responsibility. Organizations should still establish governance for sensitive documents, model versioning, output validation, human oversight, and security.

Key controls include:

  • Restrict access to source documents and generated structured data
  • Redact personally identifiable information before processing where appropriate
  • Maintain model and prompt version records
  • Validate critical extracted fields with business rules
  • Use human review for high impact decisions
  • Monitor drift across document types, scanners, and languages
  • Establish rollback procedures for model or pipeline changes

Actionable Next Steps

  1. Select a bounded pilot. Choose one document family with clear business value, such as invoices, research papers, claims forms, or financial reports.
  2. Create a golden test set. Curate representative pages, including difficult layouts and edge cases.
  3. Deploy the model in a controlled environment. Start with vLLM or the Docling library, then test throughput, latency, and cost under realistic load.
  4. Measure structure, not only text. Evaluate tables, reading order, formulas, bounding boxes, and downstream task accuracy.
  5. Build exception workflows. Route uncertain or business critical pages to trained reviewers.
  6. Connect DocLang to business systems. Export to JSON or a domain specific schema, then integrate with search, workflow, analytics, or agent platforms.
  7. Establish governance. Define ownership, access controls, audit requirements, model versioning, and quality thresholds before scaling.
  8. Compare model sizes deliberately. Use Granite Docling V2 2B where accuracy is paramount and evaluate the 500M model for high volume, lower complexity workloads.

Conclusion

Granite Docling V2 2B represents a practical shift from text extraction to document understanding. By converting page images into DocLang, it preserves not only what a document says but also how it is organized, where elements appear, and how they should be read.

For enterprises building AI systems, that distinction is strategic. Reliable document conversion improves retrieval quality, strengthens automation, supports compliance, and gives AI agents trustworthy context. The 2B model is best positioned as the accuracy focused option for complex, high value documents, while the broader Granite and Docling ecosystem provides complementary capabilities for visual extraction, retrieval, and deployment.

Organizations that treat document intelligence as a governed data pipeline, rather than a one time OCR project, will be best placed to turn their document estates into a durable competitive advantage.

We Help Businesses Adopt AI

AI Adoption Agency offers automation, web development, AI design, and manufacturing services. Fixed pricing from $100. Fast delivery.

Browse Our Services
Shopping Cart

Your cart is empty

You may check out all the available products and buy some in the shop

Return to shop