Poker Coach Engine
A small MCP math engine for a No-Limit Texas Hold'em Poker Coach Agent.
What it does
The MCP server exposes one tool: poker_analyze.
It can return:
- current hand class
- Hero equity versus a supplied Villain range
- fallback equity versus random opponent cards
- required equity / pot odds for a call
- call EV relative to folding
- SPR
- next-card hand-improvement outs
- board classification
- basic legal-action validation
It intentionally does not invent GTO frequencies or final strategy. Your Agent should combine this tool with its poker strategy / GTO knowledge base and opponent model.
Supported range notation (v0.1)
Examples:
AA
77,22,A7s,A2s,AQs,AJs
99+
AJs+
A5s-A2s
76s-54s
AKs
AKo
AK
AhKh
A5s:0.5
A5s:0.5 means the combo class is weighted at 50% when sampled.
Important input definition
pot_before_call means the pot already in the middle after Villain's current bet/raise has gone in, but before Hero calls.
Example:
- 38 BB is currently in the pot
- Hero needs 11 BB more to call
Use:
pot_before_call = 38
call_amount = 11
The required equity is 11 / (38 + 11) = 22.45%.
Local install
Requires Python 3.10+.
python -m venv .venv
# Windows: .venv\Scripts\activate
# macOS/Linux: source .venv/bin/activate
pip install -e .
Run the MCP server over stdio:
poker-coach-engine
Test the math modules
PYTHONPATH=src python -m unittest discover -s tests -v
On Windows PowerShell:
$env:PYTHONPATH="src"
python -m unittest discover -s tests -v
Build for PyPI
python -m pip install --upgrade build twine
python -m build
python -m twine check dist/*
Upload to TestPyPI first if desired, then publish to PyPI.
After it is public on PyPI, Alibaba Cloud Model Studio can launch a Python MCP package through uvx <package-name>.
Bailian MCP config
After publishing the package, use:
{
"mcpServers": {
"poker-engine": {
"type": "stdio",
"command": "uvx",
"args": [
"poker-coach-engine"
]
}
}
}
If PyPI says the package name is already taken, rename [project].name in pyproject.toml, publish using that new name, and put the same new name in the args array.
Safety / scope
This package performs poker math and simulation. It does not interact with poker clients, automate gameplay, obtain hidden cards, or bypass platform rules.
Metadata
Release files for poker-coach-engine 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| poker_coach_engine-0.1.0.tar.gz | 11.9 kB | Without provenance | Details for poker_coach_engine-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| poker_coach_engine-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for poker_coach_engine-0.1.0-py3-none-any.whl |
Total release size: 25.4 kB
Release files / poker_coach_engine-0.1.0.tar.gz
| Download URL | poker_coach_engine-0.1.0.tar.gz |
|---|---|
| Size | 11.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ba5f3b10dfa7f0a3479aae693e0a751ae25fe8a2eb875f01bbb07e6b790b2909
|
|
BLAKE2b-256 checksum How to use checksums |
5a1ff4fd092333e533f5f8af22d8f141d9e6381ed049c62885b8e0e3857f78c5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.1
|
Release files / poker_coach_engine-0.1.0-py3-none-any.whl
| Download URL | poker_coach_engine-0.1.0-py3-none-any.whl |
|---|---|
| Size | 13.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
0dc65a4a3e01afe13c63fb8aaf8f399cbdc25a65e2ea34ebdd9a6e75e58ac5a3
|
|
BLAKE2b-256 checksum How to use checksums |
c31107346c21ecd45b990b8a4f9e0f815ae1dc13b9ccde0c748c8700bcfcd0a5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.1
|
Security for poker-coach-engine 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.