docs(prd): AI back-office — agent fleet for daily admin & accounting

New PRD tree vibe/PRD/ai-back-office/ (hub + 6 leaves + STATUS): task
inventory T01-T16 with mode operatoire, atom/contract architecture on
the ADR-0003 write gate, four-tier model fleet (Claude/Mistral/M4/Pi),
12 challenges with mitigations, POC plan with exit criteria, QA
strategy with autonomy promotion gates. Index row + bidirectional
backlinks (erp guidebook, safe-prod PRD).

Co-Authored-By: Claude Fable 5 <[email protected]>
This commit is contained in:
2026-07-11 14:25:04 +02:00
co-authored by Claude Fable 5
parent 5a80ec32ae
commit 169c8debb4
11 changed files with 867 additions and 3 deletions
+77
View File
@@ -0,0 +1,77 @@
[vibe](../../README.md) > [PRD](../README.md) > [AI back-office](README.md) > **POC plan**
# POC plan — feasibility proven by real implementations
> **Status:** In design
> **Last Updated:** 2026-07-11
> **Up:** [AI back-office hub](README.md)
> **Related:** [Task inventory](task-inventory.md) · [Challenges](challenges.md) · [QA strategy](qa-strategy.md) · [STATUS](STATUS.md)
POCs are **real implementations against real data** (the live mailbox, the live bank feeds, the iso-prod sandbox) — not demos. Each has a hard exit criterion; a POC that can't meet it produces a documented "no" and a fallback decision, which is also a success. Order follows the [roadmap](README.md#phased-roadmap); effort is S/M/L (rough: S ≈ a day, M ≈ a few days, L ≈ a week-plus of focused sessions).
## POC-1 — Supplier invoice end-to-end
*Flagship — phase 1 · effort L.*
**Proves:** the full A2 loop — the pipeline shape, dual extraction, validators, sandbox rehearsal, Telegram approval, gated promote, GED attach. Covers [T01](task-inventory.md#t01--mailbox-triage--routing)→[T04](task-inventory.md#t04--thirdparty-creation--completeness).
**Build:** mail → dual extraction (M4 + Mistral) → validators → manifest → sandbox → approval card → promote → attach + verify, journaled end-to-end. Triage may start as a cron script (Pi model comes in POC-2).
**Exit criteria:** 10 consecutive *real* supplier invoices recorded in prod with **zero human field-corrections** (approvals only); critical-field accuracy ≥ 98 % over the full golden set (overall field accuracy reported alongside); all injection fixtures quarantined; every run replayable from its journal.
**Fallback if failed:** stay at A1 (agent drafts, human enters in UI) and iterate extraction only.
## POC-2 — Pi sentinel
*Phase 3 · effort M.*
**Proves:** a quantized SLM on the cluster can hold the 24/7 watch ([T01](task-inventory.md#t01--mailbox-triage--routing), [T11](task-inventory.md#t11--compliance-calendar--reminders)); closes [D6](agent-architecture.md#open-decisions).
**Build:** llama.cpp/Ollama server as an ArgoCD app (arm64, GGUF Q4, 14B candidates, GBNF-constrained), resource-limited and node-pinned; triage atom pointed at it; reminder loop from the calendar file.
**Exit criteria:** ≥ 95 % accuracy on the three action classes (`supplier-invoice`, `bank-notice`, `government-admin`) over ≥ 200 historical mails labeled by Claude + human-corrected; p95 classification latency < 60 s; zero k8s evictions of business workloads attributable to inference over a 2-week soak; reminders fire on schedule for a synthetic calendar.
**Fallback if failed:** sentinel runs on M4-wake + Mistral (loses 24/7 — accepted degraded steady-state per [C5](challenges.md#c5--slm-capability-ceiling-on-pi-hardware)).
## POC-3 — Reconciliation + payment recording
*Phase 4 · effort M.*
**Proves:** the weekly money loop — reco findings become gated payment writes with deterministic tx-id linkage ([T07](task-inventory.md#t07--bank-reconciliation), [T08](task-inventory.md#t08--payment-recording)).
**Build:** scheduled reco → work items → payment manifests (with `transaction_id`) → rehearse/gate/promote → next reco matches by id (PASS 0).
**Exit criteria:** one calendar month with **zero unexplained deltas older than 7 days**; every recorded payment carries its `transaction_id` and is matched by id (not fuzzy) on the following run; digest reflects reality (spot-checked weekly).
**Fallback if failed:** reco stays A3-report-only; payments stay manual with the agent pre-filling.
## POC-4 — TVA dry-run
*Phase 5 · effort S.*
**Proves:** €-parity of fiscal preparation ([T10](task-inventory.md#t10--tva-preparation)) before the 2027 regime switch raises the stakes; de-risks [C6](challenges.md#c6--french-fiscal-correctness-over-time).
**Build:** prepare the **acompte de décembre 2026** and the **CA12 FY-2026** sheets from the ERP (skills exist); simulate 2027-Q1 as a CA3 quarterly sheet from the same data; archive evidence (snapshot hash + sheet) per run.
**Exit criteria:** prepared figures match the actually-filed values **to the euro** (acompte now, CA12 at filing ~May 2027); the CA3 simulation is validated by the expert-comptable checkpoint (or SIE guidance) before 2027-Q1 becomes real.
**Fallback if failed:** divergences are themselves findings (either a books error or an atom error — both valuable); T10 stays fully manual-verified until parity holds.
## POC-5 — Model routing bench
*Phase 1, alongside POC-1 · effort S.*
**Proves:** the [routing policy](model-fleet.md#routing-policy) with numbers instead of vibes; closes [D5](agent-architecture.md#open-decisions) (OCR) and seeds every atom's `model_policy`.
**Build:** run the *same* extraction atom across all four tiers on the golden set; score per-field accuracy, latency, cost/doc; include the OCR contenders on the scanned subset.
**Exit criteria:** a published table (accuracy × latency × cost per tier) + routing policy v1 committed to the registry; disagreement-rate baseline established for the dual-extraction design.
**Fallback:** none needed — whatever the numbers say *is* the deliverable.
## POC-6 — E-invoicing readiness spike
*Phase 2 — hard deadline 2026-09-01 · effort M.*
**Proves:** Arcodange can receive e-invoices on day one; closes [D4](agent-architecture.md#open-decisions) with an ADR ([C12](challenges.md#c12--e-invoicing-reform-unknowns)).
**Build:** shortlist of PDPs (*plateformes de dématérialisation partenaires* — cost, API quality, Dolibarr support); test Dolibarr 22 e-invoicing module(s) on the **sandbox**; parse a real Factur-X/UBL sample through T02's schema (structured lane).
**Exit criteria:** a chosen PDP with reception verified (a test e-invoice reaches Arcodange and lands in the pipeline) before 2026-09-01; ADR merged; 2027 emission/e-reporting requirements captured as backlog fiches with owners and dates.
**Fallback if failed:** minimum-compliance manual reception via the chosen PDP's web UI while the pipeline lane matures.
## Challenge coverage
| POC | De-risks |
| --- | --- |
| POC-1 | [C1](challenges.md#c1--extraction-reliability) extraction · [C2](challenges.md#c2--erp-write-integrity) write integrity · [C3](challenges.md#c3--prompt-injection-via-inbound-content) injection · [C8](challenges.md#c8--trust-calibration--autonomy-creep) trust gates |
| POC-2 | [C5](challenges.md#c5--slm-capability-ceiling-on-pi-hardware) SLM ceiling · [C7](challenges.md#c7--silent-failures-in-unattended-operation) silent failures (heartbeat pattern) |
| POC-3 | [C2](challenges.md#c2--erp-write-integrity) · [C7](challenges.md#c7--silent-failures-in-unattended-operation) — the standing money loop |
| POC-4 | [C6](challenges.md#c6--french-fiscal-correctness-over-time) fiscal correctness |
| POC-5 | [C1](challenges.md#c1--extraction-reliability) · [C4](challenges.md#c4--data-confidentiality--sovereignty) · [C9](challenges.md#c9--provider--api-dependency) — tier diversity with data |
| POC-6 | [C12](challenges.md#c12--e-invoicing-reform-unknowns) reform readiness |
Cross-cutting: [C10](challenges.md#c10--fleet-maintenance-burden--bus-factor) (maintenance) and [C11](challenges.md#c11--laptop-tier-availability) (M4 availability) are watched across all POCs via the weekly ops review rather than owned by one.