The automatic ambushing by your forces of all AI armies that are close to them is really driving me crazy

They just keep ambushing armies more than 10 times their own size, and they keep starting wars by ambushing neutral armies.
Just a few minutes ago they ambushed an army of the Papal States...
I of course withdrew from the battle, but still was excommunicated