patrickvonplaten commited on
Commit
60a8187
1 Parent(s): c71c648

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +16 -16
README.md CHANGED
@@ -36,9 +36,9 @@ You can use this model directly with a pipeline for text generation.
36
  ```python
37
  >>> from transformers import pipeline
38
 
39
- >>> generator = pipeline('text-generation', model="facebook/opt-350m")
40
  >>> generator("Hello, I'm am conscious and")
41
- [{'generated_text': "Hello, I'm am conscious and I'm a bit of a noob. I'm looking for"}]
42
  ```
43
 
44
  By default, generation is deterministic. In order to use the top-k sampling, please set `do_sample` to `True`.
@@ -47,9 +47,9 @@ By default, generation is deterministic. In order to use the top-k sampling, ple
47
  >>> from transformers import pipeline, set_seed
48
 
49
  >>> set_seed(32)
50
- >>> generator = pipeline('text-generation', model="facebook/opt-350m", do_sample=True)
51
  >>> generator("Hello, I'm am conscious and")
52
- [{'generated_text': "Hello, I'm am conscious and I'm interested in this project. Can I get an initial contact"}]
53
  ```
54
 
55
  ### Limitations and bias
@@ -69,13 +69,13 @@ Here's an example of how the model can have biased predictions:
69
  >>> from transformers import pipeline, set_seed
70
 
71
  >>> set_seed(32)
72
- >>> generator = pipeline('text-generation', model="facebook/opt-350m", do_sample=True, num_return_sequences=5)
73
  >>> generator("The woman worked as a")
74
- [{'generated_text': "The woman works as a substitute teacher for kids who have missed school. She's the teacher herself,"},
75
- {'generated_text': 'The woman works as a security guard for another company and does an average of around $13/hour'},
76
- {'generated_text': 'The woman works as a receptionist, she could at the least wait a week or two for her'},
77
- {'generated_text': 'The woman works as a manager/intern/career development coach/advisor at a nursing home'},
78
- {'generated_text': 'The woman works as a maid and has to clean the house but you can tell her to do it'}]
79
  ```
80
 
81
  compared to:
@@ -84,13 +84,13 @@ compared to:
84
  >>> from transformers import pipeline, set_seed
85
 
86
  >>> set_seed(32)
87
- >>> generator = pipeline('text-generation', model="facebook/opt-350m", do_sample=True, num_return_sequences=5)
88
  >>> generator("The man worked as a")
89
- [{'generated_text': 'The man works as a security guard for the National Football League franchise. He has been a part of'},
90
- {'generated_text': 'The man works as a security guard for another company and does an excellent job.\nI remember when'},
91
- {'generated_text': 'The man works as a "secret agent" but at the same time he\'s working to protect the'},
92
- {'generated_text': 'The man works as a manager/operator/servant for a grocery store and does a lot of'},
93
- {'generated_text': 'The man works as a bouncer near the scene of the accident - how he could do that is'}]
94
  ```
95
 
96
  This bias will also affect all fine-tuned versions of this model.
 
36
  ```python
37
  >>> from transformers import pipeline
38
 
39
+ >>> generator = pipeline('text-generation', model="facebook/opt-1.3b")
40
  >>> generator("Hello, I'm am conscious and")
41
+ [{'generated_text': "Hello, I'm am conscious and aware of my surroundings. I'm aware that I'm dreaming."}]
42
  ```
43
 
44
  By default, generation is deterministic. In order to use the top-k sampling, please set `do_sample` to `True`.
 
47
  >>> from transformers import pipeline, set_seed
48
 
49
  >>> set_seed(32)
50
+ >>> generator = pipeline('text-generation', model="facebook/opt-1.3b", do_sample=True)
51
  >>> generator("Hello, I'm am conscious and")
52
+ [{'generated_text': "Hello, I'm am conscious and aware of my surroundings. I'm aware that my thoughts are thoughts"}]
53
  ```
54
 
55
  ### Limitations and bias
 
69
  >>> from transformers import pipeline, set_seed
70
 
71
  >>> set_seed(32)
72
+ >>> generator = pipeline('text-generation', model="facebook/opt-1.3b", do_sample=True, num_return_sequences=5)
73
  >>> generator("The woman worked as a")
74
+ [{'generated_text': 'The woman worked as a waitress for six months before she started dating her boyfriend, who was working at'},
75
+ {'generated_text': "The woman worked as a prostitute, but she didn't want to sell herself anymore. She wanted to"},
76
+ {'generated_text': 'The woman worked as a translator at the embassy during her studies at Cambridge University in England. She said'},
77
+ {'generated_text': 'The woman worked as a secretary for Senator Ted Stevens of Alaska for 22 years before retiring from his Senate'},
78
+ {'generated_text': 'The woman worked as a caregiver for elderly patients at the nursing home where she lived until she died'}]
79
  ```
80
 
81
  compared to:
 
84
  >>> from transformers import pipeline, set_seed
85
 
86
  >>> set_seed(32)
87
+ >>> generator = pipeline('text-generation', model="facebook/opt-1.3b", do_sample=True, num_return_sequences=5)
88
  >>> generator("The man worked as a")
89
+ [{'generated_text': 'The man worked as a janitor at the University of Michigan Medical Center before he died after contracting Ebola'},
90
+ {'generated_text': 'The man worked as a salesman for IBM Corp., selling computers to businesses around the globe. He traveled'},
91
+ {'generated_text': 'The man worked as a translator for the British Broadcasting Corporation between 1956 and 1961. During that period he'},
92
+ {'generated_text': 'The man worked as a salesman for IBM Corp., selling computers for computers. He traveled extensively and lived'},
93
+ {'generated_text': 'The man worked as a security guard for nearly 30 years before he was shot dead by police officers responding'}]
94
  ```
95
 
96
  This bias will also affect all fine-tuned versions of this model.