Repolode
SoMarkAI

SoMarkAI/OXR

An open-source document parsing model that converts PDFs and document images into Markdown or JSON with layout coordinates, aimed at AI agent pipelines.

Stars
3,668
Forks
240
Open issues
3
Last commit
yesterday

What is it?

OXR (Optical Everything Recognition) is a 1.3B-parameter document parsing model from the SoMark team. It takes PDFs and document images and outputs Markdown or JSON, with layout bounding boxes included, so the results can feed downstream AI agents and retrieval pipelines.

The model recognizes 13 element types, including formulas as LaTeX, tables as HTML or Markdown, chemical equations and structures, code blocks, and stamps. Reading order is handled inside the recognition stage by the same model. Layout analysis is a separate, pluggable module, so teams can swap in their own layout model while keeping OXR's recognition and ordering.

The project provides a Docker image, a from-source setup with vLLM support, a browser demo at port 8000, and a free hosted API compatible with the SoMark API and its Python and JavaScript CLIs. Local deployment expects an NVIDIA GPU with BF16 support, with 24GB of memory as the starting point.

Key features

  • 01Parses PDFs and images into Markdown or JSON with layout bounding boxes.
  • 02Recognizes 13 element types, including formulas, tables, chemical structures and code blocks.
  • 03Handles reading order within the same model as recognition.
  • 04Layout analysis is a separate module that can be replaced with a custom model.
  • 05Offers a Docker deployment, a vLLM-based source setup, and a browser demo.
  • 06Provides an API compatible with the SoMark CLI and SDKs.

Use cases

  • Turning scanned exams, papers or reports into structured text for an LLM or RAG pipeline.
  • Extracting complex tables and formulas from academic documents.
  • Adapting layout analysis to a specific document domain while reusing OXR's recognition.

Quick start

  1. 1

    Install the somark CLI from PyPI

    pip install somark
  2. 2

    Parse a document with the free OXR API (no API key needed)

    somark --base-url https://free-oxr.somark.ai/api/v1 --api-key dummy parse document.pdf --formats md,json --out ./parsed-output/

Things to know

  • Running it locally needs a Linux machine with an NVIDIA GPU, at least 24GB of GPU memory.
  • The free API has no stability guarantee and is not recommended for production use.
  • The README does not state a clear software license, so check the repository before commercial use.

In collections

Topics

FAQ

What is OXR?
An open-source document parsing model that converts PDFs and document images into Markdown or JSON with layout coordinates, aimed at AI agent pipelines. OXR (Optical Everything Recognition) is a 1.3B-parameter document parsing model from the SoMark team. It takes PDFs and document images and outputs Markdown or JSON, with layout bounding boxes included, so the results can feed downstream AI agents and retrieval pipelines.
Is OXR free to use? What license does it have?
OXR is open source under the Other license. Check the license terms before using it in commercial products.
Is OXR still maintained?
Actively maintained. The last commit to OXR was on Nov 6, 2026.
What can I use OXR for?
Turning scanned exams, papers or reports into structured text for an LLM or RAG pipeline. Extracting complex tables and formulas from academic documents. Adapting layout analysis to a specific document domain while reusing OXR's recognition.
How do I install OXR?
Install the somark CLI from PyPI: pip install somark Parse a document with the free OXR API (no API key needed): somark --base-url https://free-oxr.somark.ai/api/v1 --api-key dummy parse document.pdf --formats md,json --out ./parsed-output/
Where can I get OXR?
The source code and installation instructions are on GitHub: https://github.com/SoMarkAI/OXR

Summary generated by AI from the project's README. GitHub stats refresh daily.

Related projects