AI provides exciting commentary to a game of Pong

"I taught an AI to commentate Pong in Real Time," writes Parth Parikh, almost confessionally. "… xPong is all about Pong — but with a twist: there's LLM-based commentary generation integrated into the game."

And so it does, with all the euphoric detail of game day. Jump to 2m 30s for the game's commencement: "as we kick off this championship match, it's fascinating to see the contrasting styles."

I've wanted to do this for the longest time — in fact, back in my undergrad days, I used to carry around a GitHub Gist to store such ideas, and an entry for this one dates back to Feb 16 2020. That's five years! Anyway, for the longest time we never had the right technology to pull this off in a cost-effective, near-realtime manner. However, late last month, with OpenAI's gpt-4o-mini-tts, we finally have the resources to do it! I envision a future where gpt-4o-mini-tts-like software is integrated on the edge — that is, edge LLMs. When that happens, next-generation gaming consoles will leverage such technology, opening up a whole universe of possibilities in gaming, especially in sports-simulation titles. Hope you have a blast tinkering with this game and its source code!

Beautiful and horrible at once; be sure to read the prompts that circumscribe the language at GitHub: "There's a tournament simulator that simulates 15 years' worth of tournaments. Each year includes four majors — sixty events in all. Players and matches are simulated using Elo. In the 16th year, when the main match starts, the world's top two players face off in the World Championship Final."

Ethics notwithstanding, I must now hear Murray Walker commentate Crossy Road.