tsilva/clinical-field-mapper-classification
By tsilva · ↓ 5 · ♥ 0 · Updated 2025-05-06
What's in this repo
This page lists the files in tsilva/clinical-field-mapper-classification, including model.onnx.
- 1 ONNX models (.onnx files)
- 28 files, including 12 .json, 6 .txt, 5 .zip, 1 .md, 1 .safetensors, 1 .onnx
- Last updated 2025-05-06
ONNX files
| File | Size | Download |
|---|---|---|
| onnx/model.onnx | — | Download |
How to use
These ONNX files can be loaded with ONNX Runtime. To inspect a model graph, upload the file to the Netron viewer. Download links point to the original files on Hugging Face.
README
Model Card for tsilva/clinical-field-mapper-classification
This model is a fine-tuned version of distilbert/distilgpt2 on the tsilva/clinical-field-mappings dataset.
Its purpose is to normalize healthcare database column names to a standardized set of target column names.
Task
This model is a sequence classification model that maps free-text field names to a set of standardized schema terms.
Usage
from transformers import AutoTokenizer, AutoModelForSequenceClassification
tokenizer = AutoTokenizer.from_pretrained("tsilva/clinical-field-mapper-classification") model = AutoModelForSequenceClassification.from_pretrained("tsilva/clinical-field-mapper-classification")
def predict(input_text): inputs = tokenizer(input_text, return_tensors="pt") outputs = model(**inputs) pred = outputs.logits.argmax(-1).item() label = model.config.id2label[str(pred)] if hasattr(model.config, 'id2label') else pred print(f"Predicted label: family_history_reported")
predict('cardi@')
Evaluation Results
- train accuracy: 94.71%
- validation accuracy: 91.44%
- test accuracy: 91.56%
Training Details
- Seed: 42
- Epochs scheduled: 50
- Epochs completed: 34
- Early stopping triggered: Yes
- Final training loss: 1.0888
- Final evaluation loss: 0.9916
- Optimizer: adamw_bnb_8bit
- Learning rate: 0.0005
- Batch size: 1024
- Precision: fp16
- DeepSpeed enabled: True
- Gradient accumulation steps: 1
License
Specify your license here (e.g., Apache 2.0, MIT, etc.)
Limitations and Bias
- Model was trained on a specific clinical mapping dataset.
- Performance may vary on out-of-distribution column names.
- Ensure you validate model outputs in production environments.
Model info
Created: 2025-05-05
Updated: 2025-05-06
View on Hugging Face