Initial commit: Hold'em engine, bots, and simulation harness
Kotlin Multiplatform engine (JVM target only for now; androidTarget and iosArm64 slot in without touching commonMain). Core: - HandEvaluator: single-pass 5-7 card evaluation, ~24M evals/sec. Verified exhaustively against published frequencies for all 2,598,960 five-card hands. - Equity: Monte Carlo with ties split. PreflopChart ranks the 169 starting hands using all-in equity plus an explicit playability adjustment, so looseness means "plays the top N%". - Table: no-limit betting rounds, side pots, odd-chip splits, uncalled-bet refunds, and incomplete (short all-in) raises that correctly do not reopen betting. Bots: - SkillLevel and PlayStyle are orthogonal axes. Skill drives decision quality (rollout accuracy, pot-odds discipline, position awareness, error rate); style drives bluffing, sandbagging, aggression, tightness. - BotMood gives tilt that persists between hands and decays. - OpponentModel lets Advanced/Expert exploit habitual bettors. - MathBot emits a DecisionTrace of the numbers behind each decision, which the coach will later hand to an LLM to narrate. The LLM never does poker maths. Simulator: - 2,200-3,400 hands/sec. Deck RNG is separate from bot RNGs so rollout counts cannot shift the deal. - Controlled skill-ladder test asserts the difficulty gradient is monotonic: 73.9 / 53.9 / 27.6 / -155.4 bb/100 over 50k hands. Assets: 52 CC0 English-pattern card faces plus generated backs. Tests: 30 passing (evaluator, table rules, pre-flop chart). Known open: win-rate magnitudes ~10x realistic and several profiles looser than their labels. Tuning, not correctness. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,101 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
version="1.1"
|
||||
width="360"
|
||||
height="540"
|
||||
id="svg20298">
|
||||
<defs
|
||||
id="defs20300">
|
||||
<inkscape:path-effect
|
||||
effect="spiro"
|
||||
id="path-effect17935-89" />
|
||||
<inkscape:path-effect
|
||||
effect="spiro"
|
||||
id="path-effect17939-8" />
|
||||
<inkscape:path-effect
|
||||
effect="spiro"
|
||||
id="path-effect17935-8-7" />
|
||||
<inkscape:path-effect
|
||||
effect="spiro"
|
||||
id="path-effect17939-6-0" />
|
||||
<inkscape:path-effect
|
||||
effect="spiro"
|
||||
id="path-effect17935-9-8-2-5-09-4-0" />
|
||||
<inkscape:path-effect
|
||||
effect="spiro"
|
||||
id="path-effect17935-9-8-2-5-09-4-1-8" />
|
||||
</defs>
|
||||
<metadata
|
||||
id="metadata20303">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title></dc:title>
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
transform="translate(-151.42857,-248.08929)"
|
||||
id="layer1">
|
||||
<g
|
||||
transform="translate(151.79257,-264.27289)"
|
||||
id="g3053-3">
|
||||
<rect
|
||||
width="359"
|
||||
height="539"
|
||||
rx="29.944447"
|
||||
ry="29.944447"
|
||||
x="0.5"
|
||||
y="512.86218"
|
||||
id="rect6472-57"
|
||||
style="fill:#ffffff;stroke:#000000;stroke-width:0.99999976" />
|
||||
<path
|
||||
d="m 20,542.36208 0,14.99999 0,5 10,0 c 2.77,0 5.00001,2.23 5.00001,5.00005 l 0,14.99996 c 0,2.77001 -2.23001,5.00001 -5.00001,5.00001 -2.77,0 -5,-2.23 -5,-5.00001 l 0,-4.99999 -5,0 0,4.99999 c 0,5.54 4.46,10 10,10 5.54001,0 10,-4.46 10,-10 l 0,-14.99996 c 0,-5.54005 -4.45999,-10.00005 -10,-10.00005 l -5,0 0,-9.99998 5,0 10,0 0,-5.00001 -10,0 -5,0 z"
|
||||
id="rect3163-6-0-0-2-66"
|
||||
style="fill:#ff5555;fill-opacity:1;stroke:none" />
|
||||
<path
|
||||
d="m 340,1022.3622 0,-15 0,-5 -10,0 c -2.77,0 -5.00001,-2.23 -5.00001,-5.00006 l 0,-15.00002 c 0,-2.77 2.23001,-5 5.00001,-5 2.77,0 5,2.23 5,5 l 0,5 5,0 0,-5 c 0,-5.54 -4.46,-10 -10,-10 -5.54001,0 -10,4.46 -10,10 l 0,15.00002 c 0,5.54006 4.45999,10.00006 10,10.00006 l 5,0 0,10 -5,0 -10,0 0,5 10,0 5,0 z"
|
||||
id="rect3163-6-0-0-2-4-5"
|
||||
style="fill:#ff5555;fill-opacity:1;stroke:none" />
|
||||
<path
|
||||
d="m 30,602.36218 c 0,0 3,7.5 6.5,12.5 3.5,5 8.5,10 8.5,10 0,0 -5,5 -8.5,10 -3.5,5 -6.5,12.5 -6.5,12.5 0,0 -3,-7.5 -6.5,-12.5 -3.5,-5 -8.5,-10 -8.5,-10 0,0 5,-5 8.5,-10 3.5,-5 6.5,-12.5 6.5,-12.5"
|
||||
id="path3204-24-1-82"
|
||||
style="fill:#ff5555;stroke:none" />
|
||||
<path
|
||||
d="m 330,917.36218 c 0,0 3,7.5 6.5,12.5 3.5,5 8.5,10 8.5,10 0,0 -5,5 -8.5,10 -3.5,5 -6.5,12.5 -6.5,12.5 0,0 -3,-7.5 -6.5,-12.5 -3.5,-5 -8.5,-10 -8.5,-10 0,0 5,-5 8.5,-10 3.5,-5 6.5,-12.5 6.5,-12.5"
|
||||
id="path3204-24-1-1-5"
|
||||
style="fill:#ff5555;stroke:none" />
|
||||
<path
|
||||
d="m 90,557.36218 c 0,0 6,15 13,25 7,10 17,20 17,20 0,0 -10,10 -17,20 -7,10 -13,25 -13,25 0,0 -6,-15 -13,-25 -7,-10 -17,-20 -17,-20 0,0 10,-10 17,-20 7,-10 13,-25 13,-25"
|
||||
id="path3204-24-7-4"
|
||||
style="fill:#ff5555;stroke:none" />
|
||||
<path
|
||||
d="m 270,557.36218 c 0,0 6,15 13,25 7,10 17,20 17,20 0,0 -10,10 -17,20 -7,10 -13,25 -13,25 0,0 -6,-15 -13,-25 -7,-10 -17,-20 -17,-20 0,0 10,-10 17,-20 7,-10 13,-25 13,-25"
|
||||
id="path3204-24-4-4"
|
||||
style="fill:#ff5555;stroke:none" />
|
||||
<path
|
||||
d="m 180,737.36218 c 0,0 6,15 13,25 7,10 17,20 17,20 0,0 -10,10 -17,20 -7,10 -13,25 -13,25 0,0 -6,-15 -13,-25 -7,-10 -17,-20 -17,-20 0,0 10,-10 17,-20 7,-10 13,-25 13,-25"
|
||||
id="path3204-24-16"
|
||||
style="fill:#ff5555;stroke:none" />
|
||||
<path
|
||||
d="m 90,917.36218 c 0,0 6,15 13,25 7,10 17,20 17,20 0,0 -10,10 -17,20 -7,10 -13,25.00002 -13,25.00002 0,0 -6,-15.00002 -13,-25.00002 -7,-10 -17,-20 -17,-20 0,0 10,-10 17,-20 7,-10 13,-25 13,-25"
|
||||
id="path3204-24-0-1"
|
||||
style="fill:#ff5555;stroke:none" />
|
||||
<path
|
||||
d="m 270,917.36218 c 0,0 6,15 13,25 7,10 17,20 17,20 0,0 -10,10 -17,20 -7,10 -13,25.00002 -13,25.00002 0,0 -6,-15.00002 -13,-25.00002 -7,-10 -17,-20 -17,-20 0,0 10,-10 17,-20 7,-10 13,-25 13,-25"
|
||||
id="path3204-24-9-6"
|
||||
style="fill:#ff5555;stroke:none" />
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 4.5 KiB |
Reference in New Issue
Block a user