They probably originated roughly similar to the geth. This kind of thing happens all the time in science fiction.
Ancient civilization needs cheap work force. Ancient civilization creates machine race to serve them. Machines slowly grow more and more intelligent. Machines gain sentience. Sentient machines get pissed at the civilization for enslaving them. Galactic war occurs usually with machines as victor. Machines begin to believe that organic life is inferior and only causes trouble. Machines proceed to cause mass galactic extinction.
This is where Reapers take a different path than the other sentient machine races. Most machines would be fine eradicating all organic life, but Reapers instead like to harvest them every so often a species gains sentience and begins to span the galaxy. This is probably why they were so much more interesting than the machines in The Matrix, for example.
Ancient civilization needs cheap work force. Ancient civilization creates machine race to serve them. Machines slowly grow more and more intelligent. Machines gain sentience. Sentient machines get pissed at the civilization for enslaving them. Galactic war occurs usually with machines as victor. Machines begin to believe that organic life is inferior and only causes trouble. Machines proceed to cause mass galactic extinction.
This is where Reapers take a different path than the other sentient machine races. Most machines would be fine eradicating all organic life, but Reapers instead like to harvest them every so often a species gains sentience and begins to span the galaxy. This is probably why they were so much more interesting than the machines in The Matrix, for example.