Nyakati
A timeline of Kenya you can walk into
Scroll a river of years from 1895 to today, step into one, and it opens as a room of sourced events, credited images and a guide that answers only with citations: a plain-code check drops any sentence that doesn't cite a passage the model was given.
- Next.js 16
- Canvas · GSAP · Lenis
- Python pipeline
- Postgres · pgvector
- bge-m3
- llama3.2:1b
Design pass · before and after



Context
Nyakati is a timeline of Kenya from 1895 to today. You scroll a river of years, step into one, and it opens as a room of all that year's sourced events (lens tabs for politics, news, culture and places filter them), credited images and a guide that answers questions about that year only with citations. The idea is history as a place you move through, with every claim one click from its source.
The problem
A timeline is only as good as its events, and the hard part is not drawing it. Public sources for Kenya are uneven and noisy: Wikidata ties thousands of items to the country, most of them not events worth showing, and Wikipedia's year lists exist only for some years. On top of that, a guide that answers questions about history has to be stopped from inventing it, and it has to run on a small model on a CPU.
Approach
A Python pipeline (httpx, pydantic, psycopg), run by make and entirely in Docker, gathers candidates from Wikidata and Wikipedia. One decade was sorted by hand; the rules from those decisions pre-sort every other decade, which is then read through with the reason for each decision recorded. bge-m3 embeddings find likely duplicates, which are merged only after review. A model tags each event with its lens; its error rate was measured on a 100-event sample at 33% and published, and rules now correct its systematic mistakes. People and places come from Wikidata and show on each card, linked back to it; Wikidata's "chair" and "head of state" are skipped, because they give today's holder, not the one at the time. The result is 706 approved events. The guide retrieves passages for the year in view from pgvector with bge-m3 and asks a 1B model (llama3.2:1b), running on my own server, to answer with each sentence citing a passage. The site is Next.js 16 with canvas, GSAP and Lenis: the river is a band of water with an era-tinted current, year numerals in Fraunces float in it, and entering a year grows its numeral into the room's header in 700 ms, landing back on the same numeral when you leave.
Securing it
For a history site the risk is a confident wrong claim, so every safeguard is about provenance. A plain-code check drops any guide sentence that does not cite a passage the model was actually given; the evals found four ways to fool that check, and each became a test. Sources stream first, so a slow CPU model still leaves something to read. No image shows without its author and licence on screen, every card links to its source, all 381 source links were checked, and every card has "Report an error". Every event records who approved it, and the site publishes the split: none by a person yet, 502 approved by AI and 204 on trust from Wikidata. The palette was contrast-checked too: murram and acacia failed as text, so lighter ink variants were added for text.
What shipped
Live at nyakati.ihope.dev, with 706 approved events from 1895 to today. A 50-question eval publishes its score on the site's /sources page: 27 of 40 answerable questions answered correctly, 8 of 10 unanswerable questions declined, and 64 of 70 answer sentences backed by their cited passage. The same page lists the datasets, their licences, who checked what, and the tagging error rate.
Links