Downloads · 30 days
8
13% of all-time downloads
yasuiniko/nanochat-d8-base-39000
nanochat-d8-base-39000 is a text generation model from yasuiniko. Use it when you need the model to write or continue text. The card lists the license as mit.
Thanks to Andrej Karpathy and Harley Cooper for doing all the work.
Downloads · 30 days
8
13% of all-time downloads
All-time downloads
62
Public
Repo size
370 MB
Likes
0
Public
Click a slice to open those files.
.bin369 MB · 100%
From the Hugging Face model README
Thanks to Andrej Karpathy and Harley Cooper for doing all the work.
This repository contains a nanochat checkpoint exported for Hugging Face. The architecture mirrors GPT-style decoders with rotary embeddings, RMSNorm, multi-query attention, relu² MLPs, and untied embeddings.
from transformers import AutoModelForCausalLM, AutoTokenizer
model = AutoModelForCausalLM.from_pretrained("yasuiniko/nanochat-d8-base-39000", trust_remote_code=True)
tokenizer = AutoTokenizer.from_pretrained("yasuiniko/nanochat-d8-base-39000", trust_remote_code=True)
inputs = tokenizer("Hello nanochat!", return_tensors="pt")
output_ids = model.generate(**inputs, max_length=128)
print(tokenizer.decode(output_ids[0], skip_special_tokens=True))
Remember to pass trust_remote_code=True so Transformers picks up the custom
model and tokenizer implementations bundled in this repository.