The AI will build the best units it can if you give it time, e.g. I have had English armies come at me with retinue longbowmen and such. However the player can generally reach them before the AI does.