There's the way my e-bike works ; The electric assistance is supposed to be limited to 25km/h, you can opt to disable this through clicking a few buttons in an app for most brands, and use your vehicle on private roads only.
Then it relies on enforcement to catch you operating an illegal vehicle on a public road
Unlike e-bikes, your vehicle has a plate, so needless to say, if you get caught speeding on a public road by a camera and your vehicle was registered as having had the thing turned off at the time in the database (i.e. it shouldn't be on a public road), you could imagine getting an additional charge similar to operating a vehicle without a license plate or operating something that's not road-legal.
It makes total sense to me