Regret-Chess

CodeDay Fall 2026, Bengaluru(history) ∙ 
Permalink
♟ Regret Chess

You play White against a bot that plays Black and looks two moves ahead.
After each bot move, its journal says what it played, what reply it expects, and the three moves it almost played, with a reason for rejecting each. For example: “You’d answer Nxd5 and win my knight.”
On its next turn it looks back. It shows a “Regret” note if your reply made its position look worse than it thought, and a “thanks for the gift” note if you blundered.
Pawns count as 1.0 in the scores, shown from Black’s side.

How much experience does your group have? Does the project use anything (art, music, starter kits) you didn't create?

chess.js (open-source library) handles the rules, legal moves, and notation. We did not write our own move generator.
Three.js (open-source library) renders the 3D scene.
AI-generated code: a large part of the code was written with AI tools ([Gemini 4 Argon in Antigravity / AI Studio], and an earlier 2D prototype was built with Claude). We directed, tested, and edited it, but we did not write every line.
No outside art, music, or models. The pieces and board are built from code, and the sounds are synthesized in the browser.

What challenges did you encounter?

Making the explanations honest. The bot’s reasons had to come from real engine data, not made-up text. We had to compute tags like “loses a knight to the reply” from the actual best line.
Defining “regret.” We compare what the bot predicted against a deeper search after your reply, and tuning the thresholds took trial and error. [Add your numbers.]
Performance. The search runs in a Web Worker so the 3D scene doesn’t freeze. [Add what you hit with shatter effects or phones.]
Making 3D pieces look good. Procedural pieces, especially knights, needed several rounds of visual fixes
0
0
0
0
 
Participation Certificate

Members

SG