The magneto generator doesn't put out anywhere near an electric bike motor needs to run, but if you have room for the batteries and the engine, it can be done. To make a true "hybred electric/gas bike, you would need a pretty powerful gas engine to run a pretty powerful generator to feed those power hungry electric motors, a decent electric hub motor will need about 1000 watts or more of power and it takes about a 2hp engine to power a 1kw generator... and bigger generators require even bigger engines which would end up way too heavy of a setup to be practical.
Now if you can get en electric hub motor kit with the batteries and find a way to mount the batteries so they could feed the hub motor, then mount the gas engine in it's normal location or on a rear rack for friction drive, then you could have a 2 wheel drive gas/electric bike that could use the gas engine, the electric motor, or both to power it.