I imagine regulated distribution. Make people have to jump through hoops, get enrolled in a national registry and take educational classes on the drugs. Incentivize this route by offering cheap/free, pure drugs so that black market alternatives become exceedingly less worthwhile. Basically the meta version of parents allowing their kids to drink under supervision. Society has a chance to convey and establish norms for use and can intervene if a person falls into dangerous patterns.
Copy the driver education program? Supervised learning and testing with a controlled final "test drive", even have 5/10 year re-certification tests.
You don't see potential problems with a national registry of drug users? Like say, employers, snoopy neighbors and political opponents?
That's a great point. I actually heard of a colleague of mine who was injured on the job at his previous work. He did construction. They found out he was a medical marijuana patient and that made him ineligible for re-employment or workers comp.