Dan Luu

@danluu
13.1K Followers
19 Following
1.5K Posts

Learning a bit about building game AIs:

https://www.patreon.com/posts/152027219

Looks like I spoke too soon about the AI not being superhuman. The current Azul world champion played against it and thinks it's better than him at higher difficulties, and a top 100 player played against it at default difficulty and thought it was better than him at default.

I should write a longer post about this. As someone who has a default of trying to have a better understanding of their project than most people would, going full vibe and understanding almost nothing was interesting.

I don't want to overstate the case — I saw someone vibe coded the same project and then declared programming was dead after they finished, but their bot loses to plain MCTS with a simple heuristic.

Mine was in the same state when I just had an LLM running in a loop with instructions to improve the result. At least for now, you have to apply some direction, but it turns out someone with no AI background can supply enough direction.

It's sort of amazing how quickly you can do things now. I wanted to try writing an alphazero-style AI for Azul. With no AI background, it took me maybe 2-3 hours to (2-3 days wall clock) to beat the best AI I could find to play against:

https://danluu.com/game/tile/

I don't think the AI is superhuman, but I've just been training it on a CPU on my laptop and it's not bad and measurably better every few hours, so maybe it will get there if I just let it run for longer (or if I get a real workstation)

Exercises in benchmarking and experimental design, part 5:

https://www.patreon.com/posts/149123122

Useless information about poker chips:

https://www.patreon.com/posts/146484203

How earthquake safe are Vancouver condos?

https://www.patreon.com/posts/143211904

Interesting story about Google publishing someone's phone number on searches for them when they gave the number to Google for account verification/security:

https://danq.me/2025/05/21/google-shared-my-phone-number/

Reminds me of the time a company I worked for (AFAIK) accidentally used phone numbers obtained the same way for ad targeting and got fined $150M

Exercises in benchmarking and experimental design, part 4:

https://www.patreon.com/posts/127627543

undefined behavior is pretty well understood at this point, but a piece of the puzzle that has always been missing is "how well could a compiler like LLVM optimize, without leaning on UB"

here's a very cool new paper that takes a crack at answering this, for LLVM:

https://web.ist.utl.pt/nuno.lopes/pubs/ub-pldi25.pdf