PO_BASE_STAKE

🦉 AthenaAI is an AI-powered ensemble machine-learning trading bot for PocketOption, built on BinaryOptionsToolsV2Get it on GitLab
💬 Need help? Join the Chipa Discord · ⚡ Go no-code with ChipaEditor

The minimum stake per trade, in dollars. Every computed stake is floored at this value, and it is also the stake used whenever the Kelly formula finds no edge.

Typefloat ($)
Default25.0
RequiredNo
Maps toBotConfig.base_stake
Read inmain.py (build_config())

What it does

build_config() parses it with float(env("PO_BASE_STAKE", "25.0")) — a non-numeric value raises ValueError and crashes at startup.

It is consumed in MoneyManager.compute_stake() (src/trading/money_manager.py), called from _trade_loop() in src/bot.py just before each trade with the model’s confidence, the running win rate, and an assumed payout of 0.85:

  1. If payout ≤ 0 or the Kelly edge (win_rate * payout - (1 - win_rate)) is ≤ 0, the function returns base_stake directly.
  2. Otherwise the stake is interpolated between the base and ceiling: stake = base_stake + kelly_fraction_scaled * (max_stake - base_stake).
  3. The stake is then multiplied by a confidence factor max(0.5, (confidence - 0.45) * 2.0) (60% conf → 0.50×, 70% → 0.80×, 75% → 0.95×).
  4. Finally it is clamped: max(base_stake, min(stake, max_stake)) and rounded to 2 decimals.

Because of the final clamp, no trade is ever smaller than PO_BASE_STAKE — even at the minimum-allowed confidence. The value is in your account currency (dollars); it is passed directly as the amount to client.buy() / client.sell().

Valid values

A positive number no larger than PO_MAX_STAKE, and at or above PocketOption’s platform minimum (typically $1). If you set base_stake > max_stake, the clamp max(base, min(stake, max)) resolves to base_stake — every trade uses the base and the ceiling is silently ignored.

Examples

export PO_BASE_STAKE=10
$env:PO_BASE_STAKE = '10'
# .env
PO_BASE_STAKE=25

Interactions

  • PO_MAX_STAKE is the other end of the Kelly interpolation.
  • kelly_fraction (0.50, config-only) scales the Kelly edge: kelly-fraction.
  • Losses accumulate against PO_MAX_DAILY_LOSS; a larger base stake reaches the daily stop in fewer losses.

Risk note: binary options trading can lose money, and past performance does not guarantee future results. The base stake is the smallest amount at risk on every single trade — size it against your account balance.

See also

💬 Unsure how this interacts with the rest of the configuration? Ask in the Chipa Discord — or prototype strategies no-code with ChipaEditor.