Modern Software Tools, Explained Back to Home
Ideas that drive modern software tools, explained in code for working programmers

Modern Software Tools, Explained

These explainers are about the concepts behind the tools programmers use every day: how they work, why they are designed the way they are, and what tradeoffs they make. Each page combines diagrams, small simulations, and runnable JavaScript so the explanation and the mechanism stay close together.

AI Systems

How GPT Works

Tokenization, embeddings, attention, transformer blocks, sampling, and training, ending with a tiny GPT-2-style decoder in JavaScript.

Language models Attention Runnable code
Storage Systems

Filesystems and B-Trees

A practical guide to why B-trees matter for disk-backed systems, including search, splitting, deletion, and a miniature filesystem built on top of a B-tree.

Data structures Filesystems Disk I/O
Editor Internals

Ropes and Piece Tables

The text-buffer structures behind modern editors, covering gap buffers, ropes, piece tables, undo history, and line-oriented access.

Text editors Data structures Runnable code
Compression

The Compression Game

Shannon entropy, Huffman coding, LZ77 back-references, and the way gzip combines both into a practical lossless compressor.

Information theory Lossless compression Runnable code
Data Structures

The Balanced Bookshelf

AVL trees, red-black trees, ordered maps, and the situations where a balanced tree is a better fit than a hash table.

Ordered maps Self-balancing trees Runnable code
Data Structures

The Casino Data Structure

Skip lists, probabilistic balancing, Redis sorted sets, rank queries, and a full skip-list implementation in JavaScript.

Skip lists Redis Runnable code
Storage Engines

The Write-Heavy Problem

LSM trees, sequential write paths, MemTables, SSTables, compaction, Bloom filters, and the tradeoffs behind LevelDB, RocksDB, and Cassandra.

LSM trees Compaction Runnable code
Approximate Data

Good Enough Answers

Bloom filters, count-min sketch, HyperLogLog, and the engineering case for approximate answers when exactness is too expensive.

Probabilistic data structures Streaming Runnable code
Algorithms

The Practical Champion

Quicksort, partitioning, pivot choice, introsort, heapsort fallback, and the cases where the fastest in-memory sorter is not the right tool.

Sorting Introsort Runnable code
Algorithms

Sorting Bigger Than RAM

External mergesort, run generation, k-way merging, sequential I/O, and a simulated BinaryFile-based external sort in JavaScript.

External sorting Disk I/O Runnable code