No description
  • Python 99.5%
  • Shell 0.5%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Florian Egger 73b3032069 Document testing endpoint policy and mark version as 0.1.0-dev
- Updates AGENTS.md to clarify that production must keep invoice data

  on the same host as the model runtime, while shared LAN endpoints

  are acceptable for integration testing and staging.

- Bumps pyproject.toml version to 0.1.0-dev and adds development status

  classifiers.

- Adds CHANGELOG.md with Unreleased and 0.1.0 entries.
2026-08-21 17:03:03 +02:00
.agents/skills Add review skill and make review stage mandatory in AGENTS.md 2026-08-21 14:06:48 +02:00
prompts Initial scaffold: local invoice OCR pipeline with Ollama, classifier branches, structured extraction, review, and Odoo XML export 2026-08-21 14:04:42 +02:00
scripts Initial scaffold: local invoice OCR pipeline with Ollama, classifier branches, structured extraction, review, and Odoo XML export 2026-08-21 14:04:42 +02:00
src/odoo_ocr Add CLI orchestration with confidence-gated XML output 2026-08-21 16:44:35 +02:00
tests Add CLI orchestration with confidence-gated XML output 2026-08-21 16:44:35 +02:00
.gitignore Add review skill and make review stage mandatory in AGENTS.md 2026-08-21 14:06:48 +02:00
AGENTS.md Document testing endpoint policy and mark version as 0.1.0-dev 2026-08-21 17:03:03 +02:00
CHANGELOG.md Document testing endpoint policy and mark version as 0.1.0-dev 2026-08-21 17:03:03 +02:00
config.yaml Initial scaffold: local invoice OCR pipeline with Ollama, classifier branches, structured extraction, review, and Odoo XML export 2026-08-21 14:04:42 +02:00
pyproject.toml Document testing endpoint policy and mark version as 0.1.0-dev 2026-08-21 17:03:03 +02:00
README.md Initial scaffold: local invoice OCR pipeline with Ollama, classifier branches, structured extraction, review, and Odoo XML export 2026-08-21 14:04:42 +02:00
uv.lock Add uv.lock and bump mypy target to 3.12 2026-08-21 16:44:04 +02:00

odoo_ocr

Local-first invoice OCR pipeline that reads scanned, printed, handwritten, and native-PDF invoices and produces Odoo Enterprise-ready XML.

Quick start

  1. Install dependencies:

    uv sync --all-extras
    # or
    pip install -e ".[dev]"
    
  2. Configure config.yaml or set environment variables:

    export OLLAMA_BASE_URL="http://100.103.83.12:11435"
    
  3. Run the pipeline:

    odoo-ocr process /path/to/invoices --output ./out/
    

Architecture

Input File
  → Classifier (heuristic + small VLM)
    → Branch: digital_pdf      → text/layout extraction
    → Branch: scanned_print    → preprocess → VLM OCR
    → Branch: handwritten      → preprocess → GLM-OCR
    → Branch: mixed_unknown    → preprocess → ensemble OCR
      → Structured Extraction VLM
      → Review VLM (image vs extracted JSON)
        → Confidence check
          → XML Builder
            → Odoo XML + sidecar JSON

Project-specific agent skills

Agent skills are in .agents/skills/:

  • odoo-ocr-pipeline — classifier, branches, extraction, review.
  • odoo-xml-import — generating and validating Odoo XML.
  • local-vlm-client — Ollama/llama.cpp VLM clients and prompts.