Downloads · 30 days
267
47% of all-time downloads
amusktweewt/tiny-stories-v1
tiny-stories-v1 is a text generation model from amusktweewt. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as mit.
This model is a custom transformer-based language model trained on the TinyStories dataset, designed for creative text generation tasks such as storytelling and conversational agents. This model is purely an academic…
Downloads · 30 days
267
47% of all-time downloads
All-time downloads
565
Public
Parameters
57.4M
230 MB on disk
Likes
1
Public
Click a slice to open those files.
.safetensors230 MB · 100%
From the Hugging Face model README
This model is a custom transformer-based language model trained on the TinyStories dataset, designed for creative text generation tasks such as storytelling and conversational agents. This model is purely an academic project and should not be used in production or practical applications.
This model utilizes a custom tokenizer with Byte Pair Encoding (BPE) and has been trained with a smaller architecture to balance efficiency and performance. It is designed for generating coherent and contextually relevant short stories. However, a known issue with the tokenizer causes spaces between tokens to appear repeated, leading to suboptimal text output quality.
This model is intended for academic and research purposes only. It demonstrates a proof of concept for training smaller transformer-based language models.
The model may reflect biases present in the training data, leading to unintended or inappropriate outputs. Additionally, the tokenizer issue can result in suboptimal and incoherent text generations.
This model is meant for research and demonstration purposes. Users should validate outputs critically and avoid using it for practical applications.
from transformers import AutoModelForCausalLM, PreTrainedTokenizerFast
model = AutoModelForCausalLM.from_pretrained("amusktweewt/tiny-stories-v1")
tokenizer = PreTrainedTokenizerFast.from_pretrained("amusktweewt/tiny-stories-v1")
prompt = "Once upon a time,"
inputs = tokenizer(prompt, return_tensors="pt", return_token_type_ids=False)
outputs = model.generate(**inputs, max_new_tokens=50)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
The model was trained on the TinyStories dataset, consisting of curated short stories. Preprocessing ensured consistent formatting and tokenization using a custom BPE tokenizer.
<sos>, <pad>, <|endoftext|>, and <unk>A subset of the training data was used for evaluation, focusing on coherence and storytelling quality.
The model generates coherent short stories suitable for research demonstration but is limited by tokenizer issues and should not be used in real-world scenarios.
amusktweewt
For questions or feedback, contact amusktweewt.