Summary
Update the Workbench IA so / becomes a global overview dashboard outside the Process Sentinel workflow, while Process Sentinel gets its own workflow entry route.
The overview dashboard must include a full-width question field directly under the title. Users can ask about the current factory context, and v1 should return deterministic answers from existing FIP API data. Do not add an LLM, AI SDK, model gateway, RAG index, or external provider in this issue.
Related: #206, #232, #240
Public API / Interfaces
Add a read-only deterministic context question endpoint:
Request:
{
"question": "What is the most important finding right now?"
}
Response:
{
"question": "What is the most important finding right now?",
"answer": "The current highest-priority finding is ...",
"confidence": "supported",
"sources": [
{
"type": "detection",
"id": "det_fill_weight_gradual_drift",
"label": "Fill weight gradual drift",
"href": "/detections/det_fill_weight_gradual_drift"
}
]
}
confidence values: supported, partial, unsupported.
Supported v1 question intents:
- current site, area, line, asset, batch, work order, and product context
- active detection count and highest-priority detection
- why the primary detection was flagged, using evidence summaries
- pending recommendation count and current recommendation status
- API/source health summary from browser-safe data
Unsupported questions must return confidence: "unsupported" with a short answer and suggested example questions. Do not guess, call an LLM, query arbitrary data, expose secrets, or imply production readiness.
Implementation Changes
- Keep
/ as the overview dashboard and move Process Sentinel workflow navigation under a new /process-sentinel entry point.
- Update navigation so Overview is outside the
Sentinel workflows group; workflow pages remain detection list, detection detail/evidence, recommendation review, and RCA/CAPA draft.
- On
/, place the full-width context question form directly below the dashboard title and above overview metrics.
- Implement the question UI as a client component with accessible label text, submit/loading/error states, and an answer panel with cited links back into Workbench routes.
- Add typed API client support for
POST /context/questions.
- Add backend deterministic intent matching in the API layer, using existing domain, Sentinel, event, recommendation, and connection/profile stores.
- Update
apps/web/README.md, docs/demo/OPERATIONS_WORKBENCH_INFORMATION_ARCHITECTURE.md, and docs/LEARNING_LOG.md.
Acceptance Criteria
/ clearly reads as an overview dashboard, not a workflow step.
- The context question field spans the dashboard content width and appears directly under the title.
- Asking a supported question returns a deterministic answer with source references.
- Unsupported questions fail safely with no hallucinated answer.
- Overview remains read-only: no approve/reject/defer controls appear there.
- Workflow pages still support the Process Sentinel path: detect, explain with evidence, review recommendation, draft RCA/CAPA.
- Copy aligns with the Docker/external-source direction and avoids simulator-first wording where this issue touches UI text.
Test Plan
- Backend tests for
POST /context/questions: supported question, partial question, unsupported question, empty/invalid question, and source references.
- Frontend unit/static tests for route presence, navigation grouping, API client type coverage, and overview Q&A UI strings.
- Playwright smoke coverage for entering a question on
/, receiving an answer, and following a cited detection/recommendation link.
- Run:
make test
make lint
make typecheck
cd apps/web && npm test
cd apps/web && npm run lint
cd apps/web && npm run typecheck
make test-e2e
Assumptions
- The selected scope is deterministic v1, not AI-backed natural language answers.
- The endpoint answers only from current platform context and runtime state already exposed through browser-safe APIs.
- AI-backed context Q&A should be planned later around the documented Local Model Gateway and Factory Memory direction.
Summary
Update the Workbench IA so
/becomes a global overview dashboard outside the Process Sentinel workflow, while Process Sentinel gets its own workflow entry route.The overview dashboard must include a full-width question field directly under the title. Users can ask about the current factory context, and v1 should return deterministic answers from existing FIP API data. Do not add an LLM, AI SDK, model gateway, RAG index, or external provider in this issue.
Related: #206, #232, #240
Public API / Interfaces
Add a read-only deterministic context question endpoint:
Request:
{ "question": "What is the most important finding right now?" }Response:
{ "question": "What is the most important finding right now?", "answer": "The current highest-priority finding is ...", "confidence": "supported", "sources": [ { "type": "detection", "id": "det_fill_weight_gradual_drift", "label": "Fill weight gradual drift", "href": "/detections/det_fill_weight_gradual_drift" } ] }confidencevalues:supported,partial,unsupported.Supported v1 question intents:
Unsupported questions must return
confidence: "unsupported"with a short answer and suggested example questions. Do not guess, call an LLM, query arbitrary data, expose secrets, or imply production readiness.Implementation Changes
/as the overview dashboard and move Process Sentinel workflow navigation under a new/process-sentinelentry point.Sentinel workflowsgroup; workflow pages remain detection list, detection detail/evidence, recommendation review, and RCA/CAPA draft./, place the full-width context question form directly below the dashboard title and above overview metrics.POST /context/questions.apps/web/README.md,docs/demo/OPERATIONS_WORKBENCH_INFORMATION_ARCHITECTURE.md, anddocs/LEARNING_LOG.md.Acceptance Criteria
/clearly reads as an overview dashboard, not a workflow step.Test Plan
POST /context/questions: supported question, partial question, unsupported question, empty/invalid question, and source references./, receiving an answer, and following a cited detection/recommendation link.make testmake lintmake typecheckcd apps/web && npm testcd apps/web && npm run lintcd apps/web && npm run typecheckmake test-e2eAssumptions