To reply to the example given with river crossing.
A) The AI needs to evaluate the need to cross the river. What will happen if it tooks defensive posture and just hides in its own woods? If it is a least a draw than this is a valid option. Even if its a sure loss it can try to gamble(rarely) and play the def posture.
In this example the AI is advancing and the player is defending. The only way to reach the objectives is to cross the river.
What should a 'defensive posture' be like? If the advancing group has tank platoons, mech platoons, AA/AT assets and mortars, advancing in a column formation, what happens when it takes a defensive posture? They just stop where they are?
Currently the AI can leave formations to defend objectives it has captured.
B) If it decides to cross it needs to do it with cheap/recon units until it knows there are no enemies that shoot in that woods.
C) If it loses its cheap units in that wood than this wood is not safe. Usually this will be due to enemy inside but it can also be due to enemy observing the forest from some location(this should be checked using LOS as the players does, without cheating) - Everything in LOS of the location of ambushed unit and out of your own LOS should be marked dangerous with different coefficient. If it is assumed there are enemy units in the wood, then one way is to bomb the hell out of the forest, to prepare a cheap force that excels in wood ops (basic infantry + some recon) and to send them in using smoke cover.
A lot of assumptions are made here. The AI doesn't necessarily have recon units, artillery/mortars or dismounted infantry. All this must be taken into account. It may have a few though, but not enough to include them in all maneuver groups. The map can be huge (15x15 km), so it takes time for units elsewhere to travel to these hotspots.
About checking the LOS to mark the 'dangerous areas': See the attached image. If the attacker hasn't been spotted, in many cases there's no way knowing if he's kilometers away or 100 meters away. On the other hand, if he's spotted, then he'll probably be killed very soon, especially if spotted by tanks.
From the movies i saw i can say the following:
concerning point A. The AI is usually too aggressive. It takes defensive positions too rarely. The evaluation where to advance and where to defend needs to be reevaluated. The AI does not respond properly to problems after making its initial plan. It should make a new plan according to the new info it posses during battle. When you send in a major trust and it is ambushed your initial plan is void, you need a new one, and only try to bruteforce as a small random factor option(to still be unpredictable).
concerning point B. It seems it does sent cheap units, but usually not in good formation. The way they are sent could be improved, they seem to follow same path and this is wrong, recon units should try to identify maximum territory with minimum squads, this is not done when they are going one after the other over the same route.
I agree. However, it's a long way from these abstract ideas to having it in the code. Is there a tactical wargame that does this without scripting or cheating?
concerning point C. The AI does not use artillery in good coordination. It seems to use far less arty than the player as a whole, this needs to be improved - the AI should try to use the arty more. When it does use its arty we can give comments if it does it right.
The AI does use artillery, but it's true that sometimes it doesn't use it much. In these cases there's a reason for it, and each case should be analyzed separately, without generalizing. If the AI has DPICM it can destroy your dug-in M1A1 platoons in minutes.
can the ai be modded (a config file or something)?
Factions do have a few AI attributes that can be adjusted, but nothing complex.