mymusise commited on
Commit
5749380
1 Parent(s): 80a15e0

update example

Browse files

Signed-off-by: mymusise <[email protected]>

Files changed (1) hide show
  1. README.md +2 -2
README.md CHANGED
@@ -27,8 +27,8 @@ tokenizer = BertTokenizer.from_pretrained("mymusise/EasternFantasyNoval")
27
  model = TFGPT2LMHeadModel.from_pretrained("mymusise/EasternFantasyNoval")
28
 
29
  text_generator = TextGenerationPipeline(model, tokenizer)
30
- print(text_generator("今日", max_length=64, do_sample=True, top_k=10))
31
- print(text_generator("跨越山丘", max_length=64, do_sample=True, top_k=10))
32
  ```
33
  输出
34
  ```text
 
27
  model = TFGPT2LMHeadModel.from_pretrained("mymusise/EasternFantasyNoval")
28
 
29
  text_generator = TextGenerationPipeline(model, tokenizer)
30
+ print(text_generator("今日", max_length=64, repetition_penalty=1.3, do_sample=True, top_k=10))
31
+ print(text_generator("跨越山丘", max_length=64, repetition_penalty=1.3, do_sample=True, top_k=10))
32
  ```
33
  输出
34
  ```text