prithivida
commited on
Commit
·
845ef10
1
Parent(s):
d314313
Update README.md
Browse files
README.md
CHANGED
@@ -10,14 +10,16 @@ pip install git+https://github.com/PrithivirajDamodaran/Parrot.git
|
|
10 |
```
|
11 |
|
12 |
### Quickstart
|
|
|
13 |
```python
|
14 |
|
|
|
15 |
from parrot import Parrot
|
16 |
import torch
|
17 |
import warnings
|
18 |
warnings.filterwarnings("ignore")
|
19 |
|
20 |
-
'''
|
21 |
uncomment to get reproducable paraphrase generations
|
22 |
def random_state(seed):
|
23 |
torch.manual_seed(seed)
|
@@ -30,7 +32,7 @@ random_state(1234)
|
|
30 |
#Init models (make sure you init ONLY once if you integrate this to your code)
|
31 |
parrot = Parrot(model_tag="prithivida/parrot_paraphraser_on_T5", use_gpu=False)
|
32 |
|
33 |
-
phrases = ["Can you recommed some upscale restaurants in
|
34 |
"What are the famous places we should not miss in Russia?"
|
35 |
]
|
36 |
|
@@ -44,29 +46,28 @@ for phrase in phrases:
|
|
44 |
```
|
45 |
|
46 |
```
|
47 |
-
|
48 |
-
Input_phrase: Can you recommed some upscale restaurants in
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
Input_phrase: What are the famous places we should not miss in Russia
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
"what are some of the most famous places of russia?"
|
67 |
-
"what are some places we should not miss in russia?"
|
68 |
```
|
69 |
|
|
|
70 |
### How to get syntactic and phrasal diversity/variety in your paraphrases using parrot?
|
71 |
|
72 |
You can play with the do_diverse knob (check out the next section for more knobs).
|
|
|
10 |
```
|
11 |
|
12 |
### Quickstart
|
13 |
+
|
14 |
```python
|
15 |
|
16 |
+
|
17 |
from parrot import Parrot
|
18 |
import torch
|
19 |
import warnings
|
20 |
warnings.filterwarnings("ignore")
|
21 |
|
22 |
+
'''
|
23 |
uncomment to get reproducable paraphrase generations
|
24 |
def random_state(seed):
|
25 |
torch.manual_seed(seed)
|
|
|
32 |
#Init models (make sure you init ONLY once if you integrate this to your code)
|
33 |
parrot = Parrot(model_tag="prithivida/parrot_paraphraser_on_T5", use_gpu=False)
|
34 |
|
35 |
+
phrases = ["Can you recommed some upscale restaurants in Newyork?",
|
36 |
"What are the famous places we should not miss in Russia?"
|
37 |
]
|
38 |
|
|
|
46 |
```
|
47 |
|
48 |
```
|
49 |
+
----------------------------------------------------------------------
|
50 |
+
Input_phrase: Can you recommed some upscale restaurants in Newyork?
|
51 |
+
----------------------------------------------------------------------
|
52 |
+
list some excellent restaurants to visit in new york city?
|
53 |
+
what upscale restaurants do you recommend in new york?
|
54 |
+
i want to try some upscale restaurants in new york?
|
55 |
+
recommend some upscale restaurants in newyork?
|
56 |
+
can you recommend some high end restaurants in newyork?
|
57 |
+
can you recommend some upscale restaurants in new york?
|
58 |
+
can you recommend some upscale restaurants in newyork?
|
59 |
+
----------------------------------------------------------------------
|
60 |
Input_phrase: What are the famous places we should not miss in Russia
|
61 |
+
----------------------------------------------------------------------
|
62 |
+
what should we not miss when visiting russia?
|
63 |
+
recommend some of the best places to visit in russia?
|
64 |
+
list some of the best places to visit in russia?
|
65 |
+
can you list the top places to visit in russia?
|
66 |
+
show the places that we should not miss in russia?
|
67 |
+
list some famous places which we should not miss in russia?
|
|
|
|
|
68 |
```
|
69 |
|
70 |
+
|
71 |
### How to get syntactic and phrasal diversity/variety in your paraphrases using parrot?
|
72 |
|
73 |
You can play with the do_diverse knob (check out the next section for more knobs).
|