Inspiration
What if AI could make complex decisions while showing exactly why every conclusion was reached?
At TAMU Datathon 2026, we explored this question through casino analytics, probabilistic forecasting, competitive poker AI, and operational decision-making.
We discovered that generating predictions is often easier than proving they deserve to be trusted.
A slot machine can appear unprofitable because it has fewer operating hours, unusually large payouts, or a genuinely unexpected performance gap. Similarly, a poker agent can dominate simple strategies while consistently losing to a sophisticated opponent.
We built Pit Boss around one principle:
Every prediction should be explainable, every recommendation should be measurable, and every important decision should be supported by evidence.
Our flagship application, Gilded Ace, applies this philosophy to interactive casino-floor intelligence.
What It Does
Pit Boss combines four specialized systems with an evidence-grounded generative AI layer.
1. Gilded Ace — Casino-Floor Intelligence
Gilded Ace analyzes six months of simulated casino operations across 310 slot machines, examining revenue, theoretical returns, downtime, player activity, and financial interventions.
Rather than simply ranking machines by revenue, we calculate how far each machine's observed performance differs from its expected performance.
The core residual is:
$$ R_i = W_i^{\text{actual}} - W_i^{\text{theoretical}} $$
where:
- (R_i) is the machine's performance residual.
- (W_i^{\text{actual}}) is observed house win.
- (W_i^{\text{theoretical}}) is expected house win based on its game settings and wagering.
We standardize residuals to compare unusually large deviations across machines with different amounts of play:
$$ z_i = \frac{R_i}{\hat{\sigma}_i} $$
Because we evaluate hundreds of machines, we also apply the Holm multiple-testing correction to reduce false discoveries.
A Real Analytical Finding: M-1158
Machine M-1158 produced:
| Metric | Value |
|---|---|
| Actual house win | $15,796.25 |
| Theoretical house win | $51,961.00 |
| Performance residual | −$36,164.75 |
| Standardized residual | Approximately −4.46 |
| Holm-adjusted p-value | Approximately 0.0026 |
This made M-1158 a strong candidate for further investigation.
However, statistical significance does not prove an equipment defect. It indicates that the observed result is unusual under the statistical model.
Instead of recommending an expensive machine replacement, our conservative investment plan funds a $1,200 inspection from the available $100,000 budget:
$$ B_{\text{remaining}} = \$100{,}000 - \$1{,}200 = \$98{,}800 $$
The remaining capital stays available until stronger evidence supports additional spending.
The dashboard also supports interactive period, zone, machine-bank, and guest-tier filtering, allowing users to investigate changing conditions rather than relying on one static ranking.
2. Demand Forecasting and Financial Decisions
Gilded Ace forecasts casino-floor demand using a simple weekday-based model.
For a particular weekday (d), the prediction is calculated from historical observations for that weekday:
$$ \hat{y}{t} = \frac{1}{N_d} \sum{i \in \mathcal{T}_d} y_i $$
where (\mathcal{T}_d) contains training observations for weekday (d), and (N_d) is their count.
We train using January–April data and evaluate on May–June data, avoiding the use of future observations during training.
Forecast performance is measured using mean absolute error:
$$ \operatorname{MAE} = \frac{1}{n} \sum_{t=1}^{n} |y_t-\hat{y}_t| $$
Our documented results were:
| Forecast | Held-out MAE |
|---|---|
| Constant-mean baseline | $218,258 |
| Weekday-mean model | $68,699 |
This represents approximately a 68.5% reduction in MAE relative to the constant-mean baseline.
We also analyze the economic tradeoffs of potential interventions, including promotions, wayfinding, inspections, and technician staffing.
For a proposed intervention:
$$
\text{Net Benefit}
\text{Incremental Value Recovered}
\text{Intervention Cost} $$
Rather than treating assumed revenue improvements as guaranteed, we explicitly separate observed data from modeled intervention effects.
3. PitBossEquity — Competitive Poker AI
We developed PitBossEquity, an autonomous agent for heads-up, short-deck, five-card Pot-Limit Omaha.
The competition uses a 36-card deck. Each player receives five hole cards and must construct a final hand using exactly two hole cards and three community cards.
Our agent combines:
- Fast poker-hand evaluation.
- Monte Carlo equity estimation.
- Opponent continuing-range modeling.
- Position and betting-history analysis.
- Expected-chip-value action selection.
- Runtime-aware decision making.
A basic equity estimator is:
$$ \hat{p}{\text{win}} = \frac{1}{N} \sum{j=1}^{N} \mathbf{1}(\text{win in simulation }j) $$
For betting decisions, the agent evaluates the possible chip outcomes against the opponent's estimated range.
A simplified expected-value expression is:
$$ EV(a) = \sum_{s \in \mathcal{S}} P(s\mid a,\mathcal{H})\,U(a,s) $$
where:
- (a) is a candidate action.
- (\mathcal{H}) is observed betting history.
- (s) is a possible future game outcome.
- (U(a,s)) is its chip-value result.
One of our largest improvements came from replacing uniform assumptions about opponent hands with range-aware decision making.
We built a reproducible evaluation league against public tournament agents, using matched deals and controlled random seeds.
When an experimental preflop table improved some matchups but worsened others, we rejected it and preserved the more thoroughly tested champion.
Our goal was not simply to win against easy bots, but to measure whether strategy changes generalized to stronger opponents.
4. House Edge — Probabilistic Payout Forecasting
House Edge predicts the probability of five possible payout categories:
$$ Y \in {0,1,2,5,20} $$
For each query, the model returns a probability distribution:
$$
\mathbf{p}
(p_0,p_1,p_2,p_5,p_{20}) $$
subject to:
$$ \sum_{k\in{0,1,2,5,20}}p_k=1, \qquad p_k\geq 0 $$
We explored machine-level historical patterns, temporal dependencies, probability smoothing, and calibration.
Our latest documented main-round local validation score was 32.782/60, compared with 31.010/60 for an earlier version.
We also developed an adaptation-round model using shallow boosted trees, with a documented local kit validation score of 10.754/20.
The important engineering challenge was not only generating predictions, but ensuring that the outputs were reproducible, correctly formatted, and evaluated without overstating the strength of results selected on validation data.
5. Highway — Reliable Multi-Agent Operational Decisions
Our Highway system responds to simulated supply-chain and operational incidents.
Its architecture separates:
- Event interpretation.
- Policy-based planning.
- Authorized action execution.
- Post-execution verification.
A major safeguard is fail-closed identification.
If an event explicitly references a shipment or lot ID that does not exist, the system refuses to substitute an unrelated record.
Unconfirmed reports are escalated, while policy constraints govern resource allocation, loaner availability, notifications, and operational changes.
This reflects a broader design principle:
AI may propose an action, but deterministic rules must decide whether that action is permitted.
6. Gemini — Evidence-Grounded Generative AI
We integrated Google Gemini API, using gemini-2.5-flash, to explain verified analytical findings in natural language.
Rather than allowing Gemini to invent financial calculations, our pipeline follows this structure:
Question → Deterministic Calculation → Evidence Retrieval → Gemini Explanation → Citation and Numerical Validation
The model receives a restricted evidence package containing validated metrics and known source identifiers.
Its response is then checked for unsupported numerical claims and invalid evidence citations.
For example, we recorded a live Gemini explanation discussing why M-1158 merits inspection, referencing the existing analytical evidence while acknowledging that the deviation does not prove a physical defect.
The verified deterministic answer remains authoritative if a model call fails or produces unsupported claims.
We keep API credentials out of the publicly hosted frontend and do not expose unrestricted paid inference from the browser.
How We Built It
We organized Pit Boss as a modular repository containing independent competition submissions alongside shared analytical and integration infrastructure.
Our principal technologies were:
- Python — simulation, forecasting, poker strategy, operational rules, and API services.
- NumPy — vectorized numerical computation.
- DuckDB — local analytical data processing.
- HTML, CSS, and JavaScript — interactive Gilded Ace dashboard.
- Google Gemini API — evidence-grounded generative explanations.
- pytest — automated regression, integration, and security tests.
- Git and GitHub — source control and reproducible releases.
- GitHub Pages — public dashboard deployment.
- Cursor — development and debugging assistance.
We also developed optional integration adapters for Snowflake Cortex, Tiger Data, MongoDB Atlas, Vultr, Solana, and GoDaddy Registry. These were locally tested but are not represented as live cloud deployments without authenticated verification.
Challenges We Faced
Statistical Significance vs. Real-World Meaning
One of the hardest questions was distinguishing a statistically unusual machine from an actually defective one.
A low observed return can result from random variance rather than a configuration problem.
We had to account for theoretical returns, machine availability, different wagering volumes, and multiple comparisons before making a recommendation.
Poker Opponent Adaptation
Our original poker strategies performed well against simple baselines but struggled against sophisticated public agents.
We discovered that assuming an opponent holds a uniformly random hand badly misprices many decisions.
Modeling the opponent's continuing range improved our results, but testing against different seeds also showed that increased simulation accuracy does not automatically mean better strategy.
Hallucination-Resistant AI
Generative AI can produce fluent explanations containing unsupported numbers.
We addressed this by retaining deterministic calculations as the source of truth and requiring Gemini's supporting claims to correspond to known evidence.
Security and Integration Reliability
We had to prevent unsafe file access, reject invalid machine identifiers, secure API credentials, and ensure that a failed external model request did not alter an otherwise correct result.
We also learned that passing mocked integration tests and successfully connecting to a production provider are different achievements.
Accomplishments We're Proud Of
Our proudest accomplishment was applying the same evidence-first philosophy across several very different technical problems.
We built:
- An interactive analytical dashboard for 310 machines.
- A statistically justified machine-inspection recommendation.
- A demand forecast with substantially lower held-out error than its baseline.
- A range-aware poker agent evaluated against public competition bots.
- Reproducible probabilistic payout forecasting.
- A fail-closed operational decision workflow.
- A Gemini integration designed to reject unsupported financial claims.
Across these systems, we prioritized measurable improvement and correctness over impressive-looking but unverified complexity.
What We Learned
1. Data without context can be misleading. A raw revenue number means little without theoretical returns, exposure, and operating time.
2. Uncertainty should be visible. Statistical significance is evidence for investigation, not automatic proof of causality.
3. Strong testing requires strong opponents and appropriate baselines. Ordinary unit tests cannot establish competitive poker performance or forecasting generalization.
4. AI explanations need verifiable foundations. Generative reasoning is most useful when calculations and source evidence remain independently checkable.
5. Reproducibility is a product feature. Exact model versions, benchmark seeds, evidence identifiers, and protected submission artifacts make results more trustworthy.
What's Next
We plan to extend Gilded Ace with secure hosted analytical services, persistent investigations, richer time-series exploration, and additional independently verified cloud integrations.
For PitBossEquity, future work includes improved opponent-range calibration, more robust strategy selection, and broader complete-match evaluation.
For Gemini, we want to make the grounded analytical experience accessible through a secure, authenticated public interface without exposing credentials or compromising source-data integrity.
Ultimately, Pit Boss represents our central idea:
The best intelligent systems do not merely give answers. They show their work, quantify uncertainty, and know when the evidence is insufficient.