rigonsallauka commited on
Commit
e9fe1e7
1 Parent(s): 7145780

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +66 -3
README.md CHANGED
@@ -1,3 +1,66 @@
1
- ---
2
- license: apache-2.0
3
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ datasets:
4
+ - rigonsallauka/italian_ner_dataset
5
+ language:
6
+ - it
7
+ metrics:
8
+ - f1
9
+ - precision
10
+ - recall
11
+ - confusion_matrix
12
+ base_model:
13
+ - google-bert/bert-base-cased
14
+ pipeline_tag: token-classification
15
+ tags:
16
+ - NER
17
+ - medical
18
+ - symptom
19
+ - extraction
20
+ - italian
21
+ ---
22
+ # Italian Medical NER
23
+
24
+ ## Use
25
+ - **Primary Use Case**: This model is designed to extract medical entities such as symptoms, diagnostic tests, and treatments from clinical text in the Italian language.
26
+ - **Applications**: Suitable for healthcare professionals, clinical data analysis, and research into medical text processing.
27
+ - **Supported Entity Types**:
28
+ - `PROBLEM`: Diseases, symptoms, and medical conditions.
29
+ - `TEST`: Diagnostic procedures and laboratory tests.
30
+ - `TREATMENT`: Medications, therapies, and other medical interventions.
31
+
32
+ ## Training Data
33
+ - **Data Sources**: Annotated datasets, including clinical data and translations of English medical text into Italian.
34
+ - **Data Augmentation**: The training dataset underwent data augmentation techniques to improve the model's ability to generalize to different text structures.
35
+ - **Dataset Split**:
36
+ - **Training Set**: 80%
37
+ - **Validation Set**: 10%
38
+ - **Test Set**: 10%
39
+
40
+ ## Model Training
41
+ - **Training Configuration**:
42
+ - **Optimizer**: AdamW
43
+ - **Learning Rate**: 3e-5
44
+ - **Batch Size**: 64
45
+ - **Epochs**: 200
46
+ - **Loss Function**: Focal Loss to handle class imbalance
47
+ - **Frameworks**: PyTorch, Hugging Face Transformers, SimpleTransformers
48
+
49
+ ## How to Use
50
+ You can easily use this model with the Hugging Face `transformers` library. Here's an example of how to load and use the model for inference:
51
+
52
+ ```python
53
+ from transformers import AutoTokenizer, AutoModelForTokenClassification
54
+ import torch
55
+
56
+ model_name = "rigonsallauka/italian_medical_ner"
57
+
58
+ # Load the tokenizer and model
59
+ tokenizer = AutoTokenizer.from_pretrained(model_name)
60
+ model = AutoModelForTokenClassification.from_pretrained(model_name)
61
+
62
+ # Sample text for inference
63
+ text = "Il paziente ha lamentato forti mal di testa e nausea che persistevano da due giorni. Per alleviare i sintomi, gli è stato prescritto il paracetamolo e gli è stato consigliato di riposare e bere molti liquidi."
64
+
65
+ # Tokenize the input text
66
+ inputs = tokenizer(text, return_tensors="pt")