I cannot recall this topic being explained much in the show. Do they have court, judge or jury?
And there is one thing really strike me is how much influence princess has over the legislation system. Starlight Glimmer, completely free of any guilt, even allowed to join the core political circle, only because princess twilight decided to forgive her. And no pony in equetria ever questioned. Where are the victims? Do they all signed the form of forgiveness? But even if all victims agreed to forgive the criminal, the decision I think should still be made with the complete legislation process to be fair. It was not a pocket-picking small crime, it was enslavery and brainwash.