We don't know exactly what's going on in someone else's mind, but we can take a guess based on their behavior. That goes for primitive species like worms with few neurons, up through animals with many neurons, to humans, who have taken the concept of "mind" a lot further.
