The topic of using AI - or rather Artificial Neural Networks (ANN) - with Vassal keeps popping up in the forum, so there’s dedicated Documentation page for it: see Does Vassal support computer opponents?.
Read the above linked post. What the ANN will need is access to game state, etc.. which is most effectively done through an API.
Begin Rant
That said, remember what it is an ANN does: It recognises patterns and then replicates those based on current input. To recognise a pattern, the ANN needs to have seen that pattern, or something very similar, beforehand.
What this means is, that an ANN opponent would need to train on previous game patterns - e.g., logs of previous game session. And to be any good at recognising anything, the ANN needs to have seen many examples. Those a generally not available.
Do not be fooled by the apparent ability of some ANNs to come up with “new stuff” - it doesn’t, because everything is based on what it has seen before. A"I"s are not intelligent in any sense of that word - at least, not more intelligent than a thermostat.
That said, it is not like ANNs does not have their use - you just cannot rely on it to do anything remotely intelligent, safe, or correct. ANNs will like try to cheat if it fits with a pattern it has recognised. Remember, the ANN does not understand the rules - it just recognises a pattern.
Some people use ANNs to “read” the rules for them, to make summaries or do a quick query. However, ANNs do fail to accurately do that job too (“yes, you can move your division through your opponents division”, “no, you cannot disengage from combat”, …).
End Rant
Yours,
Christian