Quick Start: Build Your First Strategy
This walkthrough takes you from a blank workspace to a running strategy in about 5 minutes. You'll use SMITH, FORJ's visual strategy editor, to build a minimal strategy that alternates between two states on every new candle.
Prerequisites
- You've signed up and created a workspace
- You're on the Strategy Dashboard (the Hearth)
Step 1 — Open SMITH
- Click New Strategy in the sidebar.
- Enter a name for your strategy (e.g.,
BTCUSD_Starter) and confirm.
SMITH opens with an empty canvas and a Creation Checklist showing the requirements before you can save.
Step 2 — Configure Context
- Click the Gear icon at the bottom of the canvas to open the Strategy Toolbar.
- Select Configure Context.
- Set the Symbol (the instrument your strategy will track, e.g.,
BTCUSD). - Set the Candle Length (the timeframe for market updates, e.g.,
5mfor 5-minute candles). - Save the context.
The checklist item "Context Configured" is now satisfied.
Step 3 — Add Two States
- From the Strategy Toolbar, select Add New State.
- Name it
Watchingand save. - Add a second state named
Active.
The checklist item "At Least Two States Configured" is now satisfied.
Step 4 — Set the Initial State
- On the
Watchingstate widget, click Set as Initial State.
The checklist item "Initial State Configured" is now satisfied. This is the state your strategy starts in when enabled.
Step 5 — Add Transitions
- On the
Watchingstate widget, click Add Transition. - Set the trigger to a New Candle event and the target state to
Active. Save. - On the
Activestate widget, add a transition back toWatchingon a New Candle event.
The checklist item "All States Have Transitions" is now satisfied.
Step 6 — Save Your Strategy
With all checklist items satisfied, the Create Strategy button is now enabled.
- Click Create Strategy.
- SMITH closes and returns you to the Strategy Dashboard.
Your new strategy appears as a tile on the dashboard.
Step 7 — Subscribe to a Data Stream
Your strategy needs a live data feed before it can receive events. If you haven't already connected a data source to your workspace, do that first (see Data Sources).
- Reopen the strategy in SMITH (click the tile on the dashboard).
- Open the Strategy Toolbar (gear icon) and select Data Subscriptions.
- Choose the stream that matches your configured symbol and candle length, then confirm.
Your strategy is now wired to incoming market data.
Without a data subscription the strategy will save and enable successfully but will never receive events. This is the most commonly missed step.
Step 8 — Enable Your Strategy
- Return to the Strategy Dashboard.
- Find your strategy tile and click the Power toggle to enable it.
Your strategy is now live — it will receive market events at the candle length you configured and alternate between its two states.
You can disable your strategy at any time by toggling the power switch off. When disabled, the strategy resets to its initial state and default context values.
What's Next
This minimal strategy shows the basic building blocks. To make it useful, you'll want to:
- Add conditions — define the rules that control when transitions fire
- Configure actions — specify what happens during a transition (trade signals, alerts, variable updates)
- Connect a data source — set up live market data feeds for your workspace
- Run a backtest — use CRUCIBLE to test your strategy against historical data before going live