kitxor

// tech blogs, systems, code

~/posts

How Diffusion Models Actually Work

Iterative denoising loop. Latent space compression makes it GPU-friendly.

Token Bucket Rate Limiting

Prevent API abuse with token bucket. Atomic Lua scripts solve race conditions in distributed systems.

CDN Design Part 3: Cache Invalidation Strategies

TTL, purge, versioned URLs, soft purge. Pick consistency guarantees upfront.

CDN Design Part 2: Architecture & Caching Strategies

Multi-tier caching, Origin Shield, pull vs push. 85% origin load reduction.

AIAYN Part 2: Scaled Dot-Product Attention

Q, K, V matrices compute context. Scaling prevents saturation. Each token gets enriched.

CDN Design Part 1: Fundamentals & Why You Actually Need One

Physics limits latency. CDNs reduce distance. 93% faster for cached content.

AIAYN Part 1: Why Transformers Killed RNNs

Self-attention replaced sequential processing. RNNs became obsolete overnight.

Mafia: Definitive Edition

1930s mob story. Fast-paced, linear, 15 hours.

URL Shortener: Counter vs Hash

Two approaches: Base62 encoding (no collisions) vs MD5 hashing (deterministic).