# alias: PlayTopTricksNT # button-text: Top Tricks (NT) # gib-works: true # bba-works: true # auction-filter: \[Deal .* .* .* .*\..*\..*\.*[789] # curate: kind=byforce # convention-card-ns: Basic-Bridge # convention-card-ew: Basic-Bridge /*@chat --- Top Tricks — Notrump Contract (beginner) 1NT — Pass — 3NT — all pass. Final contract is 3NT (declarer needs 9 tricks). Teaching feature: NS holds all 4 aces (in either hand) AND exactly 9 quick tricks on top. We assume outside entries exist, so split chains DO count (e.g., AK opposite Qxx = 3 QT). The per-suit count is capped by the longer single-hand length in that suit (so AK opposite Qx = 2 QT, since no hand has 3 cards in the suit). Responder is constrained to no 4-card major (so no Stayman) and no 5-card major (so no transfer). The auction stays natural 1NT—3NT. Things to think about: • Count your top tricks before touching the hand. • Chain rule: A, then K (anywhere in NS), then Q, then J, then T. • Length cap: split chains need length in the longer hand to materialize. Reference: https://www.bridgebum.com/counting.php @chat*/ dealer south // Predeal one ace to each hand to guarantee an entry to declarer and dummy // and to slash the all-aces rejection rate (the dominant yield killer). The // other two aces (HA, CA) are still required in NS by allSuitsStopped in // script/topTricksNS, but roam between the hands for variety. predeal south SA predeal north DA #include "script/topTricksNS" // Provides topTricksSpades, topTricksHearts, topTricksDiamonds, topTricksClubs, topTricksNS #include "script/Leveling" // Provides keep015 (~1.5%), keep06 (~6%), keep (=1) — used to balance the // pass / 2NT / 3NT cases against each other. // ----- Opener (South) — 1NT, 15-17, balanced (Basic-Bridge shape) ----- sShape = shape(south, any 4333 + any 4432) sHcp = hcp(south) > 14 and hcp(south) < 18 // ----- Responder (North) — no 4-card major, no 6+ suit, no 5-5 ----- nNoMajor4 = spades(north) < 4 and hearts(north) < 4 nShape = shape(north, xxxx -any 7xxx -any 6xxx -any 55xx) // Quiet opponents eHcp = hcp(east) < 11 wHcp = hcp(west) < 11 # Define responder's three action paths, with Leveling factors to balance # the natural rates (Pass ~7.2%, 2NT ~2.2%, 3NT ~90.6%) toward roughly # equal distribution. 2NT is the rarest path; reduce Pass and 3NT to match. nPass = hcp(north)<9 and topTricksNS == 7 and keep30 n2N = hcp(north)==9 and topTricksNS == 8 and keep n3N = hcp(north)>9 and hcp(north)<15 and topTricksNS >= 9 and topTricksNS <= 11 and keep03 nActs = nPass or n2N or n3N // Ground-truth marker for the play trainer / grader: West's club spot // cards encode the top-trick count without affecting bidding or play. // 7C only (no 8C, no 9C) → exactly 7 top tricks (Pass) // 8C only (no 7C, no 9C) → exactly 8 top tricks (2NT) // 9C only (no 7C, no 8C) → 9+ top tricks (3NT) nsMarker = (topTricksNS == 7 and hascard(west, 7C) and not hascard(west, 8C) and not hascard(west, 9C)) or (topTricksNS == 8 and not hascard(west, 7C) and hascard(west, 8C) and not hascard(west, 9C)) or (topTricksNS >= 9 and not hascard(west, 7C) and not hascard(west, 8C) and hascard(west, 9C)) // nActs encodes the three responder paths (Pass / 2NT / 3NT). Each path's // topTricksNS check implicitly requires all 4 aces in NS in the 2NT and // 3NT cases (see script/topTricksNS — it collapses to 0 if any suit is // unstopped). sShape and sHcp and nNoMajor4 and nShape and nActs and eHcp and wHcp and nsMarker action average "North Pass " 100 * nPass, average "North 2NT " 100 * n2N, average "North 3NT " 100 * n3N, average "top tricks " topTricksNS, average "South HCP " hcp(south), average "North HCP " hcp(north),