Upload README.md
Browse files
README.md
ADDED
@@ -0,0 +1,23 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
library_name: transformers
|
3 |
+
tags:
|
4 |
+
- text-generation
|
5 |
+
- causal-lm
|
6 |
+
pipeline_tag: text-generation
|
7 |
+
---
|
8 |
+
|
9 |
+
# Your Model Name
|
10 |
+
|
11 |
+
This model is designed for text generation tasks.
|
12 |
+
|
13 |
+
## Example Usage
|
14 |
+
|
15 |
+
```python
|
16 |
+
from transformers import AutoTokenizer, AutoModelForCausalLM
|
17 |
+
|
18 |
+
tokenizer = AutoTokenizer.from_pretrained("your-username/your-model-repo")
|
19 |
+
model = AutoModelForCausalLM.from_pretrained("your-username/your-model-repo")
|
20 |
+
|
21 |
+
inputs = tokenizer("Hello, how are you?", return_tensors="pt")
|
22 |
+
outputs = model.generate(**inputs)
|
23 |
+
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
|