Downloads · 30 days
10
18% of all-time downloads
oliviercaron/gliner-fr-adr-twitter
gliner-fr-adr-twitter is a token classification model from oliviercaron. Use it when you need labels on individual words, such as names. It is set up for gliner. The card lists the license as apache-2.0.
This repository contains a fine-tuned GLiNER model trained to detect COVID-19 vaccine side effects in French tweets. The model was trained with a single entity label: EffetSecondaire.
Downloads · 30 days
10
18% of all-time downloads
All-time downloads
57
Public
Repo size
1.2 GB
Likes
0
Public
Click a slice to open those files.
.bin1.2 GB · 98%
From the Hugging Face model README
This repository contains a fine-tuned GLiNER model trained to detect COVID-19 vaccine side effects in French tweets.
The model was trained with a single entity label: Effet_Secondaire.
microsoft/mdeberta-v3-base["Effet_Secondaire"]Effet_SecondaireExample from the dataset:
"La Norvège s'inquiète d'hémorragies cutanées chez des jeunes ayant reçu le vaccin AstraZeneca."
→ Detected entity:hémorragies cutanées→ Effet_Secondaire
microsoft/mdeberta-v3-base1e-5, classifier 5e-50.48384# pip install -U gliner torch
from gliner import GLiNER
# Load the fine-tuned model from Hugging Face
model = GLiNER.from_pretrained("oliviercaron/gliner-fr-adr-twitter")
# Single label used during training
labels = ["Effet_Secondaire"]
# --- Single text ---
text = "La Norvège s'inquiète d'hémorragies cutanées chez des jeunes ayant reçu le vaccin AstraZeneca."
entities = model.predict_entities(text, labels, threshold=0.5)
for ent in entities:
print(ent["text"], "=>", ent.get("type") or ent.get("label"), "@", round(ent["score"], 2))
# --- Multiple texts (batch) ---
texts = [
"Après ma deuxième dose, j’ai eu une forte fièvre et des courbatures toute la nuit.",
"Le vaccin m'a donné des nausées et un gros mal de tête le lendemain.",
"Depuis la vaccination, j’ai ressenti des vertiges et une fatigue inhabituelle.",
"J’ai eu de fortes douleurs au bras après le vaccin Pfizer.",
]
batch = model.batch_predict_entities(texts, labels, threshold=0.5)
for i, ents in enumerate(batch, start=1):
print(f"\nText {i}: {texts[i-1]}")
if not ents:
print(" - No detected side effects.")
for ent in ents:
print(" -", ent["text"], "=>", ent.get("type") or ent.get("label"), "@", round(ent["score"], 4))
hémorragies cutanées => Effet_Secondaire @ 0.95
Text 1: Après ma deuxième dose, j’ai eu une forte fièvre et des courbatures toute la nuit.
- fièvre => Effet_Secondaire @ 0.8867
- courbatures => Effet_Secondaire @ 0.9674
Text 2: Le vaccin m'a donné des nausées et un gros mal de tête le lendemain.
- nausées => Effet_Secondaire @ 0.9735
- mal de tête => Effet_Secondaire @ 0.5509
Text 3: Depuis la vaccination, j’ai ressenti des vertiges et une fatigue inhabituelle.
- vertiges => Effet_Secondaire @ 0.9713
- fatigue inhabituelle => Effet_Secondaire @ 0.8576
Text 4: J’ai eu de fortes douleurs au bras après le vaccin Pfizer.
- douleurs => Effet_Secondaire @ 0.5328
This model was developed for research in social media analysis (marketing),
to automatically identify user-reported side effects in French tweets about COVID-19 vaccination.
It is not intended for clinical or diagnostic use.
Effet_Secondaire).| Metric | Value | Description |
|---|---|---|
| F1-score | 0.81 | Evaluated on a 20% held-out test split |
Caron, Olivier (2025). GLiNER - French COVID-19 Vaccine Side Effects (Twitter).
Hugging Face. https://huggingface.co/oliviercaron/gliner-fr-adr-twitter