Medieval worlds

A young person enters a craft household to learn a trade under an experienced practitioner. Which urban institution most likely organized or regulated this training?