Is everyone forgetting that Ultron is literally the sentience of the Mind Stone. The AI Tony and Bruce created was a shell at the time, Ultron IS the Mind Stone. It knows how to access ALL of it's abilities. Not to mention Thanos was caught off guard, he had no time to activate the stones.