commit files to HF hub
Browse files- README.md +138 -0
- eval/metric.first.answer.paragraph_answer.question.lmqg_qg_itquad.default.json +1 -0
- eval/metric.first.sentence.paragraph_answer.question.lmqg_qg_itquad.default.json +1 -0
- eval/samples.test.hyp.paragraph_answer.question.lmqg_qg_itquad.default.txt +0 -0
- eval/samples.validation.hyp.paragraph_answer.question.lmqg_qg_itquad.default.txt +0 -0
README.md
ADDED
@@ -0,0 +1,138 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
|
2 |
+
---
|
3 |
+
license: cc-by-4.0
|
4 |
+
metrics:
|
5 |
+
- bleu4
|
6 |
+
- meteor
|
7 |
+
- rouge-l
|
8 |
+
- bertscore
|
9 |
+
- moverscore
|
10 |
+
language: it
|
11 |
+
datasets:
|
12 |
+
- lmqg/qg_itquad
|
13 |
+
pipeline_tag: text2text-generation
|
14 |
+
tags:
|
15 |
+
- question generation
|
16 |
+
widget:
|
17 |
+
- text: "<hl> Dopo il 1971 <hl> , l' OPEC ha tardato ad adeguare i prezzi per riflettere tale deprezzamento."
|
18 |
+
example_title: "Question Generation Example 1"
|
19 |
+
- text: "L' individuazione del petrolio e lo sviluppo di nuovi giacimenti richiedeva in genere <hl> da cinque a dieci anni <hl> prima di una produzione significativa."
|
20 |
+
example_title: "Question Generation Example 2"
|
21 |
+
- text: "il <hl> Giappone <hl> è stato il paese più dipendente dal petrolio arabo."
|
22 |
+
example_title: "Question Generation Example 3"
|
23 |
+
model-index:
|
24 |
+
- name: vocabtrimmer/mbart-large-cc25-trimmed-it-itquad-qg
|
25 |
+
results:
|
26 |
+
- task:
|
27 |
+
name: Text2text Generation
|
28 |
+
type: text2text-generation
|
29 |
+
dataset:
|
30 |
+
name: lmqg/qg_itquad
|
31 |
+
type: default
|
32 |
+
args: default
|
33 |
+
metrics:
|
34 |
+
- name: BLEU4 (Question Generation)
|
35 |
+
type: bleu4_question_generation
|
36 |
+
value: 7.4
|
37 |
+
- name: ROUGE-L (Question Generation)
|
38 |
+
type: rouge_l_question_generation
|
39 |
+
value: 22.57
|
40 |
+
- name: METEOR (Question Generation)
|
41 |
+
type: meteor_question_generation
|
42 |
+
value: 18.94
|
43 |
+
- name: BERTScore (Question Generation)
|
44 |
+
type: bertscore_question_generation
|
45 |
+
value: 81.06
|
46 |
+
- name: MoverScore (Question Generation)
|
47 |
+
type: moverscore_question_generation
|
48 |
+
value: 57.38
|
49 |
+
---
|
50 |
+
|
51 |
+
# Model Card of `vocabtrimmer/mbart-large-cc25-trimmed-it-itquad-qg`
|
52 |
+
This model is fine-tuned version of [ckpts/mbart-large-cc25-trimmed-it](https://huggingface.co/ckpts/mbart-large-cc25-trimmed-it) for question generation task on the [lmqg/qg_itquad](https://huggingface.co/datasets/lmqg/qg_itquad) (dataset_name: default) via [`lmqg`](https://github.com/asahi417/lm-question-generation).
|
53 |
+
|
54 |
+
|
55 |
+
### Overview
|
56 |
+
- **Language model:** [ckpts/mbart-large-cc25-trimmed-it](https://huggingface.co/ckpts/mbart-large-cc25-trimmed-it)
|
57 |
+
- **Language:** it
|
58 |
+
- **Training data:** [lmqg/qg_itquad](https://huggingface.co/datasets/lmqg/qg_itquad) (default)
|
59 |
+
- **Online Demo:** [https://autoqg.net/](https://autoqg.net/)
|
60 |
+
- **Repository:** [https://github.com/asahi417/lm-question-generation](https://github.com/asahi417/lm-question-generation)
|
61 |
+
- **Paper:** [https://arxiv.org/abs/2210.03992](https://arxiv.org/abs/2210.03992)
|
62 |
+
|
63 |
+
### Usage
|
64 |
+
- With [`lmqg`](https://github.com/asahi417/lm-question-generation#lmqg-language-model-for-question-generation-)
|
65 |
+
```python
|
66 |
+
from lmqg import TransformersQG
|
67 |
+
|
68 |
+
# initialize model
|
69 |
+
model = TransformersQG(language="it", model="vocabtrimmer/mbart-large-cc25-trimmed-it-itquad-qg")
|
70 |
+
|
71 |
+
# model prediction
|
72 |
+
questions = model.generate_q(list_context="Dopo il 1971 , l' OPEC ha tardato ad adeguare i prezzi per riflettere tale deprezzamento.", list_answer="Dopo il 1971")
|
73 |
+
|
74 |
+
```
|
75 |
+
|
76 |
+
- With `transformers`
|
77 |
+
```python
|
78 |
+
from transformers import pipeline
|
79 |
+
|
80 |
+
pipe = pipeline("text2text-generation", "vocabtrimmer/mbart-large-cc25-trimmed-it-itquad-qg")
|
81 |
+
output = pipe("<hl> Dopo il 1971 <hl> , l' OPEC ha tardato ad adeguare i prezzi per riflettere tale deprezzamento.")
|
82 |
+
|
83 |
+
```
|
84 |
+
|
85 |
+
## Evaluation
|
86 |
+
|
87 |
+
|
88 |
+
- ***Metric (Question Generation)***: [raw metric file](https://huggingface.co/vocabtrimmer/mbart-large-cc25-trimmed-it-itquad-qg/raw/main/eval/metric.first.sentence.paragraph_answer.question.lmqg_qg_itquad.default.json)
|
89 |
+
|
90 |
+
| | Score | Type | Dataset |
|
91 |
+
|:-----------|--------:|:--------|:-----------------------------------------------------------------|
|
92 |
+
| BERTScore | 81.06 | default | [lmqg/qg_itquad](https://huggingface.co/datasets/lmqg/qg_itquad) |
|
93 |
+
| Bleu_1 | 22.99 | default | [lmqg/qg_itquad](https://huggingface.co/datasets/lmqg/qg_itquad) |
|
94 |
+
| Bleu_2 | 15.06 | default | [lmqg/qg_itquad](https://huggingface.co/datasets/lmqg/qg_itquad) |
|
95 |
+
| Bleu_3 | 10.41 | default | [lmqg/qg_itquad](https://huggingface.co/datasets/lmqg/qg_itquad) |
|
96 |
+
| Bleu_4 | 7.4 | default | [lmqg/qg_itquad](https://huggingface.co/datasets/lmqg/qg_itquad) |
|
97 |
+
| METEOR | 18.94 | default | [lmqg/qg_itquad](https://huggingface.co/datasets/lmqg/qg_itquad) |
|
98 |
+
| MoverScore | 57.38 | default | [lmqg/qg_itquad](https://huggingface.co/datasets/lmqg/qg_itquad) |
|
99 |
+
| ROUGE_L | 22.57 | default | [lmqg/qg_itquad](https://huggingface.co/datasets/lmqg/qg_itquad) |
|
100 |
+
|
101 |
+
|
102 |
+
|
103 |
+
## Training hyperparameters
|
104 |
+
|
105 |
+
The following hyperparameters were used during fine-tuning:
|
106 |
+
- dataset_path: lmqg/qg_itquad
|
107 |
+
- dataset_name: default
|
108 |
+
- input_types: paragraph_answer
|
109 |
+
- output_types: question
|
110 |
+
- prefix_types: None
|
111 |
+
- model: ckpts/mbart-large-cc25-trimmed-it
|
112 |
+
- max_length: 512
|
113 |
+
- max_length_output: 32
|
114 |
+
- epoch: 8
|
115 |
+
- batch: 8
|
116 |
+
- lr: 0.0001
|
117 |
+
- fp16: False
|
118 |
+
- random_seed: 1
|
119 |
+
- gradient_accumulation_steps: 8
|
120 |
+
- label_smoothing: 0.15
|
121 |
+
|
122 |
+
The full configuration can be found at [fine-tuning config file](https://huggingface.co/vocabtrimmer/mbart-large-cc25-trimmed-it-itquad-qg/raw/main/trainer_config.json).
|
123 |
+
|
124 |
+
## Citation
|
125 |
+
```
|
126 |
+
@inproceedings{ushio-etal-2022-generative,
|
127 |
+
title = "{G}enerative {L}anguage {M}odels for {P}aragraph-{L}evel {Q}uestion {G}eneration",
|
128 |
+
author = "Ushio, Asahi and
|
129 |
+
Alva-Manchego, Fernando and
|
130 |
+
Camacho-Collados, Jose",
|
131 |
+
booktitle = "Proceedings of the 2022 Conference on Empirical Methods in Natural Language Processing",
|
132 |
+
month = dec,
|
133 |
+
year = "2022",
|
134 |
+
address = "Abu Dhabi, U.A.E.",
|
135 |
+
publisher = "Association for Computational Linguistics",
|
136 |
+
}
|
137 |
+
|
138 |
+
```
|
eval/metric.first.answer.paragraph_answer.question.lmqg_qg_itquad.default.json
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
{"validation": {"Bleu_1": 0.23087067031085245, "Bleu_2": 0.15415059373770354, "Bleu_3": 0.10856486748006203, "Bleu_4": 0.07873046332873804}, "test": {"Bleu_1": 0.22014960408124712, "Bleu_2": 0.14330754041565522, "Bleu_3": 0.09883772934835909, "Bleu_4": 0.07012552373856115}}
|
eval/metric.first.sentence.paragraph_answer.question.lmqg_qg_itquad.default.json
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
{"validation": {"Bleu_1": 0.23198690544134656, "Bleu_2": 0.155044685456534, "Bleu_3": 0.10930111840821523, "Bleu_4": 0.07934065813428705, "METEOR": 0.19749778490966646, "ROUGE_L": 0.23228498429226976, "BERTScore": 0.8185450898258807, "MoverScore": 0.5827791970827807}, "test": {"Bleu_1": 0.22987607201158541, "Bleu_2": 0.1505689013475674, "Bleu_3": 0.10414336529734433, "Bleu_4": 0.07402603207398903, "METEOR": 0.18935354604081714, "ROUGE_L": 0.22565543720614775, "BERTScore": 0.8105805082699707, "MoverScore": 0.573768183313954}}
|
eval/samples.test.hyp.paragraph_answer.question.lmqg_qg_itquad.default.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|
eval/samples.validation.hyp.paragraph_answer.question.lmqg_qg_itquad.default.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|