she's probably just someone who was neglected or abandoned by their family.. idk what sort of institutions equestria would have for that, although there hasn't been any depiction of like. an orphanage. anywhere. idk she might've just grown up on the street or smth. when u have to look out for urself like that, developing misguided ideals to survive in that situation tend to stick with you. like perhaps she saw friendship as a means to get by, a way to get what she needed to live or survive. maybe she figured the only way to make do was to outwit others emotionally. anyone who grows up on the streets or on their own is generally a lot more aware (comparatively), but it's also a forced maturity, in a way; yes she is aware that she can manipulate others due to her age, cuteness, etc.. but no she does not understand the consequences of it, or much of anything.
but yeah she's probably just a street urchin or something :3c def a real kid, though