Documentation for Deptle Terminal.

Guides for setup, scripting, troubleshooting, and more.

Return Model

Return an Order.*(...) value from on_tick. If you do nothing, the strategy simply holds.

  • Order.Hold().
  • Order.Close().
  • Order.Buy(...) / Order.Sell(...).
  • Order.Score(value=...) for score-emission workflows.

Buy / Sell Semantics

Use clear quantity and price inputs so your orders behave the way you expect.

  • Quantity argument can be positional or keyword quantity=.
  • Whole-unit quantity uses i64 (quantity=1).
  • Fractional quantity should use fixed-point helpers (quantity=base(0.25) or as_base(...)).
  • For i64 quantity, emitted base quantity is scaled by 10^base_scale (default 10^8).
  • limit_price= expects fixed-point i64; literal floats are accepted and scaled, dynamic float expressions are rejected.
  • limit_price <= 0 is treated as market (limit ignored).
  • reduce_only= expects bool.
  • quantity <= 0 resolves to hold action at runtime.
orders.py
1class Exec(Strategy):
2 def on_tick(self, tick):
3 q = base(0.05)
4 lp = price(42000.5)
5 if tick.price < lp:
6 return Order.Buy(quantity=q, limit_price=lp, reduce_only=False)
7 return Order.Hold()

Score Orders

Use Order.Score when your strategy should rank ideas instead of placing an order directly.

  • Accepted keywords: value, score, or quantity (aliases for the same payload).
  • Score must resolve to i64 (cast with int(...) when needed).

Optimizer CPU backend currently rejects portfolio context ops and Order.Score; use Auto/CUDA for those strategies.

Need help?

If launch fails, include your loader version, OS, and latest crash log so support can reproduce the issue quickly.

Check service status