BridgeHand2Vec Bridge Hand Representation

Anna Sztyber-Betley, Filip Kolodziej, Piotr Duszak

TL;DR

Researchers have developed BridgeHand2Vec, a neural network-based embedding that maps a 13-card bridge hand into a compact 8-dimensional vector. By training on millions of "Double Dummy" simulations, the model learns a representation that captures hand strength and strategic potential, enabling "hand algebra" (e.g., swapping a Queen for an Ace) and significantly accelerating the training of reinforcement learning agents for bidding.

What Problem Does This Paper Address?

Contract bridge remains a "grand challenge" for AI because it combines imperfect information with the need for complex cooperation between partners. While AI has mastered games like Chess and Go, bridge bidding is still dominated by bots using rigid, human-designed rule sets.

A major hurdle is hand evaluation. How do you represent a hand to a machine? A simple binary vector (1 if you have the Ace of Spades, 0 if not) tells the computer what cards you have, but not how good they are in context. Previous attempts to estimate a partner's hand often failed because they didn't account for the "strength" or "shape" of the hand in a way that reflects actual gameplay. The authors sought to create a continuous vector space where hands with similar strategic value are physically close to one another.

Methods

The authors proposed a vectorization approach called BridgeHand2Vec. To create this representation, they trained a neural network to solve the DDBP2 problem: estimating the average number of tricks a pair can take in each suit (and No Trump) based only on the two partners' hands, assuming the opponents' cards are unknown but played optimally.

The Architecture: * Input: Two 52-element binary vectors representing the North and South hands. * Embedding Layer: The core of the paper. Each hand passes through shared-weight dense layers to produce an 8-element vector. * Normalization: They used batch normalization (without affine transformation) to ensure the vector components have a mean of 0 and a standard deviation of 1. * Prediction: These embeddings are concatenated and fed into further layers to predict the expected number of tricks.

To ensure the model didn't develop "suit bias" (e.g., thinking hearts are inherently better than spades), they used suit rotation data augmentation, effectively quadrupling their training data by rotating the suits of every hand.

Datasets

The researchers generated a massive dataset using the Bridge Calculator, a Double Dummy Solver (DDS).

  • Training Set: 400,000 initial hands, expanded to 3.2 million examples through hand-flipping (swapping N/S) and suit rotation.
  • Test Set: 200,000 boards.
  • Human Benchmark: They compared results against data from leading Polish bridge players who performed the same trick-estimation tasks under time pressure.

Key Insights and Ideas

  • The "Average" Hand is Zero: Because of the normalization, the zero vector $(0,0,...,0)$ represents the "average" bridge hand—typically a balanced 4-3-3-3 distribution with about 10-11 High Card Points (HCP).
  • Hand Algebra: Much like the famous "King - Man + Woman = Queen" in Word2Vec, BridgeHand2Vec supports strategic arithmetic. Adding a specific "difference vector" to a hand can effectively "swap" a low card for an Ace or change the hand's suit distribution while maintaining its relative position in the vector space.
  • Geometric Meaning: t-SNE visualizations show that the vector space naturally clusters hands by opening bid types (e.g., strong 1NT openings vs. weak passes) and HCP, even though the model was never explicitly told about these human-defined concepts.
  • Efficiency over Identity: The model learns that the identity of small cards matters far less than the presence of honors and suit length, which mirrors how professional players think.

Key Results

  • State-of-the-Art Performance: The model achieved SOTA results on the DDBP2 problem, outperforming previous neural network approaches and even beating expert human players (under time pressure) at estimating tricks for suit contracts.
  • RL Acceleration: In a reinforcement learning experiment for opening bids, an agent using BridgeHand2Vec embeddings learned significantly faster and reached a higher reward floor much earlier than an agent using raw binary card data.
  • Interpretable Distances: Using a simple K-Nearest Neighbors (KNN) classifier on the 8D vectors achieved 71.36% accuracy in predicting opening bids, proving the embedding captures the essential features used in human bidding systems like the "Polish Club."

Limitations and Future Work

While BridgeHand2Vec is a powerful analytical tool, the authors note it is not yet accurate enough to replace search-based solvers (like DDS) for precise analysis, as neural networks still struggle with the exact combinatorial math of card play.

Furthermore, the current model is trained on "Double Dummy" data, which assumes perfect information. Real bridge involves "Single Dummy" play, where players must navigate uncertainty and deception. Future work could involve refining these embeddings using real-world play data rather than simulations to better capture the nuances of defensive play and signaling.

Summary updated

BibTeX
@inproceedings{sztyberbetley2023bridgehand,
  author = {Anna Sztyber-Betley and Filip Kolodziej and Piotr Duszak},
  title = {{BridgeHand2Vec Bridge Hand Representation}},
  booktitle = {ECAI},
  year = {2023},
  doi = {10.3233/faia230526},
}

Loading related content...

Figure