See tokenization
Observe how training text becomes token IDs, sequences and model input.
BabyGPT is an educational training engine that makes tokenization, transformer structure, optimization and text generation visible in one browser-native experiment.
the small model learns patterns one token at a time
Modern language models are too large to inspect directly. BabyGPT reduces the architecture to a scale where the complete learning process can be understood, changed and observed.
Observe how training text becomes token IDs, sequences and model input.
Understand embeddings, attention, feed-forward layers and output projection.
Follow loss, epochs and generated samples as the model learns statistical patterns.
The experiment follows the same conceptual stages as a larger autoregressive transformer, but at a scale suitable for learning and browser execution.
Provide a small training corpus directly in the browser.
Convert the text into a compact vocabulary and numerical sequence.
Produce next-token predictions through the transformer stack.
Calculate loss, update weights and repeat across training batches.
Sample new text one token at a time from the trained model.
BabyGPT is designed for experimentation. Change one architectural or training variable and observe how the learning behaviour changes.
Explore how much prior text the model can use for each prediction.
Compare model capacity, training speed and generated output.
Observe undertraining, instability, memorisation and gradual convergence.
Change how conservative or diverse the generated continuation becomes.
Learn how discrete token IDs become trainable vector representations.
See how each position reads only the tokens that came before it.
Follow attention, residual paths, normalization and feed-forward processing.
Understand how the model learns by predicting the following token.
Observe whether training is converging, unstable or simply memorising.
Watch the trained model build a sequence one prediction at a time.
BabyGPT is useful when the goal is to understand and experiment with transformer mechanics rather than deploy a capable general-purpose language model.
Learn transformer fundamentals through direct interaction.
Demonstrate training and generation without large infrastructure.
Experiment with architecture and training choices at a manageable scale.
Prototype small educational or browser-native learning experiments.
BabyGPT reduces transformer learning to an inspectable browser experiment where architecture, training and generation remain visible.
Explore Veritiana projects