Architecture overview
Clinical Corvus uses its own control plane to keep clinical and product rules separate from AI runtimes. This division allows models, providers, or adapters to change without altering the beta boundary, CaseState, or the contract delivered to the interface.
Components
| Component | Role |
|---|---|
| Clinical workspace | Displays context, deltas, plans, actions, and review states. |
| FastAPI | Provides patient, group, agent, document, state, feedback, and usage APIs. |
| Corvus control plane | Classifies the question, selects the sequence, applies budgets, and builds AgentResponse. |
| BAML | Defines prompts and structured outputs for bounded functions. |
| Langroid | Acts as a selective runtime for agents, tools, lineage, and tasks when Corvus contracts are preserved. |
| Retrieval | Combines local corpus, bibliographic sources, and permitted external providers. |
| CaseState and PCM | Separate episode state from longitudinal context. |
| Rails | Record evidence, used context, and execution path when the route produces them. |
Important boundaries
Third-party PHI sharing is disabled by default. Explicitly public queries without PHI indicators may use approved providers. Canonical clinical research builds redacted queries for external sources.
Not every AI action passes through the canonical pipeline. That distinction must remain visible in documentation and the interface.
The Patient Context Manager aggregates known history. CaseState represents the active problem and its changes. Conversation memory and learned preferences have their own retention cycles and scopes.
Services apply tenant_id, and covered PostgreSQL tables receive RLS policies. Deployment review must confirm included tables and administrative paths.
What the architecture lets reviewers inspect
Reviewers can examine which context entered a response, which path and tools participated, which evidence was admitted or rejected, where blocking or insufficiency occurred, and which contracts a product surface can display.
These mechanisms improve inspectability. They do not demonstrate clinical safety or effectiveness on their own.