/ Модель

Характеристики

Контекст
512 токенов
Параметры
137 млн
Лицензия
MIT
Архитектура
bert · dense
Библиотека
transformers
Опубликована
24 июн 2026

lora-biomedbert-medical-triage

Классификация текстаТекст → label3 профессии

Англоязычный классификатор описаний симптомов на базе BioMedBERT, распределяющий их по трём категориям медицинской срочности для академических экспериментов по предварительной сортировке.

153скачиваний за 30 дней0лайковвеса обновлены25 июн 2026

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

Модель cristian-untaru/lora-biomedbert-medical-triage — классификатор медицинских текстов для академического прототипа предварительной сортировки симптомов SortMed, разработанного Кристианом Унтару на факультете информатики Западного университета Тимишоары. Это дообученная BioMedBERT с архитектурой BERT для классификации последовательностей: по короткому описанию симптомов на английском языке она присваивает одну из трёх категорий срочности — self_monitor, consult_gp или urgent. Веса LoRA-адаптера и классификационная голова объединены в модель, доступную для загрузки через Transformers; число параметров — 136,7 млн, контекст — до 512 токенов.

Модель предназначена для экспериментальной классификации описаний симптомов, сравнения методов дообучения и исследований медицинского NLP. На тестовой выборке указаны accuracy 0,8208, macro precision 0,8385 и macro recall 0,8205. Обучение проводилось на небольшом наборе данных SymCAT с метками, созданными по правилам, а не подтверждёнными медицинскими специалистами. Модель не ставит диагноз, не учитывает клинический контекст и не предназначена для принятия экстренных решений; применима только к английскому тексту и требует клинической проверки перед любым использованием в реальных сценариях. Лицензия — MIT.

Сценарии применения

  • Отнесение описания симптомов к категории самонаблюдения
  • Выявление случаев, когда рекомендуется консультация врача общей практики
  • Выделение симптомов, требующих срочного медицинского внимания
  • Сравнение LoRA и полного дообучения для медицинской классификации текста
  • Эксперименты с предварительной сортировкой симптомов на английском языке

Ограничения

Модель обучена на небольшом наборе с правилосозданными, клинически не подтверждёнными метками и не учитывает медицинскую историю, жизненные показатели и другие важные сведения о пациенте. Она может ошибаться на редких, неоднозначных или неполных описаниях и не должна заменять врача или применяться для экстренной сортировки без медицинского надзора.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

LoRA BioMedBERT Medical Triage Classifier

Model Description

This repository contains a merged LoRA-adapted BioMedBERT sequence classification model. LoRA trains low-rank adapter matrices and the classification head, then exports the merged model for standard Transformers loading.

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:

LabelMeaning
self_monitorSymptoms appear mild and may be monitored, assuming no worsening or additional warning signs.
consult_gpA general practitioner or non-emergency medical professional should be consulted.
urgentSymptoms may require urgent medical attention or emergency evaluation.

The label mapping is included in label_map.json and in the model configuration.

Expected mapping:

{
    0: "self_monitor",
    1: "consult_gp",
    2: "urgent",
}

Training Data

The model was trained on the cristian-untaru/symcat-medical-triage-dataset, a SymCAT-derived dataset prepared for academic experiments in medical pre-triage classification.

The dataset contains English symptom-based text examples labeled into three triage classes:

  • self_monitor
  • consult_gp
  • urgent

Dataset split used for training:

SplitExamples
Train490
Validation105
Test106
Total701

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.

Training Procedure

Base checkpoint:

microsoft/BiomedNLP-BiomedBERT-base-uncased-abstract-fulltext
ParameterValue
Fine-tuning methodLow-Rank Adaptation (LoRA)
Maximum sequence length128
Epochs8
Train batch size16
Evaluation batch size32
Learning rate0.0002
Weight decay0.01
Warmup ratio0.1
Mixed precisionFP16
Early stopping patience3
Best checkpoint metricf1
Random seed42
LoRA rank16
LoRA alpha32
LoRA dropout0.1
Target modulesquery, value
Modules saved with adapterpooler, classifier

Additional training metadata is available in training_config.json.

Evaluation Results

The model was evaluated on the held-out test split.

MetricTest Score
Accuracy0.8208
Macro Precision0.8385
Macro Recall / Sensitivity0.8205
Macro Specificity0.9089
Macro F10.8254
Macro AUC OvR0.9255
Macro IoU / Jaccard0.7065
Test Loss0.5257

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.

How to Use

from transformers import AutoTokenizer, AutoModelForSequenceClassification
import torch

repo_id = "cristian-untaru/lora-biomedbert-medical-triage"

tokenizer = AutoTokenizer.from_pretrained(repo_id)
model = AutoModelForSequenceClassification.from_pretrained(repo_id)

text = "I have chest pain, shortness of breath, and I feel dizzy."

inputs = tokenizer(
    text,
    return_tensors="pt",
    truncation=True,
    padding=True,
    max_length=128
)

with torch.no_grad():
    outputs = model(**inputs)
    probabilities = torch.softmax(outputs.logits, dim=-1)
    predicted_class_id = torch.argmax(probabilities, dim=-1).item()

predicted_label = model.config.id2label[predicted_class_id]
confidence = probabilities[0][predicted_class_id].item()

print("Predicted label:", predicted_label)
print("Confidence:", round(confidence, 4))

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

FileDescription
config.jsonModel architecture, label mapping, and classification configuration.
model.safetensorsModel weights in SafeTensors format.
tokenizer.jsonTokenizer vocabulary and processing pipeline.
tokenizer_config.jsonTokenizer configuration.
training_config.jsonHuman-readable training configuration.
label_map.jsonMapping between numeric class IDs and triage labels.
README.mdModel card documentation.
.gitattributesGit 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.

Related Datasets

Related Models

Full Fine-Tuned Models

LoRA Models

Bottleneck MLP Adapter Models

Frozen Encoder Models

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · transformers · text-classification

Можно запустить

Подбираем GPU…

Класс архитектуры
BertForSequenceClassification
Ревизия весов
4c33577

0 моделей