Sounds like a fun project! Not sure if this is the proper wiring schematic for your 500, but here is a wiring diagram for a 500 of some unknown year... Unfortunately, what you really need is a pin-out of the particular connectors on the wiring harness. The striping on the wires in the harness could match that of this diagram, and then you could use those colors as reference. But I would rather go off of a connector pin out! You might be able to find that if you can track down a service manual...
Essentially, you will need to replace the ignition switch on this diagram with something that will connect the wires into that switch in a manner described in the diagram.
If you aren't on a super tight budget, I'd honestly recommend an aftermarket ECU... Something cheap that has a stock tune for the ex500. This will have a documented pin out for the ECU, such as "coil 1 on this pin, coil 2 on this pin, ignition switch in, starter switch in, etc." That will allow you to greatly simplify your wiring harness to something that contains only the components you need for running the engine and get rid of extra buttons and features that will be rather pointless on a kart.
Speaking from experience in wiring race cars, the less wire, the better. Something will go wrong or not work right. The most bare bones you can make the system, the easier getting the bugs sorted out will be. Besides, you will learn a hell of a lot about a system like that by wiring it!
Hope this helps some, let me know if you have any questions!

Essentially, you will need to replace the ignition switch on this diagram with something that will connect the wires into that switch in a manner described in the diagram.
If you aren't on a super tight budget, I'd honestly recommend an aftermarket ECU... Something cheap that has a stock tune for the ex500. This will have a documented pin out for the ECU, such as "coil 1 on this pin, coil 2 on this pin, ignition switch in, starter switch in, etc." That will allow you to greatly simplify your wiring harness to something that contains only the components you need for running the engine and get rid of extra buttons and features that will be rather pointless on a kart.
Speaking from experience in wiring race cars, the less wire, the better. Something will go wrong or not work right. The most bare bones you can make the system, the easier getting the bugs sorted out will be. Besides, you will learn a hell of a lot about a system like that by wiring it!
Hope this helps some, let me know if you have any questions!