Where is the artificial intelligengence?

Not really. Most decisions in civilization are infrequent, have few options, and can be made mostly independently of the rest of the board,.
I think a game like Civilization is significantly more complex than chess (note that I'm not a chess player, so take that with a grain of salt). In Civilization, there have been more and more game concepts and mechanics that have been introduced over subsequent revisions that all interact with each other.

There are tactical gameplay decisions that need to be made across a diverse and changing environment and playing field as well as overall strategic ones that need to balance various parts of the game - whether it's military, religious, civilian, naval, scientific, cultural or economic pursuits.

There are also many more units than chess which are different to each other in ways other than merely how they move.

All of these decisions need to more or less be made (or at least considered in a changing environment) every turn.
 
It's not the number of mechanics and units, it's how tightly coupled things are. As an analogy, chess is like guessing an 8 character password where you only get a "yes/no" answer on the entire guess, but civilization would be like guessing a 20 character password, but you get "yes/no" result for each individual character.
 
It's not the number of mechanics and units, it's how tightly coupled things are. As an analogy, chess is like guessing an 8 character password where you only get a "yes/no" answer on the entire guess, but civilization would be like guessing a 20 character password, but you get "yes/no" result for each individual character.

It's far more complicated than just this. Let's compare:

In chess, the AI has a maximum of 16 pieces, all with a specific move pattern, to look at, where, in some cases, some are unable to move at all, reducing the number of decisions to take. Also, there's only 1 piece to move each turn with a single victory path.

In Civ6, all of their units has to move, in any direction, and cannot move the same way based on the order they move their units. There's also what building to do, what tile's improvement to do based on one or more victory path they are doing for.

If you want a correct analogy, it would be more like: "In Civ, would be guessing a 8 character password where you get a "yes/no" answer on the entire guess for each units."

For us, when we plan a strategy, it's easy because we can take these decision based on those. For example, if I want to do a sneak attack planned a while ago, I could have prepare an airlift strategy and move the units in consideration of this, without too much trouble. However, to be able to go in that direction, I would have asked myself: "Do I want a direct fight or do I want to take a few more turn through the woods and get the upper hand? Or do I want to try go behind their line and sneak them?" Once we have it, we go in that direction and we move the units starting with the closest to the decision picked.

For the AI, there's no such things, it's just a list of units on a grid and it will evaluate each turn a new tactic, analysing each turn what happened, what's their best move, what's their winning condition. So, maybe for performance issue, the concept of finding the unit closest to the decision hasn't been implemented, creating some strange moves and adjusting based on the moved units. Each time he makes a move, he'll have to evaluate the best condition for the unit, since the board is no longer the same after a single move he did. There's probably a timed decision for every unit to do the decision, limiting the exploration in the decision tree.

Let's say there's a 100ms limit per unit. If a AI has 100 units, that's 10 seconds of process time each turn, with 8 AI, that's 80 seconds. Something that seems unacceptable. So it needs to be cut to, let's say 50ms. That's now 5 seconds per AI and it's 40 seconds. However, decision trees are exponentials, each level of decision takes way more time than the previous level and the deeper they dig in a decision tree, the better the AI is. So the question can be ask, is the fact that some people complains about the AI taking it's time is really a good thing? To me, I don't care if it takes a while... but that's not the case of everyone.

So yeah, your analogy is simply wrong...
 
....*but*.....

It's certainly not impossible. Chess isn't as simple as you think. There are complete abstractions that took decades to correctly put into algorithms. If the computer is only calculating 30 half-moves ahead, and there is no clarity at the end of that, what is the consequence of the exchange sacrifice, giving up a rook to maintain a bishop pair?

That's just one simple question. There are millions. Grandmasters do not think in terms of "if rook takes pawn then horsey takes rook." They think of the game in terms of space, abstract space.

Incidentally, Go is even more like that, which is one of the reasons why it's taken so long to have competent AI in that game. The abstraction is fascinating (I'm a chess player, only a casual go player).

The abstractions in chess can lead to fatalistic endings. This is very different than Civ, where play can evolve out of a linear endgame, there is a RNG aspect, and other issues. My true complaint is why they started over from Civ 5 BNW, and we now have something slightly worse than vanilla Civ 5. Reinventing the wheel on this issue doesn't seem to make much sense.
 
The AI has definitely taken a turn for the worse, and is (currently) hopeless.

I can remember being whupped by the Zulus and Mongols in Civ I (effectively a 1UPT game) when I first played back in about 1994, and have been regularly steamrollered at the beginning in every edition up to and including 5 (at which point, experienced players will slap their foreheads and ask 'why?'... I know!). Most of these early defeats were on Prince equivalent, once those are mastered you move up the levels.
.
Even without knowing the mechanics, my first 6 game was a runaway victory. I gave up bored mid way in my second game as I was so far ahead on a higher level, without even trying. The agendas, proximity, attitude etc of the AI players broadly don't matter as they don't offer any realistic threat. There is the scope for a great game sitting there, but it is currently crud one (IMO).

Luckily, some mods by gamers done in their spare time have massively enhanced the playing experience and created a challenge, mainly by them thinking about the problems and rebalancing some AI numbers, for which I'm really grateful. The key question is why basic problems- highlighted in these forums way before launch- were not spotted by professional developers and acted upon.

The answer, I suspect, is priorities. Way too much emphasis has been given to sheen- a star narrator, animations of leaders, authentic voice clips, wonder movies, the day-night sequence etc. Many of these are good- (my favourite is the day-night sequence)- but they don't add much to replayability. A challenging AI does. A glance through the credits will show how little emphasis has been given to the AI.

I don't think people expect perfect AI (most of us want to win more games than we lose), and it would be difficult for the AI to outthink a human- I remember the units killed to units lost ratios displayed in earlier games at the end, and they were always massively in the human's favour- but there was always the challenge or threat there.

The developers are getting a well-deserved kicking on social media forums about the current state of the AI, so hopefully they will act upon it (as they've done- to some extent- with previous iterations). Mod writers will further improve this when they have the tools to do so (though even the best mods are downloaded by a tiny proportion of the player base).

So my answer to the OPs question is 'nowhere to be seen currently, but maybe- on your very own computer- at some point in the future!'
 
It's far more complicated than just this. Let's compare:

In chess, the AI has a maximum of 16 pieces, all with a specific move pattern, to look at, where, in some cases, some are unable to move at all, reducing the number of decisions to take. Also, there's only 1 piece to move each turn with a single victory path.

In Civ6, all of their units has to move, in any direction, and cannot move the same way based on the order they move their units. There's also what building to do, what tile's improvement to do based on one or more victory path they are doing for.

If you want a correct analogy, it would be more like: "In Civ, would be guessing a 8 character password where you get a "yes/no" answer on the entire guess for each units."
You're still missing the most important point; it's the coupling of the choices. The options on how to move that catapult to attack the city is nearly completely independent from your choices of how to defend a city on another front, what you're building in your capital, and whether or not your builder builds a mine or a farm on the opposite side of your civilization. And you get to do all of those things, not merely pick one.

There are lots of things to do, but the whole system breaks down into lots of small, simple, and mostly independent problems.

Chess is hard because those problems aren't independent.

However, to be able to go in that direction, I would have asked myself: "Do I want a direct fight or do I want to take a few more turn through the woods and get the upper hand? Or do I want to try go behind their line and sneak them?" Once we have it, we go in that direction and we move the units starting with the closest to the decision picked.

For the AI, there's no such things, it's just a list of units on a grid and it will evaluate each turn a new tactic, analysing each turn what happened, what's their best move, what's their winning condition.
There are such things if you program the AI that way. In fact, that's how a lot of AI's work -- an analysis module to evaluate the situation, a strategy module to make high level decisions on how to proceed, and implementation modules that carry out those decisions. IIRC, Civ 4's AI works that way. I presume Civ 6's AI does as well.

It's true that modern chess AI's don't work that way, but that's because, for chess, combinatorial search to optimize an evaluation heuristic has proven effective.
 
What makes AI especially hard to create is few people are satisfied with an AI that is aware of the fourth wall. The AI in this sort of game has to be an actor that pretends it doesn't know its playing a game, yet at the same time still is reasonably good at that game. "Good" AI is different from "fun" AI in a lot of ways. AI that was truly smart would realize right away that the human player is the most dangerous player on the board and team up with the other AIs to knock them out of the game.

Not that I think Civ 6 is doing particularly well at either. The AI does get better with mods, and with mods that change base game balance to make it slightly easier for AI to understand, so there is some shred of hope.
 
You're still missing the most important point; it's the coupling of the choices. The options on how to move that catapult to attack the city is nearly completely independent from your choices of how to defend a city on another front, what you're building in your capital, and whether or not your builder builds a mine or a farm on the opposite side of your civilization. And you get to do all of those things, not merely pick one.

There are lots of things to do, but the whole system breaks down into lots of small, simple, and mostly independent problems.

Chess is hard because those problems aren't independent.

That's where you are wrong again because you're thinking only about that catapult, but what about the 2 crossbowmen, the 3 knights and the 6 swordmen next to the catapult? They will need to move, their position is crucial to find the best path and the best way to attack. These are very dependent one to another because of the rule of 1UPT. Remove the 1UPT and I'm pretty sure the AI would gain a lot and now, each unit would be independent. But it's not the case because of the rule of 1UPT. Of course, in your example, they are independent, because you're talking about parts that don't work on the same level. The builder will never be blocked by the catapult and the city has nothing to get blocked.

However, moving the catapult, the 2 crossbowmen, the 3 knights and the 6 swordmen, that's a different story. What if the catapult, which is behind all the forces is, based on the algorithm, the first one to move. It cannot move in front of every unit. And what if, the algorithm has a trigger that says: "Melee units doesn't attack the city until the Ranged unit has hit the enemy city wall by at least 25%", the melee units will probably dance in front of the city, until the catapult gets in ranged and starts attacking. These are all dependant moves, yet the AI seems dump all the way, simply because the order of the units is crucial in his heuristic.

I'll keep this situation, with just those 12 units, if the move order is taken in consideration. For a AI to know which unit is better to move first, it will have to validate the move for each unit and go until there's no unit left, so that's 12! possibilities (12 unit moves, then 11 moves, then 10, etc. to get the number of possibilities, that's 12!), resulting 479001600 possible moves, just for that single turn, with just 12 units. Of course, more than half of these will be cut by the algorithm or because the unit cannot move, but that's still a lot of possibilities to check and that's simply to know the best move order. Also, I'm not counting every possible position on the grid for the move, it's a minimum of 7 tiles (one on each side with the option of staying on the same tile), then there's roads, fortify, fortify until heal, the option to upgrade or not, etc. Now, they will have to evaluate what the enemy(ies) can do, so it will probably evaluate based on 2 tiles within, that's still a tons of process only for 12 units for that single turn only. So I failed to see why you're telling that the system breaks down into lots of small and simple independent problems, since every units are to take in consideration.

Of course, I'm just speaking in theory, because who knows how Civ6 AI works? For sure, the AI designate a small force and group them when they are attacking, because most of the time, you see some unit staying behind doing nothing, so we can assume that Civ6 AI does some grouping to answer to the AI scheme.

There are such things if you program the AI that way. In fact, that's how a lot of AI's work -- an analysis module to evaluate the situation, a strategy module to make high level decisions on how to proceed, and implementation modules that carry out those decisions. IIRC, Civ 4's AI works that way. I presume Civ 6's AI does as well.

It's true that modern chess AI's don't work that way, but that's because, for chess, combinatorial search to optimize an evaluation heuristic has proven effective.

Well.. of course that how works a lot of AI, it's basically the definition of an AI. Every type of AI has to analyze and evaluate the situation, create a high level of decision and implement a modules to carry out. It can be the Alpha-Beta algorithm, the Ant-algorithms, the Differential evolution, the semi-supervised recognition algorithm, they all have to do this in order to analyze and evaluate the situation in order to create a high level of decision then apply it to a smaller scale.

But in all cases, it creates a decision tree that tries to find a winning situation, not just for chess, but for everything that uses AI algorithm. It may be an automatic wheelchair, but the AI will analyze data from cameras and sensors in order to find patterns and take the direction where there's the smaller chances to encounter an obstacle in the wanted direction. I know that because my AI teacher worked on that project.

So yeah, it might be neural networks, machine learning, genetic algorithm, etc. they will all provide a decision tree, even modern chess AI works that way, it will only be helped with some predefined decision stored in a database, but in the end, these database has been filled, but it's almost the same thing in the end. Let's not forget there's 288+ billion of different possition moves after 4 moves in chess, which is fairly smaller than the 479 billion moves from finding the order of moving 12 units...

Sorry but chess is way easier to code than a Civ6 AI because there's way more dependencies than you think, but they aren't all dependent, but there ia fair amount of dependencies.
 
I can remember being whupped by the Zulus and Mongols in Civ I (effectively a 1UPT game) when I first played back in about 1994, and have been regularly steamrollered at the beginning in every edition up to and including 5 (at which point, experienced players will slap their foreheads and ask 'why?'... I know!).

How effectively a 1UPT game?
 
These are very dependent one to another because of the rule of 1UPT. Remove the 1UPT and I'm pretty sure the AI would gain a lot and now, each unit would be independent.
So...reducing the 1upt carpet and going back to some form of stacking is likely to simplify and improve the ai greatly since there will be less pieces interacting with each other on the map, less interactions and conflicting moves, and hence more cpu cycles (digging deeper into the tree of possible moves and actions) can be devoted to finding the more optimal 'intelligent' action for that stack?
 
I have a car that parks itself. I can ask Siri who won the world cup, and Alexa will play music from the naughtiees, but Civ VI is dumb as hell. Gandhi declares war on me for no reason, and I can not ask "Why".

Civ should respond: "you do not see value in life, therefore you have no value" or whatever Gandhi would say.

Anyone else missing that? Real AI? We have self driving cars and the AI in Civ is still super stupid.

I feel your pain but on the flip side how much did that car cost? Your iphone new was probably $700-800 minimum and Alexa is a couple hundred too I assume and its connected to a network of decently smart stuff.

You paid $60 for this game... You get what you pay for but I agree at the very least they could have included an aggressiveness option. This reminds me of Dyson vs Rainbow/Kirby vacuums. Most people will never know what good AI is or care(dyson) but a few will NEVER settle for anything less then perfection (rainbow/kirby). Same with a belkin router or a decent $150+ router, You truly get what you pay for.

So, Firaxis I would have paid twice as much for a challenging and fun AI.
 
I would like to point the AI has always cheated a great deal. You're all comparing the AI like it's been playing fairly and been playing the same game.

What was it, Civ3 or Civ4? Where all the AI's would trade every tech amongst themselves every turn?

So you can't say the AI has gotten better or worse. Maybe the AI is simply cheating less in Civ 6. But obviously some game mechanics are easier than others to code AI for. Don't just think 1UPT, but unstacked cities, culture, religion, espionage all really need to be designed with AI in mind.

You also can't compare the different AI's because they're playing different games. Comparing Civ 1 and Civ 6 is no different from comparing Halo to Civ 6.
 
I don't think any of us are really qualified to comment on the technical aspects of programming an efficient AI but it would be nice if Firaxis improved it to the point where the AI can at least exert some pressure on the player (i.e. take a city with a large superiority in troops). That should at least be doable with some tweaks to city defense and somehow adding some routines for the AI to sacrifice units in order to capture a city (since they can afford to with a numerical advantage). I don't necessarily agree that 1UPT is the main problem though a lot of people seem to think it is. To me 1UPT seems easier for an AI to handle since there are more restrictions and less unit combinations it has to contemplate.

I will say that chess is far less forgiving than Civ. You can make any number mistakes in Civ and still easily come out with a win (probably still true against human players), but one false move in chess and you are likely going to lose the entire game against a decent player.
 
I would say 1UPT is harder for the AI to handle given unlike Civilization IV, I've never lost a city to an AI in this game.
 
I have but it's always a non-walled city in the early game. Anyway, I didn't play Civ 5 but that also had 1UPT and the AI could capture cities from what I understand. I think one really easy thing they could do would be to remove the 'free blanket city walls across your entire civilization' bonus that you get at a certain point in time (can't remember what triggers it) so that you actually have to build them for defense. That would be a good start.
 
Last edited:
Maybe the AI is so advanced that it thought: screwed it, I'm not gonna waste my time on some stupid game, I'm gonna take over the real world!
 
I wish I could have a sense of humor about it, but we're probably looking at America's next president here.

Hm, I don't think this is wise. There is much political snark to go around, we should not dish it out if we would not want to receive it I think? I think we are better not bringing these things here.
 
The irony is most declare war on me because I'm a warmonger.
This.

Also, there's a tab where you can see the factors that affect your relationship with a certain leader on the diplomacy screen. Take Pericles for example; you might get +3 for a friendly meeting, but -6 because he's angry you're competing with him for city state alliegance.

Fun fact: Expect something like -300 for warmongering.
 
Top Bottom