GPT-2 in your browser
A real language model running on your device. Type a prompt, press Generate and see the top five candidates behind every token it picks.
Your own GPT-2
Runs entirely in your browser · Xenova/gpt2 (quantized)
This downloads GPT-2 small (about 128 MB, quantized to 8 bits) from Hugging Face's servers, once, and runs it on your device with WebAssembly. Your prompts never leave the browser. On a phone or a slow connection, this may take a while.
Want to know why it says what it says? Module 01 builds up to this, from tokens and embeddings to attention and sampling, and ends with Hallucination and the Limits of Next-Token Prediction, where you use this model to catch a hallucination.