For as long as cyclists have to cycle on the roads as we know them a cyclist should be required to demonstrate that they understand the signs and rules of the road. That could be by presenting their official drivers license, or, should they not have one, be required to take a theory test. I think that would be a sensible first step.
You could then imagine a practical test for hazard perception, efficient use of gearing and safe filtering through queues of traffic.
Naturally, people don't walk on the road, and pavements don't have the same kind of mandatory control flow unless they intersect with the road, and most children are taught how to cross the road from a young age.
I would get into a ton of shit should I visit anywhere that had jaywalking laws, though in the places they exist and are enforced, they presumably get by without a dedicated licensing and testing regime.
One thing to consider is how much effect licensing has on car safety anyway. Mexico city has no test requirement at all, you just pay for permission to drive rather than sitting any test, while Peru has more road deaths per capita, despite needing a practical test, written test and medical certificate before you get behind the wheel.