Skip to content

feat(article): add blackjack README table intro - #14

Merged
kanywst merged 1 commit into
mainfrom
article/blackjack-readme-table
Oct 15, 2026
Merged

kanywst merged 1 commit into
mainfrom
article/blackjack-readme-table

Conversation

@kanywst

@kanywst kanywst commented Oct 15, 2026

Copy link
Copy Markdown
Member

Intro article for 0-draft/blackjack, written as the exposure step from the 2026-10-15 archive check (kanywst/bellman#317).

  • published: false with date: 2026-11-15T00:00:00Z, so merging schedules it: schedule.yml flips it live at that time. Change or drop the date before merging if you want it held.
  • The quoted issue comment is the real one from hand 12 (bj|bet 1 12 blackjack#3), dealt on 2026-10-15 to verify blackjack.yml after the move. The mechanics described (hole card drawn only on reveal, peek roll, composition-based pricing, the three calculator checks) are taken from scripts/blackjack.py, scripts/bjmath.py and tests/test_bjmath.py.
  • markdownlint-cli2 passes with both the global and repo config. validate_articles.py: 0 errors, 2 warnings (no cover_image; the single-article series warning, which also fires on feat(article): add identity-deep-dive radar intro #13 although ShowDev has 24 articles).

@coderabbitai

coderabbitai Bot commented Oct 15, 2026

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration
  • Configuration used: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 622506a6-b15f-445c-ae92-738edf91a298
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

A wrong board is visible. A wrong expected value just quietly tells strangers that the worse play was better. So the calculator is checked three ways in `tests/test_bjmath.py`:

1. **Against an independent Monte Carlo** that deals a real shuffled shoe with a physical hole card and rejection sampling for the peek. It shares no code with the calculator.
2. **Against the published basic strategy chart.** All 260 cells have to fall out of the numbers from a full shoe, without the calculator ever being told what the chart says.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"All 260 cells" reads as recalled. A standard six-deck basic strategy chart is usually 10 dealer upcards × (hard + soft + pair rows), which gives a different total depending on which rows you count (e.g. 280 with hard 5–17, soft A2–A9, pairs 22–AA). Please check this against the chart tests/test_bjmath.py actually uses and state which chart it is (source, and S17/DAS/late-surrender variant).


When that chip went down the running count was +0 with 4.9 decks left,
so the true count was +0.0. A shoe like that is worth about -0.12% a unit,
measured over 200 million rounds of these rules, so 1u on it was worth

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The "-0.12% a unit" edge at true count 0 and the "200 million rounds" figure are presented as measured results, but nothing in the article or repo points to where they come from. A true-count-0 edge for these rules is commonly quoted around -0.4% to -0.5% for six decks, so -0.12% needs a source or a note on how it is defined (per initial bet, conditional on count bucket, etc.). Also, "+0 running count with 4.9 decks left" giving a true count of exactly +0.0 is fine, but the example then prices 1u at -0.001, which is -0.12% of 1u rounded; say so or the sample looks inconsistent.

A strategy chart answers "what is best on average over a fresh six-deck shoe". That is the wrong question halfway through a shoe. `bjmath.py` works in compositions (how many aces, twos, ..., tens remain) and enumerates every outcome, so each action is priced for this shoe and no other:

- Cards are drawn without replacement all the way down, including the dealer's.
- The calculator is never allowed to see the hole card. Enumerate it, take the best action inside each branch, and sixteen against a ten starts "standing when the dealer has sixteen", a quarter of a unit no player can collect. Every decision is averaged over the hole cards the player cannot tell apart.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This sentence is garbled: "sixteen against a ten starts 'standing when the dealer has sixteen'" does not parse, and "a quarter of a unit" is an unsourced number. Rewrite to say what actually happens (an optimiser that sees the hole card picks stand/hit per hole card and overstates the EV of 16 vs 10 by about X units) and give the measured X from the calculator.

- githubactions
- gamedev
series: ShowDev
date: '2026-11-15T00:00:00Z'

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Compare with the sibling ShowDev articles (e.g. shogi-on-github-profile.md): they carry a cover_image under articles/assets/<slug>/ (see README "Assets", 1000x420 via scripts/gen_cover_image.py). This one has none. Also confirm the future date: (2026-11-15) is intended; with published: false the hourly scheduler will flip it publicly at that time.

@claude

claude Bot commented Oct 15, 2026

Copy link
Copy Markdown

New article articles/blackjack-readme-table.md. No workflow or script changes, no injection surface in the diff, and no EN/JA parity issue (JA copies are gitignored under articles/JA/).

Findings, all factual or housekeeping:

  • Line 75: "All 260 cells" of the basic strategy chart looks recalled. The total depends on which rows are counted, and the chart and rule variant are not named.
  • Line 42: the -0.12% edge at true count 0 and "200 million rounds" are unsourced. Commonly quoted six-deck edges are larger in magnitude, so this needs a definition or source.
  • Line 63: the "sixteen against a ten" sentence is garbled and "a quarter of a unit" is unsourced.
  • Line 11: no cover_image, unlike the sibling ShowDev articles. Also confirm the scheduled 2026-11-15 date is intended.

I did not run validate_articles.py locally; CI covers it.

@kanywst
kanywst merged commit e79d292 into main Oct 15, 2026
3 checks passed
@kanywst
kanywst deleted the article/blackjack-readme-table branch October 15, 2026 14:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant