Visualizers

Learn by moving things

Interactive explainers for the ideas behind retrieval, embeddings, and agents. A formula tells you what is true; dragging a vector shows you why. Each one also appears inside the article it belongs to, and runs entirely in your browser, so drag, poke, and break it.

Portrait of Sachin Gupta rendered in binary

Layer 4 vs layer 7: the mailroom sorter

From: Load Balancers, Up Close

Layer 4 reads only the address on the envelope and forwards fast to any server. Layer 7 opens the letter, reads the path, and routes by content: /images to image servers, /checkout to payment servers.

Read the envelope, or the letter?auto
requestsealedlayer 4reads the addressany serverfast, contents unread

Layer 4 reads only the address, never the contents, and forwards fast to any server. Simple and quick.

The gateway: the front desk

From: The Gateway: One Front Door

Every request passes one front desk: who are you (auth), coming too often (rate limit), and which service (routing). One busy bot gets turned away.

The gateway: the front deskauto
alicearrives at the front desk
who are you?
✓ pass
too often?
✓ pass
route to
orders service

One front desk checks who you are, turns you away if you are coming too often, and routes you to the right service. Every service behind it stays simpler.

Same idea, opposite direction. A reverse proxy sits in front of your servers (a receptionist); a forward proxy sits in front of your clients and faces out (a concierge). A gateway and an L7 load balancer are both reverse proxies.

Forward vs reverse: which side is it on?auto
clientclientclientreverse proxythe front desk (for servers)serverserverserver

A reverse proxy is the hotel front desk: outsiders go through it to reach the servers, which stay hidden. A gateway and a layer 7 load balancer are both reverse proxies.

Visualizers — Sachin Gupta