
# Model Card of `vocabtrimmer/mt5-small-trimmed-fr-10000-frquad-qa`
This model is fine-tuned version of [vocabtrimmer/mt5-small-trimmed-fr-10000](https://huggingface.co/vocabtrimmer/mt5-small-trimmed-fr-10000) for question answering task on the [lmqg/qg_frquad](https://huggingface.co/datasets/lmqg/qg_frquad) (dataset_name: default) via [`lmqg`](https://github.com/asahi417/lm-question-generation).


### Overview
- **Language model:** [vocabtrimmer/mt5-small-trimmed-fr-10000](https://huggingface.co/vocabtrimmer/mt5-small-trimmed-fr-10000)   
- **Language:** fr  
- **Training data:** [lmqg/qg_frquad](https://huggingface.co/datasets/lmqg/qg_frquad) (default)
- **Online Demo:** [https://autoqg.net/](https://autoqg.net/)
- **Repository:** [https://github.com/asahi417/lm-question-generation](https://github.com/asahi417/lm-question-generation)
- **Paper:** [https://arxiv.org/abs/2210.03992](https://arxiv.org/abs/2210.03992)

### Usage
- With [`lmqg`](https://github.com/asahi417/lm-question-generation#lmqg-language-model-for-question-generation-)
```python
from lmqg import TransformersQG

# initialize model
model = TransformersQG(language="fr", model="vocabtrimmer/mt5-small-trimmed-fr-10000-frquad-qa")

# model prediction
answers = model.answer_q(list_question="En quelle année a-t-on trouvé trace d'un haut fourneau similaire?", list_context=" Cette technologie ne disparaît qu'au début du XXe siècle. On retrouve vers 1900 un haut fourneau similaire dans le Bulacan, aux Philippines. Plus tard encore, le « haut fourneau dans la cour » prôné par Mao Zedong pendant le Grand Bond en avant est de ce type. L'expérience n'est un échec technique que dans les régions où le savoir-faire n'existe pas, ou a disparu.")

```

- With `transformers`
```python
from transformers import pipeline

pipe = pipeline("text2text-generation", "vocabtrimmer/mt5-small-trimmed-fr-10000-frquad-qa")
output = pipe("question: En quelle année a-t-on trouvé trace d'un haut fourneau similaire?, context: Cette technologie ne disparaît qu'au début du XXe siècle. On retrouve vers 1900 un haut fourneau similaire dans le Bulacan, aux Philippines. Plus tard encore, le « haut fourneau dans la cour » prôné par Mao Zedong pendant le Grand Bond en avant est de ce type. L'expérience n'est un échec technique que dans les régions où le savoir-faire n'existe pas, ou a disparu.")

```

## Evaluation


- ***Metric (Question Answering)***: [raw metric file](https://huggingface.co/vocabtrimmer/mt5-small-trimmed-fr-10000-frquad-qa/raw/main/eval/metric.first.answer.paragraph_question.answer.lmqg_qg_frquad.default.json) 

|                  |   Score | Type    | Dataset                                                          |
|:-----------------|--------:|:--------|:-----------------------------------------------------------------|
| AnswerExactMatch |   30.24 | default | [lmqg/qg_frquad](https://huggingface.co/datasets/lmqg/qg_frquad) |
| AnswerF1Score    |   47.59 | default | [lmqg/qg_frquad](https://huggingface.co/datasets/lmqg/qg_frquad) |
| BERTScore        |   89.65 | default | [lmqg/qg_frquad](https://huggingface.co/datasets/lmqg/qg_frquad) |
| Bleu_1           |   28.11 | default | [lmqg/qg_frquad](https://huggingface.co/datasets/lmqg/qg_frquad) |
| Bleu_2           |   23.97 | default | [lmqg/qg_frquad](https://huggingface.co/datasets/lmqg/qg_frquad) |
| Bleu_3           |   21.1  | default | [lmqg/qg_frquad](https://huggingface.co/datasets/lmqg/qg_frquad) |
| Bleu_4           |   18.63 | default | [lmqg/qg_frquad](https://huggingface.co/datasets/lmqg/qg_frquad) |
| METEOR           |   23.73 | default | [lmqg/qg_frquad](https://huggingface.co/datasets/lmqg/qg_frquad) |
| MoverScore       |   72.01 | default | [lmqg/qg_frquad](https://huggingface.co/datasets/lmqg/qg_frquad) |
| ROUGE_L          |   29.33 | default | [lmqg/qg_frquad](https://huggingface.co/datasets/lmqg/qg_frquad) |



## Training hyperparameters

The following hyperparameters were used during fine-tuning:
 - dataset_path: lmqg/qg_frquad
 - dataset_name: default
 - input_types: ['paragraph_question']
 - output_types: ['answer']
 - prefix_types: None
 - model: vocabtrimmer/mt5-small-trimmed-fr-10000
 - max_length: 512
 - max_length_output: 32
 - epoch: 25
 - batch: 32
 - lr: 0.0005
 - fp16: False
 - random_seed: 1
 - gradient_accumulation_steps: 2
 - label_smoothing: 0.15

The full configuration can be found at [fine-tuning config file](https://huggingface.co/vocabtrimmer/mt5-small-trimmed-fr-10000-frquad-qa/raw/main/trainer_config.json).

## Citation
```
@inproceedings{ushio-etal-2022-generative,
    title = "{G}enerative {L}anguage {M}odels for {P}aragraph-{L}evel {Q}uestion {G}eneration",
    author = "Ushio, Asahi  and
        Alva-Manchego, Fernando  and
        Camacho-Collados, Jose",
    booktitle = "Proceedings of the 2022 Conference on Empirical Methods in Natural Language Processing",
    month = dec,
    year = "2022",
    address = "Abu Dhabi, U.A.E.",
    publisher = "Association for Computational Linguistics",
}

```

{"language": "fr", "license": "cc-by-4.0", "tags": ["question answering"], "datasets": ["lmqg/qg_frquad"], "metrics": ["bleu4", "meteor", "rouge-l", "bertscore", "moverscore"], "pipeline_tag": "text2text-generation", "widget": [{"text": "question: En quelle ann\u00e9e a-t-on trouv\u00e9 trace d'un haut fourneau similaire?, context: Cette technologie ne dispara\u00eet qu'au d\u00e9but du XXe si\u00e8cle. On retrouve vers 1900 un haut fourneau similaire dans le Bulacan, aux Philippines. Plus tard encore, le \u00ab haut fourneau dans la cour \u00bb pr\u00f4n\u00e9 par Mao Zedong pendant le Grand Bond en avant est de ce type. L'exp\u00e9rience n'est un \u00e9chec technique que dans les r\u00e9gions o\u00f9 le savoir-faire n'existe pas, ou a disparu.", "example_title": "Question Answering Example 1"}, {"text": "question: Comment appelle-t-on la Guerre de 14-18 ?, context: Ce black dog peut \u00eatre li\u00e9 \u00e0 des \u00e9v\u00e8nements traumatisants issus du monde ext\u00e9rieur, tels que son renvoi de l'Amiraut\u00e9 apr\u00e8s la catastrophe des Dardanelles, lors de la Grande Guerre de 14-18, ou son rejet par l'\u00e9lectorat en juillet 1945. On sait \u00e9galement que dans ces deux cas, la gu\u00e9rison, certes lente et douloureuse et jamais compl\u00e8te ni d\u00e9finitive, se fera gr\u00e2ce \u00e0 la peinture. D'un autre c\u00f4t\u00e9, \u00e9tant donn\u00e9s les sympt\u00f4mes de ce mal que Churchill \u00e9prouvait de plus en plus, il ne pouvait rien moins qu'\u00eatre purement associ\u00e9 \u00e0 de telles causes extrins\u00e8ques, ce qui correspond au profil classique de la d\u00e9pression majeure unipolaire ou bipolaire.", "example_title": "Question Answering Example 2"}], "model-index": [{"name": "vocabtrimmer/mt5-small-trimmed-fr-10000-frquad-qa", "results": [{"task": {"type": "text2text-generation", "name": "Text2text Generation"}, "dataset": {"name": "lmqg/qg_frquad", "type": "default", "args": "default"}, "metrics": [{"type": "bleu4_question_answering", "value": 18.63, "name": "BLEU4 (Question Answering)"}, {"type": "rouge_l_question_answering", "value": 29.33, "name": "ROUGE-L (Question Answering)"}, {"type": "meteor_question_answering", "value": 23.73, "name": "METEOR (Question Answering)"}, {"type": "bertscore_question_answering", "value": 89.65, "name": "BERTScore (Question Answering)"}, {"type": "moverscore_question_answering", "value": 72.01, "name": "MoverScore (Question Answering)"}, {"type": "answer_f1_score__question_answering", "value": 47.59, "name": "AnswerF1Score (Question Answering)"}, {"type": "answer_exact_match_question_answering", "value": 30.24, "name": "AnswerExactMatch (Question Answering)"}]}]}]}
transformers pytorch mt5 text2text-generation question answering fr dataset:lmqg/qg_frquad arxiv:2210.03992 license:cc-by-4.0 model-index autotrain_compatible endpoints_compatible text-generation-inference region:us
TAGS
#transformers #pytorch #mt5 #text2text-generation #question answering #fr #dataset-lmqg/qg_frquad #arxiv-2210.03992 #license-cc-by-4.0 #model-index #autotrain_compatible #endpoints_compatible #text-generation-inference #region-us 

Model Card of 'vocabtrimmer/mt5-small-trimmed-fr-10000-frquad-qa'
=================================================================


This model is fine-tuned version of vocabtrimmer/mt5-small-trimmed-fr-10000 for question answering task on the lmqg/qg\_frquad (dataset\_name: default) via 'lmqg'.


### Overview


* Language model: vocabtrimmer/mt5-small-trimmed-fr-10000
* Language: fr
* Training data: lmqg/qg\_frquad (default)
* Online Demo: URL
* Repository: URL
* Paper: URL


### Usage


* With 'lmqg'
* With 'transformers'


Evaluation
----------


* *Metric (Question Answering)*: raw metric file



Training hyperparameters
------------------------


The following hyperparameters were used during fine-tuning:


* dataset\_path: lmqg/qg\_frquad
* dataset\_name: default
* input\_types: ['paragraph\_question']
* output\_types: ['answer']
* prefix\_types: None
* model: vocabtrimmer/mt5-small-trimmed-fr-10000
* max\_length: 512
* max\_length\_output: 32
* epoch: 25
* batch: 32
* lr: 0.0005
* fp16: False
* random\_seed: 1
* gradient\_accumulation\_steps: 2
* label\_smoothing: 0.15


The full configuration can be found at fine-tuning config file.



### Overview


* Language model: vocabtrimmer/mt5-small-trimmed-fr-10000
* Language: fr
* Training data: lmqg/qg\_frquad (default)
* Online Demo: URL
* Repository: URL
* Paper: URL ### Usage


* With 'lmqg'
* With 'transformers'


Evaluation
----------


* *Metric (Question Answering)*: raw metric file



Training hyperparameters
------------------------


The following hyperparameters were used during fine-tuning:


* dataset\_path: lmqg/qg\_frquad
* dataset\_name: default
* input\_types: ['paragraph\_question']
* output\_types: ['answer']
* prefix\_types: None
* model: vocabtrimmer/mt5-small-trimmed-fr-10000
* max\_length: 512
* max\_length\_output: 32
* epoch: 25
* batch: 32
* lr: 0.0005
* fp16: False
* random\_seed: 1
* gradient\_accumulation\_steps: 2
* label\_smoothing: 0.15


The full configuration can be found at fine-tuning config file.
TAGS
#transformers #pytorch #mt5 #text2text-generation #question answering #fr #dataset-lmqg/qg_frquad #arxiv-2210.03992 #license-cc-by-4.0 #model-index #autotrain_compatible #endpoints_compatible #text-generation-inference #region-us 
 ### Overview


* Language model: vocabtrimmer/mt5-small-trimmed-fr-10000
* Language: fr
* Training data: lmqg/qg\_frquad (default)
* Online Demo: URL
* Repository: URL
* Paper: URL ### Usage


* With 'lmqg'
* With 'transformers'


Evaluation
----------


* *Metric (Question Answering)*: raw metric file



Training hyperparameters
------------------------


The following hyperparameters were used during fine-tuning:


* dataset\_path: lmqg/qg\_frquad
* dataset\_name: default
* input\_types: ['paragraph\_question']
* output\_types: ['answer']
* prefix\_types: None
* model: vocabtrimmer/mt5-small-trimmed-fr-10000
* max\_length: 512
* max\_length\_output: 32
* epoch: 25
* batch: 32
* lr: 0.0005
* fp16: False
* random\_seed: 1
* gradient\_accumulation\_steps: 2
* label\_smoothing: 0.15


The full configuration can be found at fine-tuning config file.
TAGS
#transformers #pytorch #mt5 #text2text-generation #question answering #fr #dataset-lmqg/qg_frquad #arxiv-2210.03992 #license-cc-by-4.0 #model-index #autotrain_compatible #endpoints_compatible #text-generation-inference #region-us 
### Overview


* Language model: vocabtrimmer/mt5-small-trimmed-fr-10000
* Language: fr
* Training data: lmqg/qg\_frquad (default)
* Online Demo: URL
* Repository: URL
* Paper: URL### Usage


* With 'lmqg'
* With 'transformers'


Evaluation
----------


* *Metric (Question Answering)*: raw metric file



Training hyperparameters
------------------------


The following hyperparameters were used during fine-tuning:


* dataset\_path: lmqg/qg\_frquad
* dataset\_name: default
* input\_types: ['paragraph\_question']
* output\_types: ['answer']
* prefix\_types: None
* model: vocabtrimmer/mt5-small-trimmed-fr-10000
* max\_length: 512
* max\_length\_output: 32
* epoch: 25
* batch: 32
* lr: 0.0005
* fp16: False
* random\_seed: 1
* gradient\_accumulation\_steps: 2
* label\_smoothing: 0.15


The full configuration can be found at fine-tuning config file.