Instructions to use lethalantidote/phi-detector-model with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use lethalantidote/phi-detector-model with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("token-classification", model="lethalantidote/phi-detector-model")# Load model directly from transformers import AutoTokenizer, AutoModelForTokenClassification tokenizer = AutoTokenizer.from_pretrained("lethalantidote/phi-detector-model") model = AutoModelForTokenClassification.from_pretrained("lethalantidote/phi-detector-model", device_map="auto") - Notebooks
- Google Colab
- Kaggle
File size: 884 Bytes
8bdb0cf 99b85aa 8bdb0cf 99b85aa 8bdb0cf | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | ---
language: en
library_name: transformers
pipeline_tag: token-classification
base_model: StanfordAIMI/stanford-deidentifier-base
tags:
- clinical
- phi
- ner
---
# Synthetic PHI Detector
This token-classification model was fine-tuned from `StanfordAIMI/stanford-deidentifier-base` using
Synthetic Synthea-derived clinical templates. It recognizes three entity types
with the BIO labels stored in `config.json`.
Training examples: 5997
| Entity | Strict seqeval F1 |
|---|---:|
| MEDICAL_RECORD | 1.0000 |
| DIAGNOSIS | 1.0000 |
| MEDICATION | 1.0000 |
Overall strict seqeval F1: 1.0000
## Limitations
Synthetic templates do not represent every institution, document style, or
identifier format. False negatives and false positives are expected. This
model assists PHI detection and is not a compliance guarantee or substitute
for human review and layered detection controls.
|