File size: 3,253 Bytes
506f950
 
91146dd
 
 
 
 
 
 
506f950
91146dd
b347047
91146dd
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
---
license: mit
language:
- fr
tags:
- Objectifs de développement durable (ODD)
- SDG
- FlauBERT Large
- BERT
---

# ilovebots/FlauBERT large SDG French

<!-- Provide a quick summary of what the model is/does. -->

Ce modèle permet de classer les textes en fonction des objectifs de développement durable (ODD) des Nations Unies.


<img src="https://www.ulaval.ca/sites/default/files/DD/ODD/Tableau%20ODD.jpg" alt="image" width="600"/>

Source: [https://www.un.org/development/desa/disabilities/about-us/sustainable-development-goals-sdgs-and-disability.html](https://www.un.org/development/desa/disabilities/about-us/sustainable-development-goals-sdgs-and-disability.html)


## Détails du modèle

### Description du modèle

<!-- Provide a longer summary of what this model is. -->

Ce modèle de classification de texte a été développé en fine-tuning le modèle pré-entraîné dbmdz/bert-base-french-europeana-cased.
Les données d'entraînement de ce modèle affiné proviennent de l'ensemble de données communautaires OSDG (OSDG-CD) accessible au public à l'adresse https://zenodo.org/record/5550238#.ZBulfcJByF4.
Ce modèle a été réalisé dans le cadre d'une recherche universitaire à l'[Université Laval](https://www.ulaval.ca/developpement-durable/objectifs-de-developpement-durable-de-lonu).<br>
L'objectif était de créer un modèle de classification de texte SDG basé sur transformers en français.<br>
Les principaux détails du modèle sont mis en évidence ci-dessous :

- **Model type:** Text classification
- **Language(s) (NLP):** French
- **License:** mit
- **Finetuned from model :** flaubert/flaubert_large_cased

### Model Sources
<!-- Provide the basic links for the model. -->
- **Repository:** https://huggingface.co/ilovebots/Flaubert_large_SDG_French

## How to Get Started with the Model

Utilisez le code ci-dessous pour commencer à utiliser le modèle.
```python
from transformers import AutoTokenizer, AutoModelForSequenceClassification
tokenizer = AutoTokenizer.from_pretrained("ilovebots/Flaubert_large_SDG_French")
model = AutoModelForSequenceClassification.from_pretrained("ilovebots/Flaubert_large_SDG_French")
```


## Training Data

<!-- This should link to a Data Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. -->
La base disponible dans https://zenodo.org/record/5550238#.ZBulfcJByF4 a été enrichie des objectifs de développement durable des Nations Unies et traduite en en français.

## Training Hyperparameters

- Num_epoch = 4
- Learning rate = 2e-5
- Epsilon = 1e-8
- Optimizer = AdamW
- Batch size = 32
- Seed random = 42


## Evaluation

#### Metrics

<!-- These are the evaluation metrics being used, ideally with a description of why. -->
- Accuracy = 0.84

<img src="https://raw.githubusercontent.com/I-Love-Bots/public/main/BertFinetuning.png" alt="image" width="600"/>

## Citation
Martinez, D.F. (2023). SDG classification with BERT. https://huggingface.co/ilovebots/Flaubert_large_SDG_French

<!-- If there is a paper or blog post introducing the model, the APA and Bibtex information for that should go in this section. -->


<!--## Model Card Contact -->