XQSV: A Structurally Variable Network to Imitate Human Play in Xiangqi

Chenliang Zhou

TL;DR

Researchers have developed XQSV, a novel deep learning architecture designed to imitate human play in Xiangqi (Chinese Chess) rather than simply playing to win. By using a "structurally variable" approach that adapts its complexity to the player's skill level and simulating human cognitive limits like imperfect memory, the model achieves ~40% move prediction accuracy and proves indistinguishable from humans in a Turing Test.

What Problem Does This Paper Address?

While modern AI engines like AlphaZero and Stockfish have achieved superhuman performance in board games, they don't actually play like humans. They possess "perfect" memory, massive processing power, and a preference for moves that maximize winning probability—often resulting in playstyles that feel alien or frustrating to human opponents.

In Xiangqi, a game with a state-space complexity far exceeding Western Chess ($10^{150}$ vs $10^{123}$), there is a significant gap in research regarding human-centric AI. Creating an engine that mimics human behavior is vital for developing more enjoyable training partners, providing relatable strategic advice, and building robust evaluation functions that understand human mistakes.

Methods

The authors introduce the Xiangqi Structurally Variable (XQSV) network. Its design is rooted in four key innovations:

  1. Elo Range Partitioning: Instead of one-size-fits-all, the data is split into bins based on player skill (Elo). The model's architecture actually changes (becomes more complex) as the skill level of the target group increases.
  2. Sequential 1D Input: Most chess AIs look at 2D board snapshots. XQSV uses a linear sequence of moves. Interviews with players revealed that humans often deliberate based on the "flow" of recent moves rather than just the current visual configuration.
  3. Imperfect Memory Capacity: To simulate human cognitive constraints, the model is restricted to seeing only the last m moves. This prevents the AI from making decisions based on "perfect" recall of the entire game history.
  4. Locally Illegal Move Filter: Because the model predicts moves based on history rather than a board state, it might occasionally suggest an "illegal" move (e.g., moving a piece that isn't there). A post-processing filter ensures all predicted moves are legal in the current game state.

The core architecture is a Recurrent Neural Network (RNN), specifically using LSTM or GRU layers, which are better suited for sequential data than the standard Convolutional Neural Networks (CNNs) used in winning-oriented engines.

Datasets

The model was trained on raw Xiangqi game data retrieved from PlayOK.com in Standard Algebraic Notation (SAN).

  • Partitioning: The data was divided into nine distinct bins based on Elo scores, ranging from (1000, 1100] to (1900, 2000].
  • Evaluation: The model was tested against human game records and compared against a standard mobile Xiangqi app in a Turing Test.

Key Insights and Ideas

  • Complexity Scales with Skill: The "Aha!" moment in the paper is that higher-skilled players require more complex neural architectures to imitate. Advanced players use "perceptual chunks" and abstract relations, necessitating larger memory capacities and deeper networks (e.g., LSTMs vs. simpler GRUs) to model.
  • Sequences over Snapshots: Moving away from 2D board representations to 1D move sequences significantly improved accuracy. This suggests that the "history" of the battle is more predictive of the next human move than the current state of the board alone.
  • The "Human" Decline: When a model trained on high-Elo players is tested on low-Elo games, its accuracy drops. However, the drop is less severe than the reverse. This suggests advanced players can emulate novice strategies, but novices cannot easily replicate the nuanced moves of experts.

Key Results

  • Predictive Accuracy: XQSV achieved approximately 40% accuracy in predicting the exact next move made by a human. While this sounds low, it is comparable to state-of-the-art human-imitation models in Chess (like Maia).
  • Turing Test Success: In a "three-terminal" Turing Test, 30 human players played against other humans, XQSV, and a standard mobile app.
  • XQSV was identified as human 38.89% of the time—the exact same rate as actual human players.
  • The standard mobile app was correctly identified as a machine 77.78% of the time.
  • Relaxed Metrics: When using "Top-5" accuracy (checking if the human move was among the model's top 5 choices), the accuracy jumped to 62.30%, highlighting the non-deterministic nature of human play.

Limitations and Future Work

The authors acknowledge that their model is currently deterministic—given the same history, it will always predict the same move. However, humans are non-deterministic and might choose different moves in identical situations. While the authors proposed "Top-p" probability metrics to account for this, the model itself doesn't yet incorporate "personality" or specific playing styles (e.g., aggressive vs. defensive).

Future work could involve integrating personal traits into the network to allow it to imitate specific famous players or individual users more closely.

Summary updated

BibTeX
@inproceedings{zhou2024xqsv,
  author = {Chenliang Zhou},
  title = {{XQSV: A Structurally Variable Network to Imitate Human Play in Xiangqi}},
  booktitle = {Cog},
  year = {2024},
  doi = {10.1109/cog60054.2024.10645635},
}
Figure