Peace deals should exist that prevent the Ai from going to war for X amount of time, whether its a year, 2 years, etc. This would also allow for non-aggression pacts, as well as alliances. Give the Ai something to do during peace time, at the moment they have nothing else to do but fester and start another war.
People have suggested bringing back feasts as a start, or tournaments hosted by lords and not just randomly generated accross all cities. I would suggest also giving the Ai activities such as A king visiting all the cities and villages within his domain, like kings were known to do throughout history. Public works are another option for a peacetime mechanic, wars devastate the landscape and the infrastructure of your nation, having a peacetime activity such as rebuilding village homes, clearing debris, paving new roads etc can be implemented to give the Ai something to do while they recover their nation from the last war.