Local by design
Runs entirely on local hardware via llama.cpp — no cloud APIs. Patient data never leaves the deployment.
Open-source research project · DIGI at the University of Washington
An open framework for orchestrating and evaluating open-weight language models against clinical, administrative, and surveillance workflows — proven through ChartSearchAI and Catalyst, its example implementations in OpenMRS and OpenELIS.
Experimental software. Outputs require clinical review. Not a medical device.
Project overview
Open Clinical AI is an open framework for orchestrating small, open-weight language models against clinical, administrative, and surveillance workflows, and for evaluating whether the result is dependable enough to trust. The thesis: small models become dependable not through scale, but through staged orchestration — deterministic checks, citation grounding, and read-only execution policy — with every validation run published. ChartSearchAI and Catalyst are its example implementations, in OpenMRS and OpenELIS.
Because the models run locally via llama.cpp — no cloud APIs — the same framework fits health systems where connectivity, compute, cost, or data-privacy rules make cloud AI unavailable, without changing the architecture.
Runs entirely on local hardware via llama.cpp — no cloud APIs. Patient data never leaves the deployment.
Small models are made dependable by orchestration: staged pipelines, deterministic temporal and structure rules, citation resolution, and read-only SQL policy.
Comparison runs retain individual answers, source traces, judge results, and aggregate scores. A published pre-refactor Catalyst run passed 12 of 12 live scenario repetitions and 384 assertions on real models and PostgreSQL; the current architecture is undergoing a clean-pin rerun.
Example implementation 1 of 2 · OpenMRS integration
ChartSearchAI is the framework's example implementation for point-of-care chart search. Fresh installations retain the bundled provider; deployments may configure the same lifecycle through Med Agent Hub. The recording uses that configured Hub provider and stores each stage in one chat message. The initial Answer is displayed before validation and In-Depth finish.
Displayed when the answer stage finishes.
The same message records checked, edited, needs review, or unavailable.
References show the chart entries used by the final answer.
More recorded examples
These recordings use the local OpenMRS stack with the configured Med Agent Hub provider. Captions identify the stage shown; the bundled provider remains a supported separate path.
Shows the Answer, validation update, evidence, In-Depth, and a new question that interrupts unfinished In-Depth.
Each tile shows the record type, date, value used, source identifier, and grounding result.
Med Agent Hub
ChartSearchAI owns the OpenMRS workflow and can execute it through either its bundled provider or a configured Med Agent Hub provider. The recording uses Hub; the five stages below are the shared lifecycle shown in the demo above.
Load patient records and source provenance.
Generate the initial answer with the selected profile.
Apply deterministic temporal and output rules.
Resolve citations and record grounding results.
Generate additional detail from the checked answer.
Example implementation 2 of 2 · Catalyst
Catalyst is the framework's example implementation for program-monitoring and reporting questions — viral load coverage, CD4 counts, specimen turnaround — directly from laboratory (OpenELIS) and HIV program (OpenMRS) databases. It turns a question into SQL against a catalog generated from the database itself. A writer model drafts the query, a selected profile may add a reviewer, and a deterministic policy allows only read-only execution. Results are typed tables, and a follow-up instruction refines the exact current query.
A viral load question generates and runs, then a follow-up adds the result unit and specimen receipt-to-release time to the same query.
The same workbench targets a separate HIV program database: a CD4 count question, then a follow-up adding gender and birth date.
OpenELIS laboratory and OpenMRS HIV/ART program data, each with its own database and generated catalog.
Generated SQL is validated, executed read-only, and compared against independently authored gold queries.
12 of 12 live scenario repetitions passed, 384 assertions, on real models and PostgreSQL; current-pin acceptance remains open.
Catalyst pipeline
Catalyst Gateway owns the query profiles, prompts, lint, review composition, SQL policy, and evidence. It calls Med Agent Hub only as a generic single-role model executor. The four stages below are the lifecycle shown in the demos above.
A writer model drafts SQL against the generated catalog.
A reviewer model checks the draft query against the catalog and the question.
The query is checked for read-only policy compliance before it can run.
The validated query runs read-only against the analytics database.
Evaluation
The harness records configuration, per-cell answers, source traces, deterministic checks, and judge outputs. Reports show both aggregate scores and individual answers. They are research results, not product certifications.
Evaluation reports
Where to go next
The stack runs on a single workstation-class machine — CPU inference or one consumer GPU — against your own OpenMRS/OpenELIS databases.
Project documentationEvery comparison run is published: configuration, per-answer traces, deterministic checks, and judge outputs.
Evaluation reportsCatalyst, the validation harness, and Med Agent Hub are open source, with the run manifest needed to reproduce a published result.
Validation harness (GitHub)