rbattle commited on
Commit
5f35b45
1 Parent(s): 492f68c

Model Card

Browse files
Files changed (1) hide show
  1. README.md +38 -0
README.md CHANGED
@@ -1,3 +1,41 @@
1
  ---
2
  license: apache-2.0
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  license: apache-2.0
3
  ---
4
+
5
+ # T5-v1.1-Small Question Generator
6
+
7
+ ## Model Description
8
+
9
+ This model is a sequence-to-sequence question generator which takes an answer and context as an input, and generates a question as an output. It is based on Google's pretrained [T5-v1.1-Small](https://huggingface.co/google/t5-v1_1-small) model.
10
+
11
+ It was trained with and intended to be used with [AMontgomerie/question_generator](https://github.com/AMontgomerie/question_generator).
12
+
13
+ ## Intended uses & limitations
14
+
15
+ The model is trained to generate reading comprehension-style questions with answers extracted from a text. The model performs best with full sentence answers, but can also be used with single word or short phrase answers.
16
+
17
+ ### How to use
18
+
19
+ The model takes concatenated answers and context as an input sequence, and will generate a full question sentence as an output sequence. The max sequence length is 512 tokens. Inputs should be organized into the following format:
20
+
21
+ ```
22
+ <answer> answer text here <context> context text here
23
+ ```
24
+
25
+ The input sequence can then be encoded and passed as the `input_ids` argument in the model's `generate()` method.
26
+
27
+ For best results, a large number of questions can be generated, and then filtered using [iarfmoose/bert-base-cased-qa-evaluator](https://huggingface.co/iarfmoose/bert-base-cased-qa-evaluator).
28
+
29
+ For examples, please see https://github.com/iarfmoose/question_generator.
30
+
31
+ ### Limitations and bias
32
+
33
+ The model is limited to generating questions in the same style as those found in [SQuAD](https://rajpurkar.github.io/SQuAD-explorer/), [CoQA](https://stanfordnlp.github.io/coqa/), and [MSMARCO](https://microsoft.github.io/msmarco/). The generated questions can potentially be leading or reflect biases that are present in the context. If the context is too short or completely absent, or if the context and answer do not match, the generated question is likely to be incoherent.
34
+
35
+ ## Training data
36
+
37
+ The model was fine-tuned on a dataset made up of several well-known QA datasets ([SQuAD](https://rajpurkar.github.io/SQuAD-explorer/), [CoQA](https://stanfordnlp.github.io/coqa/), and [MSMARCO](https://microsoft.github.io/msmarco/)). The datasets were restructured by concatenating the answer and context fields into the previously-mentioned format. The question field from the datasets was used as the target during training. The [full training set](https://huggingface.co/datasets/iarfmoose/question_generator) was roughly 200,000 examples.
38
+
39
+ ## Training procedure
40
+
41
+ The model was trained for 20 epochs over the training set with a learning rate of 1e-3. The batch size was kept at 4 to match the original training strategy used by [iarfmoose](https://huggingface.co/iarfmoose).