Skip to content

Vrel 0.1.0

Choose a tag to compare

@luciertanner luciertanner released this 01 Dec 00:14
· 3 commits to main since this release

Download the trained model: vrel-0.1.0.zip below is Vrel 0.1 (13.9M parameters, 67 public-domain novels), 8-bit, ready to run. Unzip it into Lyss's models folder and type lyss. Also on Hugging Face.

First release.

  • Vrel, a small transformer language model built from scratch: our own tokenizer, layers, attention, optimizer, training loop and sampler. No pretrained weights, no borrowed model code.
  • Results on held-out text: validation loss 3.637 (perplexity 38.0), against 4.916 (136.5) for the bigram baseline and 9.080 (8,776) for random weights. 13.9M parameters, trained in 40 minutes on an RTX 4060 at 20,422 tokens/s. Only 0.3% of its 8-word phrases appear word for word in the training books.
  • python -m vrel prepare downloads and cleans 67 public-domain novels from Project Gutenberg, falling back to official Project Gutenberg mirrors when gutenberg.org is down, and resuming downloads that get cut off.
  • python -m vrel tokenizer trains an 8,192-token byte-level BPE tokenizer and encodes the books.
  • python -m vrel bigram scores a simple counting baseline for comparison.
  • python -m vrel train trains the model on your GPU (or CPU), with checkpoints and resume.
  • python -m vrel generate writes text from a prompt, streamed as it is produced.
  • python -m vrel watch opens a live, beginner-friendly dashboard at http://127.0.0.1:8777: how Vrel learns in plain words, how unsure it is round by round, progress, and what it wrote at the start next to what it writes now.
  • python -m vrel stats and python -m vrel export inspect a checkpoint and package it in a self-contained folder that other apps can load.