Natural Language Processing for Automated Game Commentary
Can a machine describe a fast break the way a broadcaster would? That question opened this term's natural language processing project, which set out to build a lightweight pipeline converting structured game events โ a made three-pointer, a steal, a fast-break dunk โ into short, readable commentary sentences. It is, on the surface, a fun and approachable problem. Underneath, it touches nearly every core challenge in applied NLP: entity extraction, controllable generation, factual grounding, and evaluation of open-ended text, which has no single 'correct' answer to check against.
The project was scoped deliberately narrowly. Rather than attempting to generate flowing, multi-minute broadcast commentary, the team focused on single-event descriptions โ the kind of short burst of text that might accompany a highlight clip or a live play-by-play ticker. This constraint made the problem tractable within a semester while still requiring students to confront the genuinely hard parts of language generation.
Starting from Structured Events
The input to the system was a structured event log: a sequence of records specifying an event type, the players involved, the game clock, the score at the time, and relevant spatial information such as shot distance. Before any language was generated, students had to design a schema expressive enough to capture the range of events worth describing, without becoming so complex that downstream generation became unwieldy.
This schema-design step is easy to underestimate but turned out to be foundational. An event log that failed to distinguish, for instance, a contested three-pointer from an open one made it impossible for later stages to generate commentary with any real texture โ the difference between 'a shot went in' and 'a well-defended, clutch three-pointer' lives entirely in details the schema either does or does not capture.
Entity Extraction and Context Building
With a populated event log in hand, the pipeline's first processing stage identified the key entities relevant to each event: which players were involved, what their role was (shooter, assisting passer, defender), and what contextual factors mattered โ was this a go-ahead basket, a rare and-one, or a routine mid-game possession? Students implemented this as a rule-based extraction layer initially, then compared it against a small learned classifier trained to rank which contextual factors were 'commentary-worthy' for a given event, since not every basket deserves the same descriptive energy.
"The rule-based version was actually harder to get right than I expected. You start writing a handful of conditions and within an hour you have forty edge cases โ and-ones, buzzer-beaters, four-point plays โ each needing its own little carve-out. It gave me a real appreciation for why learned components exist."
โ [Riddhi Gupta], [MCA Student]
From Structure to Sentences
The generation stage itself used a template-and-slot approach layered with a language model to add natural variation, rather than relying on either extreme alone. Pure templates produced correct but repetitive text โ every three-pointer described in an identical sentence structure quickly reads as robotic. A pure neural generation approach, on the other hand, produced more natural variety but occasionally invented details that were not actually present in the event log, a classic hallucination problem that is especially unacceptable in a sports-commentary context where factual accuracy is the entire point.
The team's hybrid solution used structured templates to guarantee factual grounding for the core facts of an event โ who, what, when, the score โ while allowing a constrained language model to vary phrasing, sentence rhythm, and descriptive tone within those factual guardrails. A separate verification pass then checked every generated sentence against the original event record, flagging any output that mentioned a player, score, or statistic not present in the source data.
Figure 1: Simplified pipeline used to convert structured game events into automated commentary text.
Tuning for Broadcast Tone
Getting the facts right was only part of the challenge; getting the tone right mattered just as much. Early outputs read more like database summaries than commentary โ technically accurate but flat. Students iterated on a style-control layer that adjusted vocabulary and sentence structure based on the significance of the event: a routine second-quarter jumper was described plainly, while a go-ahead shot in the final minute triggered a noticeably more energetic register, mirroring how human broadcasters modulate their delivery based on stakes rather than describing every play identically.
"Watching students realize that 'sounding excited' is itself an engineering problem โ not just a creative one โ was one of my favorite moments teaching this module. Controllable tone is a real, actively researched area of NLP, and this project gave them a hands-on, low-stakes way into it."
โ [Ms. Savita Prabha, Assistant Professor], Department of Computer Science & Applications
Evaluating Generated Text
Evaluation posed its own challenge, since there is no single correct sentence describing any given play. The team used a combination of automated factual-consistency checks โ confirming every named entity and statistic in the output matched the source event โ and a small human evaluation study, where classmates rated generated commentary on fluency, appropriateness of tone, and whether it felt distinguishably repetitive across a sequence of events. This mixed evaluation approach mirrors current practice in the broader NLG research community, where automated metrics alone are widely understood to be insufficient for judging open-ended text quality.
Limits and Responsible Use
The project also became a natural opportunity to discuss the current limits of generative text systems more broadly. Even with a verification layer, edge cases slipped through โ ambiguous event records that produced technically defensible but slightly misleading phrasing. The team's conclusion was one increasingly echoed across the field: automated generation tools are well suited as a drafting aid or a way to produce first-pass content at scale, but human review remains essential before anything is published, especially in domains like sports and news where factual precision has real reputational stakes for a publisher.
A Closer Look at Failure Cases
Part of what made the project feel authentic was the team's insistence on keeping a running log of failure cases rather than only showcasing polished output. Some of the more instructive failures included commentary that technically described the correct event but in an oddly flat sequence when several similar plays happened in a row, and cases where the verification layer correctly caught a factual error but the resulting fallback sentence read as noticeably more generic than the surrounding text, creating an inconsistency a careful reader would notice.
Working through these cases pushed the team toward a more graceful fallback strategy: rather than substituting a bland, safe sentence whenever verification failed, the system now falls back to a slightly less detailed but still stylistically consistent description, preserving the overall reading experience even when the more specific generation attempt had to be discarded. This kind of graceful degradation, prioritizing consistency over showing a visible seam, is a pattern that shows up across many applied generation systems and became one of the more sophisticated lessons of the semester.
Comparing to Human-Written Commentary
As a final evaluation step, the team ran a small blind comparison, mixing generated commentary sentences with human-written examples describing similar simulated events and asking volunteer readers to guess which was which. Readers correctly identified the machine-generated sentences a little better than chance, most often flagging generated text as slightly over-explained โ including details a human commentator would typically leave implicit given shared context with the audience. This finding pointed toward a promising next area of work: teaching the system what to leave out, not just what to say, which is arguably the harder and more interesting half of concise, natural commentary.
It also prompted a broader class discussion about what makes commentary feel human in the first place. Much of that quality, the group concluded, comes not from vocabulary or grammar but from selective omission โ trusting the audience to infer shared context rather than spelling out every detail. Teaching a generation system to trust its audience the way a human broadcaster implicitly does turned out to be a surprisingly deep design problem for a project that started as a lighthearted 'can a machine call a game' exercise.
What Students Take Away
Beyond the technical pipeline, students consistently pointed to one lesson as the most transferable: fluent-sounding output is not the same as correct output, and building the verification layer taught them to distrust their own generation system by default rather than assume plausible-looking text is automatically trustworthy. That instinct โ treating a generative model's output as a draft requiring verification rather than a finished answer โ is one the department is now actively reinforcing across other project-based courses that touch on generative AI.
Looking Ahead
Future extensions being discussed include multi-sentence commentary that maintains context across a short sequence of plays rather than describing each event in isolation, and a lightweight personalization layer that could adjust vocabulary complexity or focus for different audiences โ a casual fan versus a follower of advanced statistics, for instance. The team is also interested in extending the factual-verification component into a general-purpose module that other departmental NLP projects, including the automated-summary tools used in the data analytics seminar, could reuse directly.
About the authors: [Ms. Savita Prabha, Assistant Professor] teaches the department's natural language processing and computational linguistics courses. [Riddhi Gupta] is a student who built the hybrid template-and-generation pipeline described in this project.