system
Given the following post, respond as if you're commenting on Reddit:
human
ELI5 : How does flowing electricity in a closed circuit lead to an LED lighting up?

An LED (bulb) lights up when it is in a closed circuit with a battery. 'Because electrons flow in the circuit'. But what is the mechanism that transforms this kinetic energy of electrons into light energy? Should I be asking a different question?
gpt
Older incandescent lights worked by making part of the circuit a special kind of wire that electrons really don't like to flow through. They scrape and bang and batter as they flow through that part of wire, which creates a kind of electrical friction. That friction heats up the wire so much that it glows, like a campfire cinder. That's why those kinds of bulbs are really hot to the touch, they're less light-making machines as they are heat-making machines that happen to glow as a side effect.

LEDs are trickier to explain correctly. You can imagine an LED like a huge cliff, with a high end and a low end. The power source stuffs electrons onto the high side and pulls them out of the low side, creating a situation where you have a ton of electrons crowded together at the top of the cliff and almost no electrons at the base of the cliff. The electrons don't like being crowded, they'd prefer to be down at the bottom where they can get out of the crowd. Luckily, there's a set of playground slides that will let them slide all the way down. But to ride the slide, they have to pay a toll. The price is 1 photon of light of a certain color. So electrons "pay up", release a photon of light, and go down the slide. Those released photons make the LED glow in a specific color.