---
title: "oneocr cookbook"
url: https://recursiveai.org/oneocr/cookbook/
description: "Short recipes for common OneOcr tasks, each with complete code you can copy."
version: "1.0.0"
---

# oneocr cookbook

Short recipes for common OneOcr tasks, each with complete code you can copy.

## Recipes

- [Invoices as fields](https://recursiveai.org/oneocr/cookbook/invoices/index.md): Read an invoice image into typed fields with their EN 16931 business-term ids, line items included, and see which words and box each value came from.
- [Receipts](https://recursiveai.org/oneocr/cookbook/receipts/index.md): Read a till receipt into merchant, date, time, totals, payment method and items, each with the words it was read from.
- [Save and load the page as JSON](https://recursiveai.org/oneocr/cookbook/page-json/index.md): Write a page to oneocr.page JSON, the documented and versioned format, and read it back under limits.
- [Words to check](https://recursiveai.org/oneocr/cookbook/words-to-check/index.md): Use calibrated confidence to find the words a person should look at, on a grainy, tilted copy of the receipt.
- [Same bytes on every machine](https://recursiveai.org/oneocr/cookbook/same-bytes-everywhere/index.md): Check that the text, boxes and confidences don’t depend on the thread count or the CPU’s vector instructions.
- [PDF pages](https://recursiveai.org/oneocr/cookbook/pdf-pages/index.md): Read a PDF whose page has both real text and a scanned image: the text layer is used where it exists, the image is read with OCR, and every word says which.
- [The oneocr command line](https://recursiveai.org/oneocr/cookbook/command-line/index.md): Read images from a shell or a script with the oneocr tool: text to stdout, or a folder of pages to .txt and .page.json files.
