Overview
This prompt guides the creation of a detailed, automated Forex trading strategy for AlgoBuilder’s no-code platform. Traders and developers will benefit by receiving a customizable, backtest-ready blueprint with robust risk management.
Prompt Overview
Purpose: To create an automated Forex trading strategy in AlgoBuilder that uses combined technical conditions to mimic machine learning signals.
Audience: Traders and developers using AlgoBuilder’s no-code environment for strategy automation.
Distinctive Feature: It includes two selectable trading modes, Swing and Scalping, with distinct timeframes and trade management rules.
Outcome: A fully backtestable strategy with dynamic risk management and configurable entry/exit logic.
Quick Specs
- Media: Text
- Use case: Generation
- Industry: Stock Brokerage & Trading, Machine Learning & Data Science
- Techniques: System-First Instructions, Structured Output, Decomposition
- Models: GPT-4, Claude 3 Opus, DeepSeek-Coder V2
- Estimated time: 5-10 minutes
- Skill level: Beginner
Variables to Fill
No inputs required — just copy and use the prompt.
Example Variables Block
No example values needed for this prompt.
The Prompt
Create an automated Forex trading strategy compatible with AlgoBuilder that mimics a machine learning trading approach by using combined technical indicator conditions to generate buy and sell signals. The strategy must include configurable features for take profit, stop loss, break even, and trailing stop, as well as dynamic lot sizing based on a user-defined risk percentage of account balance.
The strategy should support two selectable trading modes—Swing and Scalping—with distinct timeframe filters and trade duration characteristics:
– **Swing Mode**: Utilize higher timeframes (H1, H4, D1), set larger take profit and stop loss values, and hold trades from hours to days.
– **Scalping Mode**: Operate on lower timeframes (M1, M5, M15), employ smaller take profit and stop loss values, and hold trades from seconds to minutes with increased trade frequency.
Entry and exit signals must be defined using a combination of indicators (e.g., EMA, RSI, momentum) to approximate machine learning model outputs. For example, a buy signal occurs only when all specified indicator conditions exceed defined confidence thresholds, which users can customize.
Implement strict risk management including:
– Auto-calculated lot sizes based on risk percentage
– User-configurable take profit (in pips or percentage)
– User-configurable stop loss
– Break even stop loss adjustment after reaching a user-defined profit threshold
– Trailing stop activation and distance based on profit thresholds
– Limits on maximum trades per day/session, maximum drawdown, slippage, and spread filters
Include session and optional news filters to restrict trading hours and pause trading around major economic events, if available.
The strategy must be fully backtestable on historical tick and bar data within AlgoBuilder and support parameter optimization for all inputs (e.g., TP, SL, trailing stops, indicator thresholds).
Provide the strategy in plain English description or drag-and-drop logic format compatible with AlgoBuilder’s no-code environment, ensuring modularity and clarity for easy customization.
### Steps
1. Define key input parameters including: Trading Mode, EMA period, RSI period and thresholds, take profit, stop loss, break even trigger, trailing stop activation profit and distance, risk per trade, max trades per day, trading hours, slippage and spread limits.
2. Approximate machine learning signals by combining indicator conditions (e.g., price above EMA, RSI above threshold) to generate buy/sell signals only when all criteria match.
3. Apply trading mode-specific settings to timeframe and trade durations.
4. Implement risk management rules: dynamic lot sizing, TP, SL, break even, trailing stop, and max trades/drawdown limits.
5. Incorporate session and optional news filters.
6. Ensure the strategy supports backtesting and parameter optimization within AlgoBuilder.
### Output Format
Provide the complete strategy description or logic in plain English suitable for direct input into AlgoBuilder’s editor or as a detailed step-by-step drag-and-drop instruction set that faithfully implements all features described, ensuring compatibility with AlgoBuilder’s no-code environment.
### Example
“Enter a BUY trade when the price is above the 200 EMA and RSI(14) is above 60, hold it as per the chosen trading mode (Swing or Scalping). Set take profit at 30 pips, stop loss at 15 pips, move stop loss to break even after 10 pips gained, and activate a trailing stop trailing by 10 pips once profit exceeds 20 pips. Calculate lot size to risk 1% of account balance per trade. Limit to 3 trades per day, and restrict trading to 07:00 to 18:00 with maximum spread 2 pips. Suspend trading 30 minutes before major news events if news filter enabled.”
Screenshot Examples
[Insert relevant screenshots after testing]
How to Use This Prompt
- Copy the prompt exactly as provided.
- Paste it into AlgoBuilder’s strategy editor or description field.
- Use the prompt’s steps to build your no-code logic blocks.
- Configure all input parameters from Step 1 in your platform.
- Link indicator conditions to create entry signals per Step 2.
- Apply the risk management and filter rules from Steps 4 and 5.
Tips for Best Results
- Define Inputs & Mode: Set trading mode (Swing/Scalping), indicator parameters (EMA period, RSI period/thresholds), TP/SL in pips, break-even trigger, trailing stop activation/distance, risk percentage, max trades per day, session times, and max spread/slippage.
- Generate Entry Signals: Create a buy signal only when price is above EMA and RSI exceeds its upper threshold simultaneously; a sell signal when price is below EMA and RSI is below its lower threshold.
- Apply Mode Rules: In Swing mode, use H1+ charts, larger TP/SL, and longer holds. In Scalping mode, use M1-M15 charts, smaller TP/SL, and quick exits.
- Manage Risk & Exit: Auto-calculate lot size based on risk% and stop loss. Apply TP, SL, move to break-even at defined profit, then activate trailing stop. Enforce max daily trades and drawdown limits.
FAQ
- What is the main purpose of this Forex trading strategy?
To mimic machine learning using combined technical indicators for automated buy/sell signals with strict risk management, compatible with AlgoBuilder. - How does Swing Mode differ from Scalping Mode?
Swing uses higher timeframes (H1-H4-D1) with larger TP/SL and longer holds. Scalping uses lower timeframes (M1-M5-M15) with smaller TP/SL and quick trades. - What risk management features are included?
Dynamic lot sizing based on risk percentage, configurable TP/SL, break even adjustment, trailing stops, max trades per day, and drawdown limits. - How are entry signals generated?
By combining indicator conditions like EMA, RSI, and momentum exceeding user-defined thresholds to approximate ML model confidence.
Compliance and Best Practices
- Best Practice: Review AI output for accuracy and relevance before use.
- Privacy: Avoid sharing personal, financial, or confidential data in prompts.
- Platform Policy: Your use of AI tools must comply with their terms and your local laws.
Revision History
- Version 1.0 (March 2026): Initial release.


