Frozen Encoder DistilBERT Medical Triage Classifier
Model Description
This repository contains a frozen-encoder DistilBERT sequence classification model. The pretrained encoder is kept frozen and only the classification head is trained.
The model receives a short English symptom description and predicts one of the following triage-oriented labels:
self_monitor
consult_gp
urgent
This model was developed as part of the SortMed academic project, a medical pre-triage assistant prototype built for a bachelor's thesis by Cristian Untaru at the West University of Timișoara, Faculty of Informatics.
The model is intended for research and educational use. It is not a diagnostic system and is not a certified medical device.
Intended Use
This model is intended to be used in an academic medical pre-triage prototype for:
classifying English symptom descriptions into broad urgency categories;
comparing transformer-based models for medical text classification;
evaluating full fine-tuning against parameter-efficient fine-tuning methods;
supporting experimental NLP research in symptom-based medical pre-triage.
Example input:
I have chest pain, shortness of breath, and I feel dizzy.
Example output:
urgent
Out-of-Scope Use
This model must not be used as:
a replacement for professional medical advice;
a diagnostic system;
an emergency decision-making tool;
a certified clinical triage system;
a standalone healthcare product;
a tool for non-English medical text without additional validation.
For severe, worsening, or emergency symptoms, users should contact emergency services or a qualified healthcare professional.
Labels
The model predicts one of three labels:
Label
Meaning
self_monitor
Symptoms appear mild and may be monitored, assuming no worsening or additional warning signs.
consult_gp
A general practitioner or non-emergency medical professional should be consulted.
urgent
Symptoms may require urgent medical attention or emergency evaluation.
The label mapping is included in label_map.json and in the model configuration.
The dataset contains English symptom-based text examples labeled into three triage classes:
self_monitor
consult_gp
urgent
Dataset split used for training:
Split
Examples
Train
490
Validation
105
Test
106
Total
701
The dataset labels were produced using rule-based triage logic for academic experimentation. They are not clinically validated annotations from medical professionals.
MedQuAD was not used to train this classifier. In the broader SortMed system, MedQuAD is used separately for retrieval of related medical information through the cristian-untaru/medquad-retrieval-pretriage dataset.
The model was evaluated on the held-out test split.
Metric
Test Score
Accuracy
0.6321
Macro Precision
0.6766
Macro Recall / Sensitivity
0.6202
Macro Specificity
0.8088
Macro F1
0.6282
Macro AUC OvR
0.7975
Macro IoU / Jaccard
0.4592
Test Loss
0.9203
Per-Class Results
Per-class metrics are not currently published as a separate artifact in this repository. The aggregate test metrics above are the available published evaluation results.
These results should be interpreted in the context of the small dataset size and the academic nature of the experiment.
This model loads with the standard Transformers API and does not require trust_remote_code=True.
To verify the label mapping:
print(model.config.id2label)
Expected output:
{0: "self_monitor", 1: "consult_gp", 2: "urgent"}
Repository Files
File
Description
config.json
Model architecture, label mapping, and classification configuration.
model.safetensors
Model weights in SafeTensors format.
tokenizer.json
Tokenizer vocabulary and processing pipeline.
tokenizer_config.json
Tokenizer configuration.
training_config.json
Human-readable training configuration.
label_map.json
Mapping between numeric class IDs and triage labels.
README.md
Model card documentation.
.gitattributes
Git LFS configuration for large model files.
Limitations
This model has several important limitations:
It was trained on a small academic dataset.
The labels are rule-based and not clinically validated by medical experts.
It does not perform medical diagnosis.
It does not consider patient age, sex, medical history, medication history, vital signs, comorbidities, pregnancy status, allergies, or physical examination findings.
It may produce incorrect predictions for rare, ambiguous, incomplete, severe, or contradictory symptom descriptions.
It was trained for English text only.
It should not be used for emergency triage without medical supervision.
Its predictions depend on the quality and completeness of the user-provided text.
Ethical and Safety Considerations
Medical pre-triage systems can influence user decisions in sensitive healthcare situations. This model should therefore be used only with clear disclaimers and with safeguards that encourage users to seek professional medical care when appropriate.
Any real-world deployment would require:
clinical expert review;
validation on larger and more representative medical datasets;
safety testing;
bias and fairness evaluation;
monitoring for incorrect or unsafe predictions;
clear user-facing warnings;
escalation rules for emergency symptoms.
Medical Disclaimer
This model is intended only for academic, research, and prototype development purposes. It is not a substitute for professional medical advice, diagnosis, treatment, or emergency care.
If symptoms are severe, sudden, worsening, or potentially life-threatening, users should contact emergency services or a qualified healthcare professional immediately.