FredZhang7
commited on
Commit
•
e4831f4
1
Parent(s):
d2e6900
Fixed examples
Browse files
README.md
CHANGED
@@ -83,9 +83,9 @@ No comma style:
|
|
83 |
![constrastive search](./constrastive_search.png)
|
84 |
|
85 |
|
86 |
-
To bring back the commas, assign output without `penalty_alpha`:
|
87 |
```python
|
88 |
-
output = model.generate(input_ids, do_sample=True, temperature=temperature, top_k=top_k, max_length=max_length, num_return_sequences=num_return_sequences, repetition_penalty=repitition_penalty,
|
89 |
```
|
90 |
|
91 |
![constrastive search](./contrastive_comma_style.png)
|
|
|
83 |
![constrastive search](./constrastive_search.png)
|
84 |
|
85 |
|
86 |
+
To bring back the commas, assign output without `penalty_alpha` and `no_repeat_ngram_size`:
|
87 |
```python
|
88 |
+
output = model.generate(input_ids, do_sample=True, temperature=temperature, top_k=top_k, max_length=max_length, num_return_sequences=num_return_sequences, repetition_penalty=repitition_penalty, early_stopping=True)
|
89 |
```
|
90 |
|
91 |
![constrastive search](./contrastive_comma_style.png)
|