(I'm going to assume we're talking about BtS here... for Vanilla and Warlords I fear that some things might be different, but I don't know exactly what)
Is there a thread or a guide covering how the AI leaders generally behave?
The AI leaders generally behave according to the CivLeaderHeads XML code - found in the assets/XML/Civilizations folder. The challenge is understanding what each of the fields actually mean in practice.
Obviously there are many different parts to answering your question.
How the AIs behave regarding war is IMO very well answered by
this post by DanF5771. There is also an attached zip file that is especially useful, and has an excel spreadsheet of the LeaderHeads XML.
The 'Thresholds' fields are particularly useful to know. These are the attidute limits that you must EXCEED before a particular option comes up in trade. Eg, for Alexander, the TECH threshold value is ANNOYED - this means that he will only trade techs with you if you are CAUTIOUS or better.
Slightly more complex is bribing an AI into war with another AI. In this case you must exceed the DECLAREWAR threshold as well as their relationship with the AI must not be as high as the DECLAREWARTHEM threshold. Eg, Alexander you must be CAUTIOUS or better and he must be PLEASED or worse with the target AI.
There are some exceptions, eg, Tokugawa won't OB with you under any circumstances unless you've shared a war with him. (At least I think that's how it works) I don't know off-hand what all of these exceptions are. And I think some of these are also modified when the 'Aggressive AI' option is set, as you'd expect to encourage more war.
The 'NoWarProbs' fields are a useful guide to keeping out of wars with an AI. Again, they are explained well in Dan's post, but in general they give you a % chance that an AI will NOT consider a war with you at each of the attitude levels. (Although from
my own experience it's not quite bulletproof.
Another useful section are the 'TradeVals' fields. The iNoTechTradeThreshold governs the number of techs an AI can see you receive in trade before they reach the "We Fear You Are Becoming Too Advanced" limit. This is quite well explained in
this thread by VoiceOfUnreason.
There is also the iTechTradeKnownPercent which specifies the percentage of other AI who also know a tech before an AI will offer to trade. Eg, if an AI has a monopoly on a tech then they would only trade it if their threshold is 0 = Mansa Musa. For Alexander agagain, if there were 12 players total in the game, him, you and 10 others, then he would only trade a tech if 30%, or 3 other AIs know that tech.
Finally, I have found the
Civ4 BTS Reference Sheet by dj_anion especially useful. In fact, I think I might send him a postcard
