In Imperial China, Law Enforcement for the longest time, was a community job.
If you lived close to a military garrison (say, a fortified city) then the cunts enforcing the law would be the soldiers.
However, China happens to be a vast empire, and soldiers cannot afford to move far from their garrisons lest they spread out. So in the rural countrysides, what the Chinese do is simply send a single judge/jury/executioner type legal officer called a prefect to oversee at least 3 villages. Law enforcement, however, is done by the regular Chinese peasant, who more often than not, owned weapons. The males of the villages would form armed posses to go after robbers, bandit groups, town troublemakers, and problematic animals such as tigers & wolves, or simply drunk Uncle Ho trying to burn down an Inn again. To make Posse actions legal, the Prefect has to be notified of any arrests or, during times of bandit wars, lead the posse himself as the dude has basic military training.
Version 2 of law enforcement came from Private Military Groups of armed young men- memefully rogue scholars, but usually ex-soldiers, bravos, reformed criminals, toughs, and inheritanceless sons- who wandered around China offering services to whoever is rich enough. Since government contracts are lucrative, they were hired as muscle by the prefects, to make up for any shortcomings of the village posse. Their life is the stuff of Imperial Chinese popular poetry, which called them Youxia (wandering heroes).
Also this set-up led to the rise of martial arts schools among civilians, particularly the monasteries. Being places stocked with food & money, monasteries were vulnerable to bandits. So the Monks made martial arts their physical training to protect themselves. Unlike villagers though, Monks had all the free time from meditation - in addition to disciplined life- that made them almost paramilitary, as the Shaolin Monastery proved to be during the Pirate Wars of the 1560s.
Attached: Wandering Bladesman.jpg (2481x3509, 1.03M)