gifs: index the collection, paginate it, search it server-side
The catalog was fetched whole, held whole on the server, shipped whole to every client, and searched by filtering that array. Measured: 509 bytes a record — 78KB at today's 154, but 4.9MB per client at 10k and 48MB at 100k. That only ever worked because the corpus was tiny, and assuming it stays tiny is not an assumption worth carrying. Gifs are now an indexed collection like any other. hatk ingests net.gifdex.gif.post off the firehose, the picker pages through dev.hatk.getRecords, and search runs against hatk's full-text index via dev.hatk.searchRecords. Nothing holds more than the page on screen, and /api/gifs — the fan-out to every PDS — is deleted. The lexicon is vendored and inferred: gifdex publishes none, so it is reconstructed from records in the wild and kept permissive, since a schema stricter than reality makes the indexer drop records silently. Verified against 113 real records from four PDSes — zero rejected. Existing gifs would otherwise be invisible, because the indexer only learns a repo from a live commit. server/setup/gif-sources.ts asks lightrail which repos publish each registered source and seeds them as pending for backfill. It loops the registry, so a new source needs no change there. gifdex is now one source rather than the tab: gifsources.ts owns all source-specific knowledge, including that the tid:blobCid rkey shortcut is a gifdex convention. A source without it falls back instead of rendering a broken image. Nothing outside the registry names a collection. Also fixes gif statuses having no link preview at all — the og:image path only handled custom: bufos. They now preview as the gif itself, which can animate: bluesky's card proxy passes gifs through byte-for-byte, verified up to 10MB. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>