EricFillion commited on
Commit
e7b5814
1 Parent(s): f5df97a

Completed initial readme

Browse files
Files changed (1) hide show
  1. README.md +3 -2
README.md CHANGED
@@ -20,13 +20,14 @@ using a dataset called [JFLEG](https://arxiv.org/abs/1702.04066).
20
  `pip install happytransformer `
21
 
22
  ```python
23
- from happytransformer import HappyTextToText
24
 
25
  happy_tt = HappyTextToText("T5", "vennify/t5-base-grammar-correction")
26
 
27
  args = TTSettings(num_beams=5, min_length=1)
28
 
29
- result = happy_tt.generate_text("This sentences has has bads grammar.", args=args)
 
30
 
31
  print(result.text) # This sentence has bad grammar.
32
 
20
  `pip install happytransformer `
21
 
22
  ```python
23
+ from happytransformer import HappyTextToText, TTSettings
24
 
25
  happy_tt = HappyTextToText("T5", "vennify/t5-base-grammar-correction")
26
 
27
  args = TTSettings(num_beams=5, min_length=1)
28
 
29
+ # Add the prefix "grammar: " before each input
30
+ result = happy_tt.generate_text("grammar: This sentences has has bads grammar.", args=args)
31
 
32
  print(result.text) # This sentence has bad grammar.
33