The AutoGPT MetaTrader Plugin is a software tool that enables traders to connect their MetaTrader 4 or 5 trading account to Auto-GPT.
- ๐ฐ Place Trades
- โน๏ธ Account Information
- โ๏ธ Close Trade
- โ Close All Trades
- ๐ฏ Candlestick Data
Follow these steps to configure the Auto-GPT MetaTrader Plugin:
Clone this repository and navigate to the Auto-GPT-MetaTrader-Plugin
folder in your terminal:
git clone https://github.com/isaiahbjork/Auto-GPT-MetaTrader-Plugin.git
Execute the following command to install the necessary dependencies:
pip install -r requirements.txt
Compress the Auto-GPT-MetaTrader-Plugin
folder or download the repository as a zip file.
If you haven't already, clone the Auto-GPT repository, follow its installation instructions, and navigate to the Auto-GPT
folder.
You might have to run this in the Auto-GPT file if you get an error saying "No Moudle Found".
pip install ta
Transfer the zip file from step 3 into the plugins
subfolder within the Auto-GPT
repo.
Find the file named .env.template
in the main /Auto-GPT
folder.
Duplicate the .env.template
file and rename the copy to .env
inside the /Auto-GPT
folder.
Open the .env
file in a text editor. Note: Files starting with a dot might be hidden by your operating system.
Append the following configuration settings to the end of the file:
################################################################################
### METATRADER
################################################################################
META_API_ACCOUNT_ID=
META_API_TOKEN=
- Create a MetaAPI account and connect to your broker.
- Set
META_API_ACCOUNT_ID
to your MetaAPI account ID. - Set
META_API_TOKEN
to your MetaAPI token.
In your .env
search for ALLOWLISTED_PLUGINS
and add this Plugin:
################################################################################
### ALLOWLISTED PLUGINS
################################################################################
#ALLOWLISTED_PLUGINS - Sets the listed plugins that are allowed (Example: plugin1,plugin2,plugin3)
ALLOWLISTED_PLUGINS=AutoGPTMetaTraderPlugin
Experience the plugin's capabilities by testing it for placing trades, managing your account, closing trades, and fetching candlestick data.
-
Configure Auto-GPT: Set up Auto-GPT with the following parameters:
- Name:
TradeGPT
- Role:
fetch candlestick data
- Goals:
- Goal 1:
fetch candlestick data for the 1 hour chart on EURUSD
- Goal 2:
Terminate
- Goal 1:
- Name:
-
Run Auto-GPT: Launch Auto-GPT, which should use the MetaTrader plugin and it should load the candlestick data.
-
Sample response:
- Relative Strength Index (RSI)
- Volume
- Moving Averages (SMA, EMA, WMA, MAE, OsMA, MACD)
- Fibonacci Retracement
- Bollinger Bands
- Money Fund Index (MFI)