chandra-ocr

Installation
SKILL.md

Chandra OCR

Overview

Chandra (package chandra-ocr 0.2.0, model datalab-to/chandra-ocr-2) is a vision-language OCR model. For each page it produces HTML with layout labels (text, table, image, header, footer and so on), from which it derives Markdown, HTML and a list of layout chunks with bounding boxes. It covers 90+ languages, math, handwriting and checkbox forms. There are two inference methods: vllm (default; talks to a vLLM server, the base install is lightweight) and hf (loads the model locally with PyTorch and Transformers).

Licensing: the code is Apache 2.0, but the model weights use a modified OpenRAIL-M licence (free for research, personal use and startups under 2 million USD funding or revenue; not for competing with Datalab's API). Check the README's "Commercial usage" section before using it in a company product. Datalab also sells a hosted API.

Instructions

Install

python -m venv .venv && source .venv/bin/activate
pip install chandra-ocr            # CLI + vLLM client
pip install "chandra-ocr[hf]"      # adds torch, transformers, accelerate for local inference
pip install "chandra-ocr[app]"     # adds the Streamlit demo
Installs
1
GitHub Stars
179
First Seen
1 day ago
Security Audits