Building a Pure-Python Top-p/Top-k Sampler with Temperature Scaling for LLM Logits
This post walks through building a pure-Python top-p/top-k sampler with temperature scaling, providing runnable code and a roadmap for productionizing it.
This post walks through building a pure-Python top-p/top-k sampler with temperature scaling, providing runnable code and a roadmap for productionizing it.
A practical guide to building a lazy weight loader for large LLMs using safetensors, async prefetch, and checksum verification.
A hands‑on guide to building a production‑ready context manager that automatically trims prompt histories using attention‑weighted saliency, keeping your LLM prompts within any context window.
This post walks through building a lightweight post-training quantizer that maps FP32 LLM weights to INT4 using calibration and dithering, with full Python code and testing steps.
A hands‑on guide to constructing a pure‑Python KV cache eviction engine that uses attention‑based pruning to reduce memory footprint for long‑context LLM inference.