Kaitlyn Bassford / interactive sketches
Try a sketch.
Choose a sketch to inspect search, constraints, attention, model selection.
sketches
Current AI/ML work
Inspect the implementations, experiments and limitations. These small mechanisms are illustrations, not substitutes for the live projects.
nibble
A from-scratch LLM inference engine in C++20 that runs Qwen2.5, Llama 3.2 and TinyLlama GGUF models on the CPU in F16 and seven quantized formats, with no dependencies beyond the standard library. Checked against llama.cpp: F16 logits reach 0.99996 cosine similarity and quantized dot products match bit for bit. Q4_0 decode is within 1.19× of llama.cpp at 8 threads.
Multimodel Face Analyzer
A configurable computer-vision pipeline with 15 features, four swappable face detectors, and independently optional model backends. Held-out evaluation rejected race fusion: 63.3% versus the best model's 76.5% on 1,002 FairFace test faces. Missing backends degrade gracefully; detection needs any one of the four detectors.
Search Agents
Twenty-six puzzles and games, plus nine algorithm labs, connecting search, exact methods, and learned guidance. A TD-learned n-tuple network reaches 2048 in 88.1% of 3,000 held-out games without search; a neural 15-puzzle heuristic expands about 120× fewer nodes on 40 puzzles, with paths 3.3% longer on average.
Intraday Trading Engine
A C++20 engine replays 5.1M real NVDA quotes in 1.3 s against 111.5 s in Python, held bit-identical by parity tests. ML models and a 16-configuration PPO search on Kaggle GPUs are judged against holding the same stocks; the best agent made +51.9% while holding made +97.2%. Two Alpaca paper bots run daily; real money stays locked behind statistical qualification and 30 paper sessions.
Transformer: Positional Encodings & Length Generalization
An encoder-decoder from PyTorch primitives, extended into controlled experiments on four positional encodings. Models train on copy and reverse up to length 16 and test through 48 across three seeds. Every encoding reaches 0% exact match by length 24; inspect the results, attention maps, and KV-cache benchmarks in the study.
Diffusion from Scratch
DDPM and DDIM sampling from PyTorch primitives, with a conditioned U-Net and an interactive denoising demo. On 1,000 MNIST samples, 50-step DDIM matches 1,000-step DDPM's 99.9% classifier accuracy while sampling 18–21× faster. Evaluation uses dataset-specific CNN features, not a directly comparable published FID benchmark.