Few documents in a hospital are as personal as a psychiatric note. A clinician writes down what someone said on a bad day, in words close to their own, along with details about family, work, and relationships. Now health systems are being asked to use that text to train language models, mostly to take some of the documentation burden off clinicians.
The promise is real. But one question keeps nagging at me. After a model has learned from those notes, what does it still know about the people in them?
Removing the Name Is Not Removing the Person
The standard answer to privacy in health data is de-identification. Strip the names, dates, phone numbers, and record numbers, and the data is considered safe to use.
That works reasonably well for tables. It works much less well for free text, and psychiatric notes are almost all free text. A note can be full of details that appear on no identifier list but still point to one person: a rare occupation, a small town, a specific event at a specific workplace. In psychiatric care those details are often the clinical content itself, so you cannot delete them without deleting the meaning.
The history here is worth remembering. In the 1990s, Latanya Sweeney matched an “anonymized” hospital dataset against public voter records and picked out the medical records of the Massachusetts governor. Those were tables with a handful of columns. A clinical note holds far more.
Automated scrubbing also misses things. In my research (https://ieeexplore.ieee.org/document/11325541/), we ran psychiatric notes through both pattern-matching rules and a neural tagger, and a small share of identifiers, around 0.7 percent, still got through. That sounds tiny until you remember that a corpus of this kind runs to well over a hundred thousand notes.
Models Remember More Than We Would Like
A trained language model is not just a bundle of general patterns. It can retain pieces of its training data, and researchers have shown that carefully written prompts can pull rare passages back out. Small, sensitive datasets make this worse, because unusual passages get seen again and again during training, and unusual passages are exactly what identifies people.
We saw this directly. Even after masking, a model fine-tuned in the ordinary way gave an attacker a real edge. Attack success is usually scored on a scale where 0.5 is a coin flip, and ours came in at 0.86. In plain terms, someone with query access to the model could tell, far better than chance, whether a particular note had been used to train it. It also reproduced identifier-like strings at roughly 27 per 10,000 tokens.
So the model becomes a new place where the data lives. It may sit outside the systems that were locked down for the original records, and it may get shared, moved, or exposed through an API. Nobody set up access controls for it the way they did for the EHR.
“Once you train on patient notes, the model is part of your data store, whether or not anyone has written that down.”
The Trade-Off Everyone Assumes
The usual objection is that stronger privacy protection costs accuracy, and clinicians will not use a model that gets worse.
That assumption deserves to be tested, not just repeated. When we trained the same kind of model with differential privacy, which adds carefully calibrated noise so that no single patient’s records can shift the result much, the attack dropped to 0.52, close to a coin flip. The model still predicted the next word correctly about 85 percent of the time, within a few percentage points of the non-private version. The extra cost was compute, about 13 more hours on a four-GPU server.
One design choice mattered more than I expected. Psychiatric notes run long, and a single fixed noise setting punishes long notes the most. Adjusting the setting to note length recovered accuracy without weakening the protection.
I would not read this as “privacy is free.” Privacy versus usefulness is a curve, not a cliff, and where you land depends on the task and how much protection you need. The useful habit is to report both together so people can see what a given level of protection actually costs.
Where This Stops
This was one hospital’s data, from a public research database. The risks that remain are the kind I would want any team to plan for: misspelled names and nicknames that slip past scrubbing, notes that are unusually short or long, models that behave differently at a different hospital, and prompts clever enough to coax out memorized text. And formal privacy guarantees are not a legal stamp. They do not replace ethics review or careful control over who gets the model.
Key Takeaways
- De-identifying inputs is not the same as securing outputs. Even after masking, a standard fine-tuned model let an attacker guess training membership with 0.86 accuracy, far above the 0.5 coin-flip baseline.
- Automated scrubbing misses real identifiers. Around 0.7% of identifiers survived pattern-matching and neural tagging, a small share that still adds up across a corpus of over 100,000 notes.
- Differential privacy worked, at a modest cost. It cut attack success to 0.52 (near chance) while keeping next-word accuracy around 85%, for about 13 extra hours of compute on a four-GPU server.
- Layered protection matters. Removing the masking step increased leakage even with private training still in place; no single safeguard was sufficient alone.
- A trained model should be governed like the records it learned from — with the same access controls, logging and retention rules as the source EHR data.
- Privacy and performance should be reported together. A model card listing accuracy alone tells only half the story.
What Teams Can Do With This
Measure privacy directly. “We de-identified the data” describes the inputs. It says nothing about what the trained model will output. Test the model itself with extraction and membership inference attempts.
Do not rely on one layer. In our tests, removing the masking step made leakage climb noticeably even with private training in place. Each layer covered gaps the other left.
Treat the model as a data store. Give it the same access controls, logging, and retention rules as the source records.
Report privacy and performance together. A model card that lists accuracy and says nothing about privacy tells you half the story.
Bring in clinicians and privacy officers early. They know which details in a note are most revealing, and they will spot risks an engineering team would not.
Closing Thought
Health systems will train models on clinical text. The incentives are too strong for that to stop. What we can still shape is how it is done and what evidence comes with it.
The question worth asking is not only whether the model is accurate. It is whether the people who trusted a clinician with their story can be shown, with evidence and not just assurances, that the model did not keep what it should not.
WHY THIS MATTERS: THE BIZTECH BYTES TAKEAWAY
For health systems, AI leaders and compliance teams, this piece raises four practical points:
- De-identifying inputs is not the same as securing outputs. A model trained on “anonymized” notes can still leak identifying information unless it is tested directly.
- A trained model should be governed like the records it learned from. Access controls, logging and retention policies need to extend to the model itself, not stop at the source data.
- Privacy-preserving training is not free, but it is affordable. The research cited here found a large drop in attack success for roughly 13 extra hours of compute, with accuracy within a few percentage points of the non-private version.
- Privacy and performance should be reported together. A model card showing only accuracy leaves out half the risk picture.











