CLI flag definitions

CLI flag definitions

Generated from the current CLI flag definitions. See the usage guide for command examples and configuration rules.

algo cache

FlagTypeDefaultMeaning
--cache-dirString""bar-series cache directory (default: $HOME/algolang/cache)

algo report

FlagTypeDefaultMeaning
--formatString"text"output format: text|json
--outString""directory to (re)write portfolio artefacts under (as /portfolio/)
--partialBoolfalsecombine whatever run directories exist (a fail-fast run set leaves no index.json)
--risk-free-rateFloat640annual risk-free rate for the recomputed portfolio Sharpe (default: the first run’s recorded rate)
--runsString""comma-separated run ids to include (default: every run in index.json)

algo run

FlagTypeDefaultMeaning
--accept-degraded-seamsBoolfalsecontinuous futures: trade across a served roll seam whose pair is a fallback (degraded) instead of refusing the run; recorded in degradation.json and the manifest pin
--adapterString""path to the data adapter binary (required)
--adapter-inputsString""adapter input values: k=v[,k=v…]
--auto-lineageBoolfalsefollow each configured equity symbol’s rename chain FORWARD and auto-discover its successor tickers (fetch their bars + corporate actions and run the whole lineage from one head ticker)
--bar-intervalString""with –config: override every run’s bar interval
--bar-kindString"time"bar construction kind: time|volume|tick|dollar|range|renko|imbalance_tick|imbalance_volume|imbalance_dollar|streak|vwap_anchor|runs_tick|runs_volume|runs_dollar
--batch-sizeInt4096records per data response envelope
--bracket-ambiguityString"conservative"same-bar bracket ambiguity convention: conservative|optimistic|path_direction (Section 6.5.3)
--cacheString"on"bar-series disk cache: off|on|refresh
--cache-dirString""bar-series cache directory (default: $HOME/algolang/cache)
--calendar-accept-unverifiedString""comma-separated roots whose unrecorded session eras precise-time admission accepts (decision D-I11-4)
--calendar-margin-quartersInt0calendar quarters past the run’s last bar the exchange-calendar fetch reaches (0 = the default, 2)
--calendar-revisionsString""exchange-calendar pins: root=revision[,root=revision…]; a served revision that differs, or no calendar for a pinned root, refuses the run (calendar_pin_drift)
--capitalFloat64100000fill simulator: starting cash
--commission-per-orderFloat640fill simulator: flat commission per fill
--commission-per-shareFloat640fill simulator: commission per share/contract
--configString""path to a run-config JSON file (one run = one strategy instance; excludes the single-run flags)
--continuous-clockString""continuous futures: session (default) reads the feed’s trade-date session composite for a 1d/1w series (under –session, or eth when none is given) and epoch buckets for an intraday interval; epoch reads UTC epoch buckets at every interval and takes no session
--data-protocolString"auto"data wire protocol: auto|dbn|pb|csv
--date-fromString""with –config: override every run’s start date (YYYY-MM-DD)
--date-toString""with –config: override every run’s last date, inclusive (YYYY-MM-DD)
--deploymentString""with –mode live: the ledger’s deployment label (1-40 characters from [A-Za-z0-9_]; empty = algo); every order reference (the IBKR cOID) is
--endString"2100-01-01T00:00:00Z"range end (RFC 3339)
--ewma-span-barsFloat640expectation mode: EWMA span (bars) for the expected bar size
--ewma-span-signalFloat640expectation mode: EWMA span (bars) for the signed-rate estimate
--exchange-calendarBoolfalsefetch the exchange calendar of every root the run reads (pb data wire), push it to a strategy that asks for it and record it in the run’s provenance (result.json, –fills-json, –lifecycle-json); a strategy that sets needs_calendar turns this on by itself
--fills-jsonString""backtest only: write the run’s fill blotter (all simulator fills + summary equity) to this JSON path — the golden-master parity seam
--gtc-expiryString"never"fill simulator: venue GTC termination model: never (a GTC order rests until filled, cancelled or the run ends) | ibkr-quarter (cancelled, reason gtc_expired, before the first bar whose trade date falls after the end of the calendar quarter following its submission’s trade date); a live venue applies its own rule
--include-pathBoolfalserequest the intra-bar path (BARS_TIME only; serves_path adapters): the finer bars each coarsened bar was built from, used to simulate fills at bar resolution
--init-expected-sizeFloat640expectation mode: expected-bar-size seed
--init-signed-rateFloat640.5expectation mode: signed-rate seed, in [0,1]
--initial-capitalString""with –config: override the capital pool (e.g. USD100000), reallocated by capital-units
--inputsString""strategy input values: k=v[,k=v…]
--intervalString"1m"bar interval: 1s/5m/1h/1d style (–bar-kind time only)
--lead-inDuration0event bars: constructor warm-up; the adapter feeds trades from start minus this and discards the bars that close before start (0 = none)
--ledgerString""with –mode live: the order-ledger file (startup reconciliation + canonical-id store, designspec §11.3)
--ledger-migrationString""with –mode live: accept a ledger written before deployment identity existed (every reference c-): exclusive-owner asserts no other deployment on the account allocated references under that prefix; empty refuses such a ledger
--lifecycle-jsonString""backtest only: write the run’s order lifecycle trace (submissions in both frames, cancel requests, every venue fill and cancel, rolls, the working set before shutdown, and the fill blotter) to this JSON path
--lifetimeString"v1"order lifetime profile: v1 (legacy: every exchange as before) | v2 (GLE-200: the strategy must accept lifetime-v2; every submission is acknowledged with an OrderUpdate, every cancel request answered with a CancelResponse, and lifecycle turns are granted per instant; backtest and emulated-live, non-continuous strategy runs only in this release)
--lifetime-hold-timeoutDuration0with –lifetime v2: how long the admission race guard holds an order behind a pending cancellation before rejecting it (hold_timeout), on the run’s event clock (0 = the default, 5m)
--lifetime-turnsInt0with –lifetime v2: lifecycle turns granted per instant (0 = the default, 3)
--limit-fillString"conservative"limit fill rule: conservative (trade-through at tick resolution) | through (trade-through at every resolution) | optimistic (touch; diagnostic only)
--max-order-quantityInt640with –lifetime v2: the admission policy’s limit on the quantity of one order and of each attached order (cap_quantity; 0 = no limit)
--max-positionInt640with –lifetime v2: the admission policy’s limit, either way, on the position each symbol could reach if every working and held order executed (cap_exposure; 0 = no limit)
--max-submissionsInt0with –lifetime v2 and –submission-window: the admission policy’s budget of new orders per window of event time (rate_budget; 0 = no budget)
--max-symbol-working-ordersInt0with –lifetime v2: the admission policy’s limit on the working orders on each symbol, counted as –max-working-orders counts them (cap_symbol_working_orders; 0 = no limit)
--max-working-ordersInt0with –lifetime v2: the admission policy’s limit on the instance’s working orders, held, pending-cancel and unknown ones and labelled attached orders included (cap_working_orders; 0 = no limit)
--modeString"backtest"run mode: backtest (in-process fill simulator) | live (IBKR VenueAdapter over HTTP)
--on-orphanString"exit"with –mode live: the match_ledger orphan policy (only exit is in scope: refuse-to-start on an unexplained broker order)
--path-heuristicString""bar-resolution fill assumption: legacy (the old engine’s O->H->L->C walk, branch bug reproduced) | midpoint (open’s half of the range picks the leg order); empty = single ambiguous OHLC interval
--path-intervalString""named granularity for the intra-bar path constituents (“1s”, “1m”, …); implies –include-path and is exact-or-refused: the adapter serves exactly this granularity or the run fails
--replicateInt1total copies of the fetched bars to run
--reportString"on"performance report: on prints the performance block after each backtest run (and, with –results-dir, writes result.json/equity.csv/trades.csv); off restores the pre-report output
--results-dirString""directory for per-run artefacts: every backtest run writes //{result.json,equity.csv,trades.csv} (report on), a continuous run adds manifest.yaml/audit.jsonl, and the run set writes index.json (empty: write nothing)
--reversal-multFloat640renko reversal as a multiple of the brick size (default 2.0)
--risk-free-rateFloat640performance report: annual risk-free rate for the Sharpe ratio, as a decimal (0.04 = 4%)
--roll-tradesString"stitch"performance report, continuous runs: pair trades across contract rolls as one economic round trip (stitch) or per contract leg (split)
--run-idString""run identifier (default: deterministic run--)
--schemaString"BARS"BARS or TRADES (TRADES = data-plane benchmark, no strategy)
--sessionString""trading-day bar container for 1d/1w series: eth|rth|session (empty: epoch bars); with an intraday interval, eth|rth|session|utc-day selects a session-anchored grid (bars restart at each window open, the last is cut at the close); with –config, overrides every run’s session
--simulation-resolutionString"auto"fill simulation path resolution: auto|tick|bar (tick replays each bar’s trades)
--slippage-ticksFloat640fill simulator: adverse slippage on market-style fills, in ticks (multiplied by each traded symbol’s tick size)
--startString"1970-01-01T00:00:00Z"range start (RFC 3339)
--strategyString""path to the strategy binary (required unless –schema TRADES)
--strategy-protocolString"auto"strategy wire protocol: auto|pb|csv
--strict-calendarBoolfalserequire a pinned, served exchange calendar (–calendar-revisions) for every symbol the run reads (calendar_pin_drift)
--submission-windowDuration0with –lifetime v2 and –max-submissions: the window of event time the submission budget covers (0 = no budget)
--symbolString""deprecated alias for –symbols with a single symbol
--symbolsString""comma-separated instrument symbols (required); ONE instance receives every symbol’s series
--thresholdFloat640activity-bar close threshold (static mode; the kind’s unit)
--threshold-modeString"static"imbalance/runs threshold mode: static|expectation
--transport-queueInt0with –lifetime v2, live: the most submissions the transport scheduler queues; a submission that finds the queue full is refused (transport_overload; 0 = the default, 100)
--transport-requestsInt0with –lifetime v2, live: the transport scheduler sends at most this many submissions and cancel requests to the venue within any –transport-window of the run’s operational clock, queued cancel requests first (0 = the default, 5)
--transport-windowDuration0with –lifetime v2, live: the window –transport-requests covers; also the pause after the venue refuses a request for pacing (0 = the default, 1s)
--venue-accountString""with –mode live: the IBKR account id (empty resolves from the venue)
--venue-emulatedBoolfalsewith –mode live: drive the deterministic emulator clock via POST /admin/tick (vs a real-time gateway feed)
--venue-reply-allowString""with –mode live: comma-separated IBKR order reply message ids the venue confirms; any other reply is declined and its order denied (reply_declined) with IBKR’s text; none confirms no reply; empty = the default, o10151,o10152,o10153,o10331,p12
--venue-urlString""with –mode live: the IBKR gateway / emulator base URL
--verifyBoolfalsewith –config: validate the file, run every check a run makes before its first bar (adapter capabilities, coverage, the grid probe) without fetching bars or trades, print the plan, and exit non-zero if any run would fail