TinyWay-1.1.0 is a lightweight decoder-only Transformer language model trained from scratch on limited compute. The project demonstrates that meaningful language modeling behavior can emerge from modest-scale models trained in constrained environments such as.
Core idea: Understanding LLM training mechanics end-to-end by building, training, debugging, and deploying a Transformer LM without relying on pretrained weights.
Models were saved at multiple training steps (5k → 30k). TinyWay-1.1.0 corresponds to the ~25k step checkpoint, which showed the best balance of fluency and stability.
from transformers import AutoConfig, AutoTokenizer, AutoModelForCausalLM
model_id = "NNEngine/TinyWay-1.1.0"
config = AutoConfig.from_pretrained(model_id, trust_remote_code=True)
tok = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
mdl = AutoModelForCausalLM.from_pretrained(model_id, config=config, trust_remote_code=True)
out = mdl.generate(
**tok(
"Once upon a time",
return_tensors="pt"
).to(mdl.device),
max_new_tokens=200, # force length
do_sample=True, # sampling, not greedy
temperature=0.8,
top_k=50,
repetition_penalty=1.2,
eos_token_id=None, # 🔥 disable EOS stopping
pad_token_id=tok.eos_token_id
)
print(tok.decode(out[0], skip_special_tokens=True))
Once upon a time, there was a little girl named Lily. She loved to play with her toys and explore the park near her home. One day, she found a shiny red ball hidden behind a tree…
(Outputs vary due to sampling.)
This model is not intended for production use or sensitive applications.
If you use this model in academic or technical work, please cite:
@misc{sharma2025tinyway,
title={TinyWay: Training Decoder-Only Language Models from Scratch on Limited Compute},
author={Shivam Sharma},
year={2025},
}
Shivam Sharma B.Tech in Computer Science and Engineering (AIML) ITM Gwalior, India