Upload folder using huggingface_hub
Browse files54 unmodified lines555657585958596061621 unmodified line646566676768696970717172737475767778797778798081828384858586878788899091929389909192939495969597989910054 unmodified lines| Data | 200,000 deals || Steps | 50000, 1024 deals per step || Learning rate | 0.0003, cosine || Final loss | 1.2938 (table 0.7635), 0.667 of cells exact || Hardware | NVIDIA A10G, 81 min || Final loss | 2.7616 (table 0.8088), 0.648 of cells exact || Hardware | NVIDIA A10G, 118 min |
## 📊 Results
1 unmodified line
| MAE (tricks) | Exact | Within one | Whole table exact ||---|---|---|---|| 0.366 | 0.654 | 0.984 | 0.016 || 0.398 | 0.628 | 0.98 | 0.012 |
**Hands.** From one hand alone, the expected-table head is off by 0.345 tricks per cell on the 1000 test hands; guessing the average hand is off by 1.251.**Hands.** From one hand alone, the expected-table head is off by 0.346 tricks per cell on the 1000 test hands; guessing the average hand is off by 1.251.
**Hard pairs.** Hands with the same suit-length pattern and similar HCP look alike to a counting rule. Among them, for an anchor and two mates whose expected tables differ from the anchor's by more than half a trick, the embedding must rank the closer table first. Out of 98,216 triplets it gets 0.769 right; chance, and any rule that only counts points and cards per suit, gets 0.5.**Hard pairs.** Hands with the same suit-length pattern and similar HCP look alike to a counting rule. Among them, for an anchor and two mates whose expected tables differ from the anchor's by more than half a trick, the embedding must rank the closer table first. Out of 98,216 triplets it gets 0.901 right; chance, and any rule that only counts points and cards per suit, gets 0.5.
**Retrieval.** Each test hand is matched to its nearest other test hand; the score is the mean difference between their expected tables, in tricks, so lower is better. Deals are matched the same way on their exact tables, excluding deals that share the test hand; a deal's embedding is its four hand embeddings in seat order.
| Nearest by | Hands | Deals ||---|---|---|| Embedding | 0.836 | 1.788 || HCP and suit lengths | 0.613 | 1.411 || Random | 1.752 | 3.131 || Embedding | 0.55 | 1.277 || HCP and suit lengths | 0.616 | 1.412 || Random | 1.781 | 3.135 |

The test hands' embeddings, flattened with UMAP and coloured by expected notrump tricks with the hand declaring.
### Auxiliary weight### Training variants
The same model trained with three weights on the table and value heads, each on its own branch (`aux0`, `aux0.1`, `aux1`). `main` is `aux0.1`.The same model trained five ways, each on its own branch. `main` is `metric0.3`. The metric loss makes the embedding's similarity follow the distance between hands' expected tables (`--metric-weight`); the auxiliary weight scales the shape head (`--aux-weight`). Retrieval is the mean table distance to the nearest neighbour, so lower is better.
| Aux weight | Table MAE | Exact | Hard pairs | Hand retrieval | Deal retrieval ||---|---|---|---|---|---|| 0 | 0.365 | 0.655 | 0.775 | 0.826 | 1.775 || 0.1 | 0.366 | 0.654 | 0.769 | 0.836 | 1.788 || 1 | 0.380 | 0.642 | 0.776 | 0.845 | 1.793 || Branch | Aux | Metric | Table MAE | Exact | Hard pairs | Hand retrieval | Deal retrieval ||---|---|---|---|---|---|---|---|| `aux0` | 0 | 0 | 0.365 | 0.655 | 0.775 | 0.826 | 1.775 || `aux0.1` | 0.1 | 0 | 0.366 | 0.654 | 0.769 | 0.836 | 1.788 || `aux1` | 1 | 0 | 0.380 | 0.642 | 0.776 | 0.845 | 1.793 || `metric0.3` | 0.1 | 0.3 | 0.398 | 0.628 | 0.901 | 0.550 | 1.277 || `metric1` | 0.1 | 1 | 0.409 | 0.620 | 0.907 | 0.543 | 1.279 |
The weight barely matters here, and hard pairs do not collapse at any value. Retrieval by embedding is worse than by HCP and suit lengths at every weight.The auxiliary weight barely matters. The metric loss costs about 0.03 tricks of table accuracy and improves hard pairs from 0.77 to 0.90. Without it, retrieval by embedding is worse than by HCP and suit lengths; with it, it is better on hands (0.55 against 0.62) and on deals (1.28 against 1.41).
## ⚠️ Limitations
README.md+18-16