inference.eu

OCR and documents · DeepSeek

Run DeepSeek-OCR 2 in the EU to turn documents into Markdown through an OpenAI-compatible API

DeepSeek-OCR 2 is a compact open model that reads document images and returns their text, usually as Markdown with headings, tables and layout preserved. It suits invoices, contracts, forms and scanned archives. On inference.eu you call it with the OpenAI request format, with your documents processed in EU data centres, never sent to China and never used for training.

  1. 013B
  2. 02EU data centres
  3. 03Apache 2.0

What DeepSeek-OCR 2 is

DeepSeek-OCR 2 was released by DeepSeek in January 2026 under the Apache 2.0 licence. It has about 3 billion parameters and pairs a new vision encoder, DeepEncoder V2, with a small mixture-of-experts language decoder. Its paper, titled Visual Causal Flow, describes an encoder that reorders visual information in a reading order closer to how people scan a page.

The model compresses each page into a small number of visual tokens: with dynamic resolution, between 256 and 1,120 tokens per page. That keeps processing cheap even for dense pages. DeepSeek reports a 3.73 percent improvement over the first DeepSeek-OCR on the OmniDocBench document parsing benchmark.

What it does well, and where it falls short

DeepSeek-OCR 2 is built for document parsing: converting pages into structured Markdown with headings, lists and tables, or extracting plain text. It handles complex layouts such as multi-column pages and forms, and its small size makes it practical for large back-office archives where thousands of pages are processed every day.

It is a specialised model, not a general assistant. It reads and transcribes, but does not reason well about the content or answer open questions about it; pass its output to a chat model such as Qwen3.8 27B or DeepSeek V4 Flash for that. Handwriting, very low-quality scans and unusual scripts can reduce accuracy, so check results on samples of your own documents.

Calling DeepSeek-OCR 2 through the API

inference.eu uses the OpenAI request format. Set the base URL to the inference.eu API, use your inference.eu key and set the model to deepseek-ocr-2. Send one page image per request as an image_url content part, with a short text prompt in the same message.

DeepSeek's model card shows two prompts: Convert the document to markdown. for structured output with layout, and Free OCR. for plain text. For PDFs, render each page to an image first and send pages in parallel. Store the Markdown result next to the original file, then embed it with bge-m3 or Qwen3 Embedding 8B to make the archive searchable.

Data residency for DeepSeek-OCR 2

Documents sent to an OCR model are often the most sensitive files a company holds: identity documents, payslips, medical letters and signed contracts. On inference.eu, DeepSeek-OCR 2 runs on infrastructure in the European Union. Page images and extracted text are processed in EU data centres, are not sent to DeepSeek or to China, and are never used to train any model.

Every customer receives a data processing agreement under Article 28 of the GDPR and our subprocessor list, so your records of processing can name every party involved. Billing is in euros. The Apache 2.0 licence allows commercial use without user limits.

deepseek-ocr-2 · Python
import os
from openai import OpenAI

client = OpenAI(base_url="https://api.inference.eu/v1", api_key=os.environ["INFERENCE_EU_API_KEY"])

response = client.chat.completions.create(
    model="deepseek-ocr-2",
    messages=[{"role": "user", "content": "Summarise this contract in five bullet points."}],
)
print(response.choices[0].message.content)

What teams use it for

  • 1

    Invoice and receipt capture

    Extract supplier, amounts and line items from scanned invoices before posting them to accounting.

  • 2

    Digitising paper archives

    Turn scanned contracts, letters and reports into searchable Markdown for document management and RAG.

  • 3

    Forms and applications

    Read filled-in forms in insurance, banking or public administration and pass the text to validation steps.

DeepSeek-OCR 2: common questions

The questions buyers, developers and legal teams ask us most. Something missing? Ask us directly.

Ask a question

Move your AI workloads to EU infrastructure

Tell us which models you use and roughly how much traffic you have. We reply within one working day with pricing and next steps.

  • Reply within one working day
  • Pricing for your volume
  • DPA ready to sign