If you want to increase your popularity with AI click the link below
Personally an AI has never declared war on me after 4,5 games. I just searched on google why ai declared war on me and I found this thread. Since then I have been following the steps written in this thread and had great popularity with AI.