How AlphaLens hosting works
Understand the relationship between alphalens-core, local strategy execution, hosted sync, and Strategy Center.
alphalens-core is the local Python runtime. AlphaLens is the hosted product surface for sync, dashboards, telemetry, and monitoring.
That split is deliberate. Your strategy code, broker credentials, and order routing stay on your machine. AlphaLens receives normalized results and telemetry so you can inspect backtests and live deployments in the web app.
The model
| Layer | Runs where | Responsibility |
|---|---|---|
| Strategy code | Your machine | Signals, sizing, schedules, orders |
alphalens-core | Your machine | Backtest engine, live runner, broker integration, local cache |
| AlphaLens API | Hosted | API-key auth, run ingestion, market data proxy, telemetry ingestion |
| Strategy Center | Hosted | Standard Portfolio dashboard for backtests, paper deployments, and live deployments |
What AlphaLens hosts
AlphaLens hosts the parts that should be shared, searchable, and visual:
- API keys created from Settings.
- Backtest result sync.
- Strategy and run lists.
- Standard Portfolio dashboards.
- AlphaLens-authenticated market data endpoints.
- Live deployment telemetry.
- Heartbeat, signal, order, fill, and log views.
AlphaLens does not run your strategy process in v1. Start the local process with the CLI or Python API.
Standard Portfolio contract
Strategy Center renders strategies through the same Standard Portfolio model used by broker accounts.
| Source key | Meaning |
|---|---|
backtest:<run_id> | Historical backtest synced by alphalens-core |
deployment:<deployment_id> | Local paper/live runner emitting telemetry |
alpaca:<connection_id> | Direct broker account source |
snaptrade:<account_id> | SnapTrade account source |
This means the strategy dashboard should use the same concepts as the portfolio dashboard: NAV, returns, benchmark, positions, trades, orders, allocation, drawdown, rolling Sharpe, warnings, and reconciliation state.
Developer flow
- Build an
Algorithmsubclass. - Run local backtests.
- Sync promising runs to Strategy Center.
- Compare runs against benchmark and risk metrics.
- Start an Alpaca paper deployment.
- Monitor heartbeat, signals, orders, fills, and live equity.
- Move to live routing only after paper behavior is understood.
Choose your next guide
| Goal | Read |
|---|---|
| Run the first synced backtest | Quickstart |
| Understand strategy components | Build a strategy |
| Sync historical runs | Sync backtests |
| Start paper or live Alpaca | Live deployments |
| Use Python instead of the CLI | Python API |
| Configure env vars | Environment setup |