cloudinit-bot 3746f03c58 docs(extraction-contract): refresh 4 stale pipelines/common.py line refs (REQ-INB-32)
The extraction-contract.md doc cited 4 line ranges in
pipelines/common.py that drifted past the v1.0 + v1.1
line-shuffle (the v1.1 EXECUTE stage added ~70 lines to
the LLM block: 30+ to LLMConfig.from_env and ~25 to
_ollama_call_one_model, plus a reshape of opencode_run_command).

This commit updates the 4 cites to the post-v1.1 line
positions:
- line 40: 467-468 → 545-546 (default_model / extract_model
  env defaults in LLMConfig.from_env)
- line 98: 414-479 → 492-585 (LLMConfig class range)
- line 102: 605-624 → 636-680 (_ollama_call_one_model
  function range)
- line 161: 378-407 → 440-487 (opencode_run_command
  function range)

The contract semantics (model pin, prompt path, JSON parse)
are unchanged — only the line refs are updated. The
surrounding prose is preserved verbatim.

Verified: grep -n 'pipelines/common.py:' docs/extraction-contract.md
shows the 4 new ranges and zero hits to the stale ranges
(467-468, 414-479, 605-624, 378-407).

---ci---
project: inboxos
phase: 1
milestone: v1.3
status: execute
tasks_completed: [T2.4]
candidates_closed: [REQ-INB-32]
files_touched:
  - docs/extraction-contract.md (4 line-ref substrings replaced, lines 40, 98, 102, 161)
---/ci---
2026-06-08 23:26:11 +00:00

InboxOS

Self-hosted personal ERP / CRM pipeline. A single Gmail inbox, polled over IMAP, archived to SeaweedFS, classified and extracted by a local LLM (Ollama), and written to NocoDB as structured records. Curated attachments are mirrored to Papra. No third-party SaaS touches PII.

Where to start

  • Operations runbook — docs/operations-runbook.md. System overview, service inventory, workflow operations, observability, failure modes, security, cost, glossary. The first thing to read on day 1 of incident response.
  • Extraction contract — docs/extraction-contract.md. How a raw email becomes a NocoDB record. Source of truth for the inboxos:classify + inboxos:extract-<module> prompt family.
  • NocoDB schema — docs/schemas.md. The four module tables (finance, crm, intel, promotions) and the Message-ID idempotency contract.
  • Gitea Actions setup — docs/gitea-actions.md. Runner provisioning (including the second runner for live + historical parallelism), repo secrets, the Basic Auth model.
  • Pipelines — pipelines/README.md. Flow diagrams, idempotency model, rollback procedure for the live and historical pipelines.
  • Papra write policy — docs/papra-write-policy.md. When the pipeline writes to Papra (attachments + selected bodies), and why the first ship is dry-run.

Quick layout

inboxos/
├── README.md                     # this file
├── .env.example                  # placeholder env (no real secrets)
├── docker/
│   └── docker-compose.yml        # self-hosted stack: gitea, runners, nocodb, seaweedfs, papra, ollama
├── .gitea/workflows/
│   ├── live-pipeline.yml         # cron */5 * * * *, polls IMAP
│   ├── historical-pipeline.yml   # workflow_dispatch, streams .mbox
│   └── ci-pr.yml                 # fast-tests + 100MB e2e + live Ollama smoke
├── pipelines/                    # shared Python: common.py, live_pipeline.py, historical_pipeline.py, mbox_stream.py
├── .opencode/commands/           # version-controlled extraction prompts (prompt-as-code)
├── config/                       # n8n config (legacy, no longer in use)
└── docs/                         # this runbook + schemas + contracts + reports

Status

Phase 5 — Full Deployment. Parent goal: INB-1. Current phase issue: INB-7. The runbook in docs/operations-runbook.md is the canonical reference for ongoing operation.

Historical archive (Google Takeout .mbox)

The full Google Takeout .mbox export lives in SeaweedFS at the canonical S3 URI:

s3://inboxos/eml/historical/all-mail.mbox

That is the value to pass as the mbox_object_key workflow_dispatch input to historical-pipeline.yml. To verify it exists, run from any host with mc configured against the inboxos bucket:

mc ls --recursive inboxos/inboxos/ | grep '\.mbox$'

The historical pipeline streams this object message-by-message, UPSERTs each into NocoDB on Message-ID, and writes the raw .eml backup under s3://inboxos/eml/historical/<yyyy>/<mm>/<dd>/<Message-ID>.eml. See docs/operations-runbook.md §3.2 for the dispatch recipe and §4.4 for the full bucket layout.

S
Description
InboxOS — self-hosted personal ERP/CRM pipeline. Prompts-as-code, Gitea Actions, NocoDB, Ollama, SeaweedFS, Papra.
Readme 1.8 MiB
Languages
Python 90.3%
Shell 9.7%