Getting started with Lona
Create a strategy from a plain-language idea, run a backtest, and review the result. You do not need to write code.
Create your first strategy
1. Start a chat
Open New Chat and describe the trading behavior you want to test. Include the entry, exit, and risk rules you already know.
For example:
Create a moving-average crossover strategy. Enter long when the 10-period moving average crosses above the 30-period moving average. Exit when it crosses below.
Lona asks questions when the idea needs more detail.
2. Review the rules
The Canvas records Lona’s current understanding under Identified rules. Check the indicator settings, entry conditions, exit conditions, and risk rules. Continue the conversation if something is missing or incorrect.
3. Lona builds the strategy
An available model is selected by default. When Lona has enough information, it automatically records the identified rules, generates Backtrader code, and checks that the code can run. You can choose a different available model from the chat input before sending a message.
When generation finishes, the Canvas shows the code and an explanation. You can review the code, edit it directly, or ask Lona to revise the strategy.
4. Configure the backtest
Select Run Backtest below the assistant message or New Backtest in the Canvas. Complete the four sections in Configure Backtest:
- Name — enter a strategy name and, optionally, a run name.
- Select data — choose Lona data or custom data, then select up to five symbols.
- Strategy parameters — choose a frequency and date range supported by every selected symbol.
- Simulation — review initial cash, commission, leverage, and order timing.
Select Run Strategy. Lona saves the strategy version and queues the backtest.
5. Review the result
The Canvas shows the run as PENDING, EXECUTING, COMPLETED, or FAILED. A completed report can include:
- The data, strategy parameters, and simulation settings used
- Return, risk, trading activity, and benchmark metrics
- Account balance, drawdown, and trading charts
- A trade log when the run contains executions
A backtest describes historical behavior; it does not predict future returns.
Know the workspace
- The sidebar opens chats, strategies, reports, optimizations, and data.
- The chat is where you describe and revise the strategy.
- The Canvas holds identified rules, generated code, runs, and results.