openpql-runner 0.1.3

A high-performance Rust implementation of Poker Query Language (PQL), enabling SQL-like queries for poker analysis and calculations. This project is a spiritual successor to the original Java implementation developed by Odds Oracle.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
use super::*;

#[pqlfn]
pub fn fractional_river_equity(
    ctx: &PQLFnContext,
    hero: PQLPlayer,
) -> PQLFraction {
    let idx_board = PQLFnContext::idx_board_start(
        ctx.n_players,
        ctx.game.player_cards_len(),
    );
    let player_cards = &ctx.sampled_cards[..idx_board];
    let board = ctx.get_board(PQLStreet::River);

    core::fractional_river_equity(ctx.game, board, player_cards, hero.into())
}