I went to a board game night with a buddy in Sunnyvale and had a good time playing this stupid simple game called L.L.A.M.A.
While playing it I couldn't stop thinking about writing an engine / bot.
I had a python game engine built within an hour or two. It could play random legal moves. I later rewrote it in C++ for the speed. I thought I'd use the C++ engine to generate a bunch of training examples and use those examples later on to train a model in python.
But then I thought it'd be even more fun to expose the C++ engine in the browser by exporting a wasm binary with bindings that allow the game to be manipulated with javascript.
I then created a simple bot loosely modeled how I play L.L.A.M.A. In a 4-player game against 3 other bots that play randomly it wins 850/1000 games or so. This isn't too impressive though.
The next thing I want to try is creating a small model using tensorflowjs (or maybe just write it by hand). The model can be a simple neural net that takes in the visible state of that player and decides the best legal action. The cool thing about tensorflowjs is that it can train the model right there in the browser!
I also want to make it easy for someone to write their own bot with just a few lines of JS and see how close it comes to beating my best bot.
Really I want to be able to use this to make a simple bot live with my nieces and nephews and see how it performs. I want to see what ideas they come up with. I want to get their brains thinking about automation like this. I'll probably have to actually write a UI to keep them interested, however.
For now the page is located here. It doesn't do much; it plays 1000 games and reports back how many games each player won. Stay tuned for updates!