M16: isolate acceptance and harden readiness

This commit is contained in:
NuklearRabbit
2026-08-10 12:08:42 +02:00
parent 2ee8b2d82b
commit 686795a452
13 changed files with 200 additions and 41 deletions
+10 -14
View File
@@ -50,8 +50,9 @@ The PoC implements:
- role-aware global search across vehicles, bookings and (Operations Manager) issues;
- safe, confirmed demo reset;
- RAGcore-backed knowledge assistant with citations;
- two n8n workflows: return processing, and a scheduled data-quality scan with
crash-recoverable outbox delivery leases;
- four canonical n8n workflows: return processing, scheduled data-quality scanning,
RAGcore procedure sync and centralized workflow-error handling, with explicit
heartbeat evidence and crash-recoverable outbox delivery leases;
- four read-only MCP tools through ITWorx MCP Hub;
- deterministic demo reset and five-minute showcase.
@@ -66,16 +67,11 @@ It is not an ERP, CRM, accounting package, public booking site, payment system o
quality-scan) workflow live-verified end to end against a real n8n instance.
`GET /api/v1/integrations/status` reports a truthful aggregate state from outbox
delivery counts, not just the most recent event.
- **RAGcore**: the demo `KnowledgeProvider` (deterministic TF-IDF extractive retrieval
over the local procedure documents) is what satisfies the knowledge-assistant
acceptance criteria and is what's active in production (`KNOWLEDGE_PROVIDER=demo`). A
`RAGcoreKnowledgeProvider` HTTP adapter is implemented, unit-tested, and has been
exercised live against the deployed RAGcore instance: a real filesystem-permission bug
that caused every live retrieval to return zero candidates was found and fixed
(`docs/final-integrations/current-state-audit.md`), but a second, deeper gap — RAGcore's
reranker adapter calls an Ollama HTTP route (`/api/rerank`) that does not exist on the
deployed Ollama version — still blocks real grounded answers. `KNOWLEDGE_PROVIDER` stays
`demo` until that is resolved on the RAGcore side.
- **RAGcore**: the live deployment uses `KNOWLEDGE_PROVIDER=ragcore`. Readiness and real
grounded retrieval are verified end to end; when RAGcore's generated-answer endpoint
is unavailable, Fleet Ops falls back only to cited extractive search results and never
invents an answer. The deterministic demo provider remains available for clean-checkout
acceptance and local development.
- **ITWorx MCP Hub**: the four read-only provider endpoints are implemented, tested, and
directly `curl`-verified with correct auth enforcement and audit logging.
`MCP_HUB_REGISTRATION_ENABLED` is actually wired into `Settings` and reported honestly
@@ -130,9 +126,9 @@ All defaults are configurable via `.env` (see `.env.example`).
## Quality gates
```bash
make test # backend: pytest (151 tests)
make test # backend: isolated PostgreSQL Compose project; never the live database
make lint # backend: ruff + mypy (strict, zero errors)
make e2e # frontend: Playwright end-to-end (138 tests, live stack required)
make e2e # frontend: complete Playwright acceptance (live stack required)
```
Frontend build/typecheck: `cd frontend && npm run build` (`tsc -b && vite build`).