Singer actually sold "conversion kits" for treadle machines. I have a manual for how to hook them up. The first electric conversion kits have a very old style pedal and different type of connection than what we have for modern use. It even shows plugging it into a light socket on the wall. I so want to get a vintage wall scones with an outlet built in, but I have no where I can wire it in to my house. Will save that for the next place!
You have later wiring than that - same as what my 1930's machines come with. I may need to look through the manuals and see when that type of light first showed up. Even with that, it looks like the plug in cord was probably replaced at an even later date.