Well, more specifically, there actually are human beings inside the cars, and are the source of the car’s personality, intelligence, everything. The mechanical car is just the external body of these human-derived creatures. I call this the Homunculus Theory.
Color me disturbed but in agreement that this is the most plausible theory. Keep in mind, it’s a kids’ movie and therefore the origins don’t have to be figured out.