Some say it was a spark that started the universe.
It's pointless trying to trace back before the spark because it's what happens afterward that's really important. Synapses spark inside the brain and send ideas into motion, there's a lot of great animated graphics of the process but it probably fails to capture the real lightning storm going on inside the head of a human.
The closest thing which replicates the process probably takes place inside a computer and that's the scary part.
People imagine machines as cold and calculating because they're used by humans to do some pretty awful things. Computers calculate compound interest and navigate missile guidance system for bombs delivered to commit mass murder and probably take out a few innocent children in the process. For now and hopefully forever people spark machines into actions in order to do a great deal of their dirty work. The illusion of computers giving orders is a convenient escape for those hoping to avoid responsibility. It's almost easier to accept an atrocity from a machine because human compassion isn't expected. But like the great and powerful Oz twisting and turning levers to power his illusion, there's always a pathetic man behind the curtain. For now.