Update README.md
Browse files
README.md
CHANGED
@@ -10,6 +10,42 @@ model-index:
|
|
10 |
<!-- This model card has been generated automatically according to the information Keras had access to. You should
|
11 |
probably proofread and complete it, then remove this comment. -->
|
12 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
13 |
# articleGeneratorV1.0
|
14 |
|
15 |
This model is a fine-tuned version of [t5-small](https://huggingface.co/t5-small) on an unknown dataset.
|
|
|
10 |
<!-- This model card has been generated automatically according to the information Keras had access to. You should
|
11 |
probably proofread and complete it, then remove this comment. -->
|
12 |
|
13 |
+
# What does model do and how to use it
|
14 |
+
|
15 |
+
Just provide an title to the model and it will generate a whole article about it.
|
16 |
+
|
17 |
+
```python
|
18 |
+
# Install transformers library
|
19 |
+
!pip install transformers
|
20 |
+
```
|
21 |
+
|
22 |
+
```python
|
23 |
+
# Load tokenizer and model
|
24 |
+
from transformers import AutoTokenizer, AutoModelForSeq2SeqLM, TFAutoModelForSeq2SeqLM
|
25 |
+
model_name = "Seungjun/articleGeneratorV1.0"
|
26 |
+
tokenizer = AutoTokenizer.from_pretrained("t5-small")
|
27 |
+
model = TFAutoModelForSeq2SeqLM.from_pretrained(model_name)
|
28 |
+
```
|
29 |
+
|
30 |
+
```python
|
31 |
+
# Get the article for a given title
|
32 |
+
from transformers import pipeline
|
33 |
+
summarizer = pipeline("summarization", model=model, tokenizer=tokenizer, framework="tf")
|
34 |
+
summarizer(
|
35 |
+
"Steve Jobs", # title
|
36 |
+
min_length=500,
|
37 |
+
max_length=1024,
|
38 |
+
)
|
39 |
+
```
|
40 |
+
|
41 |
+
Result:
|
42 |
+
|
43 |
+
|
44 |
+
|
45 |
+
# Current limitation of the model
|
46 |
+
|
47 |
+
It generate aot of lies. 99% of the word generated by this model is not true.
|
48 |
+
|
49 |
# articleGeneratorV1.0
|
50 |
|
51 |
This model is a fine-tuned version of [t5-small](https://huggingface.co/t5-small) on an unknown dataset.
|