← Experiments

Celebrity Golf(experiment)

Connect two film people by naming movies — scored like golf.

Each hole names two film people, a tee and a pin. You connect them by naming films: a film links two people who both worked on it, and each film you name is a stroke. On the first hole, Steve Buscemi to Julianne Moore, The Big Lebowski is an ace.

Par is a shortest path

Films and people form one graph, with an edge wherever a person worked on a film. A route from tee to pin alternates people and films, so the cheapest route is a breadth-first search, and par is its length counted in films.

teef1pin(a)
teef1f2pin(b)
Figure 1 A route alternates people (circles) and films (boxes). (a) An ace: one film with both tee and pin in it, one stroke. (b) Two films joined by a person in both, two strokes. A route of n slots between tee and pin costs (n + 1) / 2 strokes; a hole's par is its cheapest route.

Some holes add routes with a rule, such as going through a composer or a cinematographer. The search state records whether the route has met the rule yet, and each route type gets its own par; the hole’s par is the lowest.

The graph comes from four IMDb data files: 45,904 films and 598,198 edges. It keeps movies (no shorts or documentaries) with at least 1,000 votes released in 1930 or later, the top 10 billed cast of each, and only three crew roles: director, composer and cinematographer. The shipped course uses a smaller board of 6,081 films and 79,639 edges, limited to films a US player is likely to know: English-language films with at least 25,000 votes, or any film with at least 250,000. → Par Is a Graph Property

Scoring without the graph

The browser never searches the graph. For each hole the generator stores every shortest chain of each route type, up to 10, in the hole’s file. Play only compares a guess against those chains.

Af1f2Bf1f3Cf4f5(a)
Af1f2Bf1f3Cf4f5(b)
Af1f2Bf1f3Cf4f5(c)
Figure 2 Scoring a hole against its stored shortest chains A, B and C. A guess that is the next film of some chain keeps only those chains; the hole is done when one chain is fully played. Every guess is a stroke, including films that make no progress.

A film from the current person’s filmography that is on no shortest chain still costs a stroke, as a shot into the trees; a title already played or not in the film list is a whiff. Lists of film titles for typeahead load separately and lazily; scoring never reads them. → Offline validation