Case file
Post-market complaint triage for a fictional medical device manufacturer under the EU MDR. A complaint comes in, a language model suggests whether it is a possible serious incident and which reporting limit applies, and a quality engineer confirms or corrects it, with a reason for every correction. The deadline follows MDR Article 87 to the day, with weekends and Austrian public holidays, and every step goes into a hash-linked audit trail. Synthetic data; not a validated quality management system. 29 unit, 39 API and 28 browser tests.
Problem
When a complaint about a medical device comes in, the manufacturer has to decide quickly whether it is a possible serious incident. If it is, MDR Article 87 sets the latest day the report may reach the competent authority: 2 days for a serious public health threat, 10 for a death or an unanticipated serious deterioration of health, 15 for any other serious incident. The clock starts on the day anyone at the manufacturer first hears of it, not when the complaint reaches the quality team.
The judgement is hard and the arithmetic is easy to get wrong. A nurse writes that a pump kept running after stop and a child needed cardiac monitoring overnight: is that a near miss with 15 days, or harm that already happened with 10? And when does day 10 end if day 6 is Austria's National Day?
Playnt lets a language model draft that first judgement and keeps the decision with a person. A quality engineer confirms or corrects every suggestion, a correction needs a reason, and the deadline is computed from rules with sources, not from the model.

The tour shows a real model miss: a nuisance occlusion alarm flagged as "might have led to a serious outcome, 15 days", corrected by the quality engineer. Synthetic data throughout. The manufacturer, Orrowell Medical GmbH, its five devices and every complaint are invented. Not a validated quality management system.
How it works
browser (React) ---> API (Node, Express) ---------------> MongoDB
Zod at the boundary, complaints, devices,
deadline rules, audit chain append-only auditEvents
|
+---> Gemini (gemini-3.8-flash), or recorded responses in demo mode
A complaint is logged with its device and awareness date. The API sends only the complaint text and the fictional device's risk file to the model, never the reporter's details, and asks for a structured suggestion: is it a complaint, is it a possible serious incident, which serious outcome, and the exact passage that supports it. Anything that does not parse, or quotes text that is not in the complaint, is stored raw and goes to manual triage. It is never repaired.
The queue opens on what needs action, nearest deadline first: complaints waiting
for a decision, and possible serious incidents whose report has not been
recorded. J and K move through it, C confirms, R corrects.

The hosted demo runs the same Express API as one Vercel Function in Frankfurt against MongoDB Atlas, with recorded model responses and the clock fixed at 25 October 2026. A nightly GitHub Action resets the data.
Design decisions
Each complaint embeds its triage history: every model suggestion and every human decision belongs to one complaint, is never shared, and is always read with it, so one document read serves the whole complaint screen. The current triage and the deadline sit next to the history, so the queue sorts and filters without unwinding arrays. Devices are referenced, because a risk file is shared by many complaints and changes on its own schedule.
The audit trail is its own collection. Every intake, suggestion, rejected output, decision and report is one event, carrying a per-complaint sequence number and the SHA-256 hash of the event before it, so editing or deleting an event breaks the chain and the audit page names where. The API has no route to change an event, and that is not the only guard: the application connects as a database user whose role may only find and insert on that collection. MongoDB Atlas supports custom roles on its free tier, so the hosted demo keeps the same guarantee, with a separate user for the nightly reset. JSON Schema validators on every collection back up Zod at the API, and the indexes follow the screens: status and due date for the queue, device and awareness date for trends.
The deadline is computed in one shared module used by the API and the browser. Calendar days, with day 0 the awareness date (MDCG 2023-3 Rev.2 Q14). A last day on a weekend or public holiday moves to the next working day, and a period of two days or more keeps at least two working days, both from Regulation 1182/71, which sets how EU time limits are counted. Deadlines end at 23:59 Vienna time, with the Austrian public holidays of 2026 and 2027; outside those years Playnt refuses to compute a deadline rather than guess.
The model never sets the limit. It suggests a serious outcome, the server derives 2, 10 or 15 days from it, and a suggestion whose limit does not match is stored as needing manual triage. The rule lives in one place.

The model suggests and a quality engineer decides. Confirming is one key. Correcting opens a form that will not save without a reason of at least ten characters, and the reason is shown next to the decision and kept in the audit trail. The model's evidence is highlighted in the complaint as received, so the engineer checks the suggestion against the words it rests on. Status is always text with an icon, never colour alone, and each regulatory term opens its definition and source in place.
The seeded story shows the miss that matters most. On PLT-2026-0034 the model called a potassium overdose a near miss with 15 days; the engineer corrects it to an unanticipated serious deterioration with 10 days, citing MDCG 2023-3 and the device's risk file.
Tests and evaluation
29 unit tests, 39 API tests and 28 browser tests, run in CI on every push.
The unit tests cover the deadline rules at their edges: a period ending on a weekend, a weekend followed by a public holiday, the two-working-day rule, the MDCG 2023-3 worked example, 23:59 Vienna in winter and summer, and one second either side of the deadline. They also check Easter and the holidays derived from it against a fixed table. The API tests run on an in-memory MongoDB: every validation error at intake, model output that must be refused, confirming and correcting, an audit event edited or deleted directly in the database and caught by the chain check, and the least-privilege user that can append to the audit trail but not change it. The browser tests run 14 scenarios in light and dark mode, with axe accessibility checks and the keyboard flow, and one fails if any request leaves localhost in demo mode.
The model was run once over a frozen, labelled set of 40 synthetic complaints:
gemini-3.8-flash, temperature 0, on 25 October 2026. The prompt was not
changed after seeing the results.
| All 40 | 28 clear | 12 ambiguous | |
|---|---|---|---|
| Serious incident flag, precision | 0.913 (21 of 23) | 0.933 (14 of 15) | 0.875 (7 of 8) |
| 95% Wilson interval | 0.732 to 0.976 | 0.702 to 0.988 | 0.529 to 0.978 |
| Serious incident flag, recall | 1.000 (21 of 21) | 1.000 (14 of 14) | 1.000 (7 of 7) |
| 95% Wilson interval | 0.845 to 1.000 | 0.785 to 1.000 | 0.646 to 1.000 |
| Time limit agreement, where both flagged | 21 of 21 | 14 of 14 | 7 of 7 |
It missed no labelled serious incident and gave the labelled limit each time it flagged one. Both errors over-flag a non-serious fault as "might have led". Forty items is small: one more false positive moves precision by about four points, and on this set recall is only shown to be above 0.85. The labels are one reviewer's reading, by someone with QA/RA training, not a vigilance specialist; they are not ground truth. The 38 demo complaints are a separate set and do not count towards these numbers.

What is simplified
Sources
The repository has the full research notes under docs, the frozen evaluation set with its checksums, and the per-item results.
Live demo and code
Try it at playnt.vercel.app: demo mode, recorded model responses, reset every night. The code is MIT-licensed at github.com/Henrycarto/playnt.