The <AutoUnlock> is what brings our spells into our spellbooks most of the time. If you have prereq triggers, and <autounlock>1 you'll find the spell in your spellbook when you fulfill the prereqs. The other way for spells to end up in your spellbook is through research, or special unlocks such as Annointed by fire.
However, the AI does not always honor strategic spells that lack the <AutoUnlock> trigger. Below is a sample spell that the AI - for unknown reasons - can start casting from the very start of the game.
<SpellDef InternalName="Reliquary_SoulContract">
<DisplayName>Soul Contract</DisplayName>
<Description>Summons a Lower Death Demon, its level is equal to half of the caster's</Description>
<Image>S_SummonEarthElemental_Painting.png</Image>
<IconFG>S_SummonEarthElemental_Icon.png</IconFG>
<IconBG>S_SummonEarthElemental_Icon_BG.png</IconBG>
<IconColor>167,249,131</IconColor>
<CanStack>0</CanStack>
<SpellType>Strategic</SpellType>
<SpellClass>Defensive</SpellClass>
<SpellSubClass>Summon</SpellSubClass>
<SpellTargetType>Self</SpellTargetType>
<Range>0</Range>
<IsCastable>0</IsCastable>
<GameModifier>
<ModType>Unit</ModType>
<Attribute>SummonUnit</Attribute>
<StrVal>Lower Death Demon</StrVal>
<Calculate InternalName="Calc" ValueOwner="CastingUnit">
<Expression><![CDATA[[Unit_GetLevel] /2]]></Expression>
</Calculate>
<Calculate InternalName="Value">
<Expression><![CDATA[[Calc]]]></Expression>
</Calculate>
<UnitClass>LowerDeathDemon_BG_Summon</UnitClass>
</GameModifier>
<AIData AIPersonality="AI_General">
<AIPriority>70</AIPriority>
</AIData>
<HitSoundFX>Spell_Summon_Earth_Elemental_01</HitSoundFX>
<SpellDefEffect>
<EffectName>S_SummonEarthElemental_Particle</EffectName>
<LocalPosition>0,0,0</LocalPosition>
<EffectScale>0.5</EffectScale>
<EffectDelay>0</EffectDelay>
<SnapToTerrain>1</SnapToTerrain>
</SpellDefEffect>
</SpellDef>
When introducing new strategic spells to the game, be extra careful so that the AI does not have free access to them. Do this by having a Prereq or a SpellResourceCost.