Quoting Lord Xia, reply 10It would make more sense that the AIs gang up on the most powerful nation, not the weakest.
Actually, that wouldn't make any sense at all. It is far more logical to kill the weak and use diplomacy to prevent the strong from killing you. Dogpile also makes sense: the A.I. has better odds of defeating you when you're already engaged in another war. A.I. sovereigns aren't auditioning to join the Knights of the Round Table, they here to kill you in the most expedient manner possible.
It depends on what the goal of the AI sovereigns is. Do they want to maintain status quo (at least temporarily)? Then it makes sense for them to aid weaker nations against stronger nations. Do they want to weaken a strong nation so that they have a chance at beating that nation eventually? Then it makes sense for them to support (though not necessarily openly aid) a weak nation in a fight against a strong nation. Do they want to see a great nation brought low? Then it makes sense for them to form alliances that they think have the power to bring down that nation in a war, and aid those fighting that nation. Do they think that by supporting the strong nation they'll at least have a little more time to build up strength before the strong nation turns on them? Then it makes sense for them to attack you when the strong nation does, for two reasons: one, by taking some of your cities they'll gain some strength; two, by aiding the strong nation in its assault on your kingdom they might gain enough of a relationship boost to at least be the last morsel eaten at dinner, rather than the be the next bite taken. On the other hand, if they have other options for gaining strength, it might make sense fro them to quietly support your faction's war effort against the invading nation in the hopes that war with you will weaken the strong nation enough to give them time to build up enough strength to stand a reasonable chance in open war with the strong nation.
Right now, it seems like the only motivation of the AI sovereigns is to be on the winning side of a war, regardless of how much or little they can gain from 'participating' in that war. If I'm on one side of, say, Yithril, and Gilden is on the opposite side, then it is in Gilden's interest that Yithril's attention be occupied by my nation for as long as possible. It isn't in Gilden's interest to declare war on me just because Yithril does, since Gilden will never gain any of my territory if they have to cross Yithril to get it, and the relationship boost with Yithril from helping Yithril in a war against me isn't going to significantly delay the time when Yithril turns to Gilden and says "Those are some nice cities you have, I think I'll take them for myself." On the other hand, Yithril is probably sending a fair number of its armies against me, leaving it (somewhat) vulnerable to being stabbed in the back by Gilden. And if my power rating and Gilden's power rating total up to roughly what Yithril has, the Gilden AI should go "well, at least there is a chance we'll win if we aid those guys on the other side." rather than "gee, those guys on the other side of Yithril have not a snowball's chance in Hell, I think I'll declare war on them to keep Yithril happy." In this example, Gilden is more likely to gain enough power to oppose Yithril by attacking Yithril while I'm occupying Yithril's armies, rather than by declaring war on me to keep Yithril happy. Even by remaining neutral they are more likely to have a positive outcome - Yithril isn't going to be ticked off that Gilden tried to betray them if I lose, and if I win I'm not going to be ticked off that Gilden attempted to jump me when Yithril decided to try to consume my faction.
I do think the second option in my example above should be something the AI considers doing, if they have particularly good relations with Yithril and not with me. It's just something that should be much less prevalent among the AI sovereigns - if you must go to war, at least go to war with someone who you border so you stand a decent chance of taking over a few of their cities in the war.