Publishing & sharing
Save a backtest run, make it public, and share it — how runs are stored, what the leaderboard and shared-run pages show, and the JSON caveat for profit factor.
Any backtest can be saved to your workspace and optionally published so others can see it.
What a saved run stores
Saving writes a row to the backtests table:
- config — the
BacktestConfigthat produced the run. - metrics — the full metrics object.
- equity_curve — the daily curve (sampled for storage).
- strategy_id — the saved strategy it came from, if any.
- is_public — whether it’s shared (defaults to private).
Everything is JSON-serializable by design.
Profit-factor caveat.
profitFactorcan be+Infinity(gains, zero losses), whichJSON.stringifyrenders asnull. Saving coerces non-finite values before persisting, so stored/leaderboard rows stay well-formed. See Metrics.
Making a run public
Set is_public on a run and it becomes readable by anyone. Row-level security enforces the rule: a backtest is visible if it’s public or you own it; only the owner can edit or delete.
The leaderboard
Public runs surface on the community leaderboard, which joins public backtests with public profiles and ranks by Sharpe ratio (also showing annualized return and max drawdown).
The leaderboard is a security-invoker view, so the underlying RLS still
decides visibility — it never exposes private runs. It’s also hardened against
malformed metrics: because metrics is user-controlled, values are parsed with
a safe numeric coercion so one bad row degrades to blank cells instead of
breaking the whole leaderboard. Details in the
data model.
Sharing a single run
Individual public runs render on a shared-run page (/runs/) showing
the configuration, metrics, and equity curve — a link you can send to anyone.