LLM-Based Players

Discussions about BGA (all languages)
Forum rules
Warning: challenging a moderation in Forum = 10 days ban
More info & details about how to challenge a moderation: viewtopic.php?p=119756
User avatar
BananaHarambe
Posts: 297
Joined: 19 June 2024, 17:40

Re: LLM-Based Players

Post by BananaHarambe »

Why use a LLM to do a custom logic task like playing a board game when it could be manually coded instead? What an extreme waste of resources for an LLM, just make a lean bot that is focused on the single task or use machine learning.

LLMs are for LANGUAGE, not logic. If you want mastery in a specific task use machine learning (totally different from LLM) to have the computer play against itself (with the rules already coded into it) and have it iterate until it is good enough at the game. In Chess this is how Leela Chess bot and others do it.

Have an experienced player and coder teach it the rules of the game and then give it a playing algorithm that resembles how regular players evaluate resources in a game.
FrankJones
Posts: 2441
Joined: 30 June 2024, 00:24

Re: LLM-Based Players

Post by FrankJones »

Writing a pre-defined set of instructions to play a board game is not easy. For thematic strategy games with luck and hidden information, the number of failures probably outweighs the successes.

Some people might find it an interesting endeavor to create an AI computer player that is actually "AI", meaning, it actually "thinks", when playing a game such as terraforming Mars or Wingspan. Maybe then the computer player wouldn't be so abysmally terrible.

Manually writing out a set of instructions for a computer program to follow while playing Terraforming is likely very tedious, and likely why such computer players play so poorly.
User avatar
tbhp
Posts: 714
Joined: 16 April 2025, 00:35

Re: LLM-Based Players

Post by tbhp »

BananaHarambe wrote: 15 April 2026, 18:27 Why use a LLM to do a custom logic task like playing a board game when it could be manually coded instead? What an extreme waste of resources for an LLM, just make a lean bot that is focused on the single task or use machine learning.

LLMs are for LANGUAGE, not logic. If you want mastery in a specific task use machine learning (totally different from LLM) to have the computer play against itself (with the rules already coded into it) and have it iterate until it is good enough at the game. In Chess this is how Leela Chess bot and others do it.

Have an experienced player and coder teach it the rules of the game and then give it a playing algorithm that resembles how regular players evaluate resources in a game.
That's what I was thinking too. Why not make a program that reproduces the mental steps you go through when you play a game? The more exhaustive you make this process, the better the program will be at replicating your play.

Calculating every future possibility may be effective for a game like chess (I mean, that's kinda how humans tend to play chess in the first place), but for some other games it seems that a logical framework could give powerful results.
FrankJones
Posts: 2441
Joined: 30 June 2024, 00:24

Re: LLM-Based Players

Post by FrankJones »

BananaHarambe wrote: 15 April 2026, 18:27 Why use a LLM to do a custom logic task like playing a board game when it could be manually coded instead? What an extreme waste of resources for an LLM, just make a lean bot that is focused on the single task or use machine learning.

LLMs are for LANGUAGE, not logic. If you want mastery in a specific task use machine learning (totally different from LLM) to have the computer play against itself (with the rules already coded into it) and have it iterate until it is good enough at the game. In Chess this is how Leela Chess bot and others do it.

Have an experienced player and coder teach it the rules of the game and then give it a playing algorithm that resembles how regular players evaluate resources in a game.
The intersection between "talented coder" and "high-skill player" for any complex thematic strategy game might be a very small group of people. Then, one of them would need to be willing to undertake the project. Possibly for little or no money.

For many games, I think a high-skill player teaming up with a coder might be a good idea. Let's take Terraforming Mars.

Have a high level TFM player write a lengthy and detailed set of instructions that would, if followed, make the same choices and same plays he makes (This would be exceedingly difficult. It would take thousands of lines of code just to select the starting corporation, preludes and project cards relative to the goals and milestones of the specific map in question.)

Then, have a skilled programmer translate these instructions into code. This would not be difficult. Tedious, yes. Difficult, no. Thousands and thousands of lines of code? Yes. Hundreds of "if/else" blocks? Yes. "Difficult"? No. Time-consuming does not always mean difficult. And vice versa.

But writing the code would be extremely tedious and boring.

And that is why the "AI"s for Scythe, Wingspan, Terraforming Mars, are terrible.
Last edited by FrankJones on 16 April 2026, 17:34, edited 1 time in total.
Andrei3009
Posts: 271
Joined: 16 November 2023, 21:55

Re: LLM-Based Players

Post by Andrei3009 »

I think that making AI based on how a person thinks is extremely inefficient. We still can't connect a human brain and a computer, and some instructions from a real person won't help (at least with current technology). In addition, bots often beat people with new strategies previously inaccessible to humans, and these strategies will be lost if you write a bot based on human experience.
User avatar
BananaHarambe
Posts: 297
Joined: 19 June 2024, 17:40

Re: LLM-Based Players

Post by BananaHarambe »

The best way to make a strong board game bot is the machine learning method with a high number of self-play games and many iterations like many of the Chess engines have done or like Google's AlphaGo. I honestly doubt that a regular person would have enough computing resources to replicate this on a modern board game and have the performance resemble an average player considering the increased complexity and the non-deterministic nature of games with random cards and dice. The whole deck would need to be considered.

All you need to set up as a human coder is the rules of the game, just like how every single BGA game is coded except replace the UI with the bot's decision making system. The decision making is a basically using a bunch of knobs (nodes) to evaluate a given position and determine which choice gives the best expected outcome. Each card, resource, or game action gets assigned different values on each of the knobs and those values get adjusted throughout the game based on game progression and relative resources, card availability etc using situational awareness, which is learned over time.

The bot refines these knobs over time by playing against itself a bunch and evolving its evaluation system over time. To speed this up a human player would likely want to intervene and adjust some knobs early on to give it some basic logic like "early game economy good" and "late game scoring good, money bad" to avoid wasting time.
User avatar
OriProf
Posts: 10
Joined: 26 October 2023, 18:00

Re: LLM-Based Players

Post by OriProf »

Pocc, I'm curious how the AI code reads game state from BGA w/o access to underlying game code that drives each move. And could it actually make a valid move as a human would or does a human need to curate the desire of the AI by 'pressing the button' on the BGA site for the opponent?
User avatar
Pocc
Posts: 21
Joined: 12 May 2013, 04:49

Re: LLM-Based Players

Post by Pocc »

Once I get the green light from BGA, I'll take a look. It would certainly be easier if I had some special integration to game state, but the existing HTTP API endpoints should be sufficient. I would probably create a typescript MCP server for BGA endpoints, see "code mode".
User avatar
Pocc
Posts: 21
Joined: 12 May 2013, 04:49

Re: LLM-Based Players

Post by Pocc »

OriProf wrote: 18 April 2026, 00:18 Pocc, I'm curious how the AI code reads game state from BGA w/o access to underlying game code that drives each move. And could it actually make a valid move as a human would or does a human need to curate the desire of the AI by 'pressing the button' on the BGA site for the opponent?
The LLM would both determine what the move it needs to make is and also "press buttons" to execute it.
Post Reply

Return to “Discussions”