AI ENGINEERING
Gomoku AI
Gomoku AI is a complete implementation of the Gomoku board game (Pente ruleset) featuring a competitive artificial intelligence capable of playing against human opponents.
YEAR
2026
ROLE
Designed • Developed • Shipped
STACK
01/PROBLEM → SOLUTION
PROBLEM
A 19×19 board makes exhaustive search infeasible; a strict time limit requires the search to stop gracefully with the strongest move found.
SOLUTION
Candidate move generation near existing stones + alpha-beta pruning + a Zobrist-hashed transposition table cut the branching factor; a heuristic evaluator scores positions.
02/SYSTEM ARCHITECTURE
How the system fits together
- Player
- →Input Handler
- →Game Engine
- →AI Core
- →Move Generator
- →Evaluator
Drag to pan or Hover to trace or Click to inspect
03/KEY ENGINEERING DECISIONS
Candidate Generation
Search restricted to moves near existing stones cuts the branching factor while preserving move quality.
Alpha-Beta Pruning
Prunes provably-losing subtrees so effective depth rises without extra compute.
Transposition Cache
A 64-bit Zobrist fingerprint keys an O(1) cache of evaluated positions, avoiding redundant work.
04/IMPACT & TAKEAWAYS
Time-Boxed Search. Returns the strongest move found within the execution-time limit.
Pente Ruleset. Handles stone captures, capture-win, breakable five, and capture prevention in generation and evaluation.
Search Depth. Effective depth increased by pruning and caching.