Paperless AI
German paperwork filed by an LLM: title, sender, type, amount, deadline, and a short summary in Arabic.
LLMStructured outputPythonPaperless-ngxCost guard
Problem
German letters arrive constantly, and deadlines hide in long paragraphs. I wanted every document sorted and every deadline reminded, without reading each one twice.
Architecture
- 01 Scan / upload
- 02 OCR
- 03 LLM, no tools, JSON schema
- 04 Title · type · amount · deadline
- 05 Reminder push
Key decisions
- The model gets no tools and answers only through a strict JSON schema. Document text is treated as data, never as instructions.
- One model call per document does everything (classification, amounts, deadlines, tax relevance), which keeps cost predictable.
- A hard monthly budget with a shared lock: every AI feature reserves its maximum cost before calling and records the real cost after.
- It never overwrites values I corrected by hand.
What I learned
- Structured output plus validation beats clever prompting.
- Cost control has to be designed in from the first line, not added later.
Repository
Repository coming soon