WikiGame

wiki path solver
Side project · 2026

Give it any two Wikipedia articles and watch it find a path between them, hopping link to link.

WikiGame screenshot
Demo · walking from one article to another, hop by hop

The Wikipedia Game is the old browser dare: start on one article, reach another using only the blue links inside each page, in as few clicks as you can. Playing it by hand is half intuition and half luck: you click toward whatever feels closer to the destination and hope the next page opens a better door. I wanted to watch that intuition run as a program, so I built a solver that makes the same call at every step and shows you the trail it leaves behind.

The honest part of the problem is "closer." A human reads a page and senses which link points roughly the right way; the solver has to turn that hunch into a number. So at each article it pulls the outbound links, reads a little of what each one is about, and measures how much that text overlaps with the destination article's text. The link that overlaps the most wins, and the walk moves on. No backtracking, no lookahead, just the best-looking step, taken over and over until it arrives or gives up.

How it works

Stack

Vite · React · TypeScript, talking directly to the MediaWiki API. The TF-IDF tokenizer and sparse cosine similarity are hand-rolled, ported from an earlier Python version of the same idea, and the whole thing ships as a static site on GitHub Pages.

Next a bidirectional walk that searches from both articles at once, for shorter paths on the hard pairs.

← all projects