Update README.md
Browse files
README.md
CHANGED
@@ -34,18 +34,19 @@ inference:
|
|
34 |
|
35 |
# 💡GENIUS – generating text using sketches!
|
36 |
|
37 |
-
|
38 |
-
- **Paper: [GENIUS: Sketch-based Language Model Pre-training via Extreme and Selective Masking for Text Generation and Augmentation](https://arxiv.org/abs/2211.10330)**
|
39 |
-
- **GitHub: [GENIUS, Pre-training/Data Augmentation Tutorial](https://github.com/beyondguo/genius)**
|
40 |
-
|
41 |
**How to use:**
|
42 |
-
```
|
43 |
from transformers import pipeline
|
44 |
genius = pipeline("text2text-generation", model='beyond/genius-large', device=0)
|
45 |
sketch = "<mask> Conference on Empirical Methods <mask> submission of research papers <mask> Deep Learning <mask>"
|
46 |
genius(sketch, num_beams=3, do_sample=True, max_length=200)[0]['generated_text']
|
47 |
```
|
48 |
|
|
|
|
|
|
|
|
|
|
|
49 |
💡**GENIUS** is a powerful conditional text generation model using sketches as input, which can fill in the missing contexts for a given **sketch** (key information consisting of textual spans, phrases, or words, concatenated by mask tokens). GENIUS is pre-trained on a large-scale textual corpus with a novel *reconstruction from sketch* objective using an *extreme and selective masking* strategy, enabling it to generate diverse and high-quality texts given sketches.
|
50 |
|
51 |
**GENIUS** can also be used as a general textual **data augmentation tool** for **various NLP tasks** (including sentiment analysis, topic classification, NER, and QA).
|
|
|
34 |
|
35 |
# 💡GENIUS – generating text using sketches!
|
36 |
|
|
|
|
|
|
|
|
|
37 |
**How to use:**
|
38 |
+
```
|
39 |
from transformers import pipeline
|
40 |
genius = pipeline("text2text-generation", model='beyond/genius-large', device=0)
|
41 |
sketch = "<mask> Conference on Empirical Methods <mask> submission of research papers <mask> Deep Learning <mask>"
|
42 |
genius(sketch, num_beams=3, do_sample=True, max_length=200)[0]['generated_text']
|
43 |
```
|
44 |
|
45 |
+
- **Paper: [GENIUS: Sketch-based Language Model Pre-training via Extreme and Selective Masking for Text Generation and Augmentation](https://arxiv.org/abs/2211.10330)**
|
46 |
+
- **GitHub: [GENIUS, Pre-training/Data Augmentation Tutorial](https://github.com/beyondguo/genius)**
|
47 |
+
|
48 |
+
|
49 |
+
|
50 |
💡**GENIUS** is a powerful conditional text generation model using sketches as input, which can fill in the missing contexts for a given **sketch** (key information consisting of textual spans, phrases, or words, concatenated by mask tokens). GENIUS is pre-trained on a large-scale textual corpus with a novel *reconstruction from sketch* objective using an *extreme and selective masking* strategy, enabling it to generate diverse and high-quality texts given sketches.
|
51 |
|
52 |
**GENIUS** can also be used as a general textual **data augmentation tool** for **various NLP tasks** (including sentiment analysis, topic classification, NER, and QA).
|