Buffs are rated higher the earlier in the battle they are cast.
Buffs are also rated higher the more HP etc the target has.
Also astral shield is more powerful if you have high astral magic and the spell is likely rated higher if you are strong in astral magic.
Supposedly your tartatian was strong and powerful enough to warrant a hefty and early buff
Normally scripting gives spells very high ratings, but there are instances where a spell can get a higher, in order to save gems or avoid loops or other strange behaviors. This might be a case where the script rating is beaten by an unforseen rating due to an extreme situation (overly powerful tartarian).