Downloads · 30 days
4.7K
3% of all-time downloads
roneneldan/TinyStories-3M
TinyStories-3M is a text generation model from roneneldan. Use it when you need the model to write or continue text. It is set up for transformers.
Model trained on the TinyStories Dataset, see https://arxiv.org/abs/2305.07759
Downloads · 30 days
4.7K
3% of all-time downloads
All-time downloads
136K
Public
Repo size
133 MB
Likes
4
Public
Click a slice to open those files.
.bin66.7 MB · 95%
From the Hugging Face model README
Model trained on the TinyStories Dataset, see https://arxiv.org/abs/2305.07759
------ EXAMPLE USAGE ---
from transformers import AutoModelForCausalLM, AutoTokenizer, GenerationConfig
model = AutoModelForCausalLM.from_pretrained('roneneldan/TinyStories-3M')
tokenizer = AutoTokenizer.from_pretrained("EleutherAI/gpt-neo-125M")
prompt = "Once upon a time there was"
input_ids = tokenizer.encode(prompt, return_tensors="pt")
output = model.generate(input_ids, max_length = 1000, num_beams=1)
output_text = tokenizer.decode(output[0], skip_special_tokens=True)
print(output_text)