Kernwerk

Scan in, report out: two medical AI models on one $249 box, fully offline

The scan never leaves the room. A chest X-ray goes into a $249 box, a written report comes out, and nothing touches the cloud. Two models do the work, one that sees and one that writes.

The usual way to get this is a cloud API, which brings a PACS integration, a data-processing agreement, and a per-scan fee for every image that leaves the building. This box needs none of that, and it runs anywhere an X-ray is taken, online or not.

From image to report

A chest X-ray goes in. A short written report comes out. Two models do the work, with a fixed rule between them:

  • SEE: a chest X-ray classifier reads the image into 14 pathology probabilities (about 5 ms)
  • WRITE: a medical LLM, MedGemma, adds a recommended next step and a clinical consideration (about 2 s)

The findings between them are written by neither model but by a fixed rule, so they always match the numbers.

Pipeline diagram: a chest X-ray enters a vision model that outputs 14 probabilities, which enter a language model that outputs a written report. A crossed-out square dashed path shows the language model never receives the image, only the numbers.
The image stops at the vision model. The writer only ever sees the numbers.

Here are two real reads from the board.

Reading station with three report boxes: current findings (from the vision model), next steps to confirm and clinical considerations (both from MedGemma). Effusion scores 0.95, the findings read 'likely effusion' and the next step is a lateral decubitus view.
Effusion at 0.95: the findings read "likely effusion", then MedGemma adds a next step (a lateral decubitus view) and a consideration. Each box is labelled with its source.
The reading station on a cardiomegaly case: cardiomegaly scores 0.88 (likely). The findings read 'likely cardiomegaly', the next step is an echocardiogram, and the clinical consideration is to assess for pulmonary edema if the patient is symptomatic.
A different finding: likely cardiomegaly, then MedGemma's next step (an echocardiogram, not a CT) and a consideration. A systems demonstration, not a clinical tool.

A rule for the findings, MedGemma for the advice

The findings are not written by MedGemma. A fixed rule turns each probability into a word (above 0.6 “likely”, 0.4 to 0.6 “possible”, below “unlikely”), so the findings always match the numbers, nothing invented.

MedGemma does the part that needs judgment. It reads the findings and adds:

  • a next step to confirm each finding (a lateral view for an effusion, an echocardiogram for cardiomegaly)
  • a clinical consideration (what to watch for, or what could change management)

Both models fit in 8 GB

Both models share the box’s 8 GB and its GPU:

  • vision engine: about 15 MB
  • MedGemma 4B at 4-bit (the quantization trick from post 002): about 2.5 GB
  • speed: about 15 tokens a second, so a report in about two seconds

That is under a third of the memory. There is room for a larger vision model, a bigger medical LLM, or a shelf of specialist models kept on disk and loaded on demand.

The boundary

This is a systems demonstration, not a clinical tool:

  • the findings come from a pretrained classifier, the wording from a small general model
  • no claim of clinical validity, the point is the capability, not the diagnosis
  • swap the classifier for any detector and the pattern holds

One box, a shelf of specialists

This is where it stops being a demo and starts being a platform. Nothing here is tied to chests. Each model is small and only one runs at a time, so the box can hold a whole shelf of specialist models on disk and load only the one it needs: a router reads the image, picks the body part, and pulls the matching model. The rest of the pipeline runs unchanged.

Diagram: an X-ray goes to a router that identifies the body part, loads the matching specialist model from a shelf on disk (chest, abdomen, leg, arm), which runs the prediction, then the rule and MedGemma write the report.
A router picks the body part and loads the matching model. Only the chosen one runs. The rest wait on disk.

One cheap box carrying a library of specialists, loading the right one on demand. That is probably what the future of edge medical AI looks like: not one model in the cloud that every scan has to reach, but a shelf of them sitting where the scan is taken.

This is what we build at Kernwerk: AI that runs where your data is, not where a vendor’s servers are. If you are building something that needs to run where the data lives, we are looking for design partners. Talk to us.

See, then say.

Specs, for the curious. Vision: a DenseNet-121 from torchxrayvision, pretrained on public chest X-ray sets (NIH ChestX-ray14, CheXpert, MIMIC-CXR, PadChest), served with TensorRT FP16 at about 5 ms per image. Language: MedGemma 4B, 4-bit, on the GPU via llama.cpp at about 15 tokens a second. Latencies are measured on the board and averaged over repeated runs, with under 1 percent variance. A 10-minute endurance run held full throughput at 69 °C, no thermal throttling. Hardware: Jetson Orin Nano Super, 8 GB, 25 W.