If I am correct... the Derbi (and Aprilia, and Yamaha Zuma) are all required to be licensed as motorcycles.
The government has no restrictions for 50cc motorcycles.... 50cc mopeds on the other hand are required (by the US gov) to be 2hp 30mph automatic trannies.
It is quite easy for the manufacturers to make 50cc 2 strokes to make 4 to 7HP... so that is what the Derbi is.
How?... an integrated system of airfilter/carb/reed valve/cylinder/piston/head/exhaust pipe designed for a meduim amount of power and good reliability.
Consider this... a 65cc KTM mini dirtbike puts out 15HP (with a gearbox).. so a 50 could put out 11.5 HP... so 5 to 7 HP is easy.
For you to make yours do that requires all those parts put together in a well engineered system as mentioned.
Frankly... stock Tomos' are already stretching the government restrictions.. I don't know how they did that.