← Latest papers
🤖 machine learning

Play Like Champions: Counterfactual Feedback Generation in Latent Space

This paper introduces "Latent Maps of Performance," a framework utilizing a Guided Variational Autoencoder trained on professional StarCraft II replays to generate actionable, multi-step counterfactual feedback trajectories that guide amateur players toward winning configurations by traversing a learned latent space of expert behavior.

Original authors: Andrzej Białecki, Adam Mastalerz, Han Zhou

Published 2026-07-02
📖 5 min read🧠 Deep dive

Original authors: Andrzej Białecki, Adam Mastalerz, Han Zhou

Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

Imagine you are watching a professional StarCraft II player lose a match. You know they played well, but they still lost. Now, imagine an AI that doesn't just tell you who won, but acts like a time-traveling coach. It asks: "If you had made just a few different moves, could you have won?"

This paper introduces a system called Latent Maps of Performance that does exactly that. It uses advanced math to create a "map" of how games are played and then draws a new path for a losing player to follow that leads to a win.

Here is how it works, broken down into simple concepts:

1. The "Black Box" of Game Data

StarCraft II is a complex game with thousands of numbers changing every second (how much gold you have, how many units you built, how fast you are clicking).

  • The Analogy: Imagine trying to describe a whole movie by listing every single pixel that changes on the screen. It's impossible for a human to read.
  • What the paper did: The researchers took thousands of professional replays and fed them into a special AI (a Guided Variational Autoencoder). Think of this AI as a master chef who tastes a complex stew and writes down a simple recipe card with just the key ingredients (like "more gold," "faster army," "better timing"). This recipe card is the "latent space"—a compressed, simplified version of the game.

2. The "Championship Model"

In sports science, coaches often study how champions train to help regular athletes improve. They look at the champion's path and say, "If you do what they do, you might win too."

  • The Analogy: Imagine a GPS. Usually, a GPS tells you the fastest route from Point A to Point B. But in this paper, the GPS is special. It knows where "Winning" is located in the map. If you are currently at "Losing," the GPS doesn't just show you the road; it draws a new, hypothetical road that connects your current location to the "Winning" zone, showing you exactly which turns to take.
  • The Paper's Goal: Instead of asking "Who will win?", the system asks, "What specific changes would make this player win?"

3. Drawing the Path (The Four Strategies)

Once the AI has the map, it needs to draw a line from the "Losing" point to the "Winning" point. The paper tested four different ways to draw this line, like four different types of hikers trying to get to the summit:

  • Linear Interpolation (The Straight Line): This is like walking in a perfectly straight line from the bottom of the mountain to the top. It's simple, but sometimes the terrain in between is rocky or doesn't exist in reality (like walking through a lake).
  • Iterative Optimal Transport (The Smart Hiker): This method is smarter. Instead of aiming for one specific spot, it looks at the whole "Winning" crowd and constantly adjusts its path to stay on solid ground, moving toward the densest part of the winning area. It's like following a river that naturally flows uphill toward the summit.
  • Gradient Ascent (The Climber with a Compass): This method uses a compass that always points toward "higher win probability." It climbs step-by-step, trying to get the steepest path up. The paper found this method is very good at finding a win, but sometimes it takes a weird, jagged path that doesn't look like a real human game.
  • Neural Flow (The River Current): This is the most advanced method. The AI learns how the "water" of the game flows naturally from losing to winning states and then rides that current. It creates a very smooth, realistic path.

4. The Result: Actionable Feedback

Once the path is drawn, the system translates the "recipe card" back into real game advice.

  • The Output: It gives the player a ranked list of changes. For example: "If you had spent 10% more money on workers in the first 5 minutes, and built your army 2 minutes earlier, your chance of winning would have gone from 40% to 80%."
  • The Catch: The paper tested this on data from amateur players (people who didn't play in the tournaments used to train the AI). They found that while some methods (like the "Smart Hiker" and "River Current") worked very well and stayed on realistic paths, others (like the "Climber") sometimes took shortcuts that didn't make sense in the real game.

Summary

The paper claims to have built a bridge between AI that plays games and AI that teaches humans how to play better. By using a "latent map" of professional gameplay, they can generate "what-if" scenarios. They don't just say "You lost"; they say, "Here is the specific, step-by-step path you could have taken to win, based on how champions actually play."

The authors conclude that while the technology works, there is a trade-off: some methods find a win faster but take unrealistic paths, while others stay realistic but might take longer to find the win. They hope this work inspires future tools that help human players improve by learning from the "ghost" of a perfect game.

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →