POSTERIOR S2: Linientabelle (gedaechtnis-voll, HandHQ-Prior + NL2) eingelesen; Variante flussnur. Live-Hand 178593300919 mit echter Tabelle: Turn- und River-Fold

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-16 13:41:49 +01:00
co-authored by Claude Opus 5.5
parent 71a26f01cd
commit 90ff671f92
2 changed files with 10435 additions and 5 deletions
File diff suppressed because it is too large Load Diff
+11 -5
View File
@@ -65,6 +65,9 @@ pub struct Mode {
pub class_rate: bool,
/// S2 `bluff`: the bluff share of a villain's bet is a Beta posterior, see `bluff`.
pub bluff: bool,
/// `flussnur`: the line table only on the river (its flop/turn rows count only what reached a
/// showdown and lean to value).
pub river_lines_only: bool,
}
thread_local! {
@@ -93,7 +96,7 @@ pub fn mode() -> Option<Mode> {
}
fn parse(s: &str) -> Option<Mode> {
let mut m = Mode { fold: false, board_weight: 1.0, fold_only_branch: false, class_rate: false, bluff: false };
let mut m = Mode { fold: false, board_weight: 1.0, fold_only_branch: false, class_rate: false, bluff: false, river_lines_only: false };
for t in s.split(',').map(str::trim) {
if t == "fold" {
m.fold = true;
@@ -103,6 +106,8 @@ fn parse(s: &str) -> Option<Mode> {
m.class_rate = true;
} else if t == "bluff" {
m.bluff = true;
} else if t == "flussnur" {
m.river_lines_only = true;
} else if let Some(w) = t.strip_prefix("fold:").and_then(|w| w.parse::<f64>().ok()).filter(|w| w.is_finite()) {
m.fold = true;
m.board_weight = w;
@@ -283,7 +288,8 @@ pub fn bluff(seat: u8, street: Street, ratio: Option<f64>, line: Option<&Line>,
}
let ok = |x: Option<f64>| x.filter(|v| v.is_finite());
let raw = RAW.with(|x| x.borrow().iter().find(|(s, _)| *s == seat).map(|(_, p)| *p));
let population = match line.and_then(glaube_linie::lookup) {
let table_here = street == Street::River || !mode().is_some_and(|m| m.river_lines_only);
let population = match line.filter(|_| table_here).and_then(glaube_linie::lookup) {
Some((air, n)) => ((air + 0.5) / (n + 1.0)).min(MAX_BLUFF_SHARE),
None if street == Street::River => prior.min(POOL_RIVER_AIR),
None => prior,
@@ -339,9 +345,9 @@ mod tests {
#[test]
fn parses_the_stages() {
assert_eq!(parse("fold"), Some(Mode { fold: true, board_weight: 1.0, fold_only_branch: false, class_rate: false, bluff: false }));
assert_eq!(parse("fold:0.5,bluff"), Some(Mode { fold: true, board_weight: 0.5, fold_only_branch: false, class_rate: false, bluff: true }));
assert_eq!(parse("fold:0,nurfold"), Some(Mode { fold: true, board_weight: 0.0, fold_only_branch: true, class_rate: false, bluff: false }));
assert_eq!(parse("fold"), Some(Mode { fold: true, board_weight: 1.0, fold_only_branch: false, class_rate: false, bluff: false, river_lines_only: false }));
assert_eq!(parse("fold:0.5,bluff"), Some(Mode { fold: true, board_weight: 0.5, fold_only_branch: false, class_rate: false, bluff: true, river_lines_only: false }));
assert_eq!(parse("fold:0,nurfold"), Some(Mode { fold: true, board_weight: 0.0, fold_only_branch: true, class_rate: false, bluff: false, river_lines_only: false }));
assert_eq!(parse("0"), None);
assert_eq!(parse(""), None);
}