Matching Networks: Attention-Weighted Few-Shot Classification

Few-shot classifiers like Matching Networks never fine-tune on a new class — instead they attend over a small labelled support set and vote. This simulation lays that attention mechanism out as flat 2D geometry: support points from N classes sit in an embedding plane, a draggable query point casts a distance-weighted attention line to every one of them, and the predicted class is whichever label collects the most attention mass. A sharpness slider morphs the vote continuously between a soft, blurry consensus and a hard nearest-neighbour lookup, while live readouts track prediction confidence and attention entropy as you move the query across the plane. Pan and zoom the plane freely to inspect any cluster up close.