First, let’s talk about what AutoGpt is! It is an open-source application that showcases the capabilities of GPT-4. This program is driven by GPT-4 and can chain together LLM “thoughts”, to autonomously achieve any given goal you set.
#WHY IS IT COOL?
It pushes the boundaries of what is possible with AI as one of the best examples of GPT-4 running fully autonomously.Some of cool features: Internet Access for searches and information gathering Long-term and Short-term Memory Management GPT-4 instances for text generation Access to popular websites and platforms File storage and summarization with GPT-3.5
#What are the Requirements ?
- Python 3.10 or later
- OpenAI API Key
GPT3.5 ONLY Mode (please see GitHub repo for any help!) If you don’t have access to the GPT4 api, this mode will allow you to use Auto-GPT! python -m autogpt –speak –gpt3only
Backend -> Pinecone | Milvus | Reddit ElevenLabs Key (To have AI SPEAK )
Create a folder in your home directory or Desktop. Create another folder called ‘autogpt’. Or whatever name you like!
#Activate a virtual environment
To create a virtual environment. Follow the code below:
To navigate to your root directory, use the ‘cd’ command followed by the path to your root directory.For example if your root directory is ‘/home/user/’ on Linux or MacOS, use the command:
Once you’ve navigated to your root directory, you can create a new Python virtual environment using the ‘venv’ module or any other tool of your choice. python3 -m venv myenv This will create a new virtual environment called ‘myenv’. To activate your new virtual environment, run the activate script in the virtual environment’s ‘bin’ directory.
#On MacOS or Linux:
This will activate the virtual environment and you can start working on your new project! Installation (disregard the weird number 1 formatting )
#To start installing Auto-GPT, follow these steps:
Install all requirements listed above, if not already installed.
To execute the following commands, open a CMD,Bash or terminal window. Clone the repository: For this step, you need Git installed on your computer.
Navigate to the directory where repository was downloaded
cd Auto-GPT Install the required dependencies
pip install -r requirements.txt
- Locate the file named .env.template in the main /Auto-GPT folder.
- Create a copy of this file, called .env by removing the template extension.
The easiest way is to do this in a command prompt/terminal window cp .env.template .env.
- Open the .env file in a text editor. Note: Files starting with a dot might be hidden by your Operating System.
- Find the line that says OPENAI_API_KEY=.
After the “=”, enter your unique OpenAI API Key (without any quotes or spaces).
- Enter any other API keys or Tokens for services you would like to utilize.
- Save and close the .env file.
By completing these steps, you have properly configured the API Keys for your project.
Command Line Arguments Here are some common arguments you can use when running Auto-GPT:
Replace anything in (<>) to a value you want to specify. To view all available command line arguments
python -m autogpt --help Run Auto-GPT with a different AI Settings file
python -m autogpt --ai-settings <filename> Specify a memory backend
python -m autogpt --use-memory <memory-backend> Speech Mode Use this to use TTS (Text-to-Speech) for Auto-GPT. python -m autogpt --speak
List of IDs with names from eleven labs, you can use the name or ID:
#You can use 2 of these ID’s in you .env file as a voice if you choose to use the SPEAK option.
Rachel : 21m00Tcm4TlvDq8ikWAM Domi : AZnzlk1XvdvUeBnXmlld Bella : EXAVITQu4vr4xnSDxMaL Antoni : ErXwobaYiN019PkySvjV Elli : MF3mGyEYCl7XYWbV9V6O Josh : TxGEqnHWrfWFTfGW9XjX Arnold : VR6AewLTigWG4xSOukaG Adam : pNInz6obpgDQGcFmaJgB Sam : yoZ06aMxZJJ28mfd3POQ
OpenAI API Keys Configuration
Obtain your OpenAI API key from: https://platform.openai.com/account/api-keys. To use OpenAI API key for Auto-GPT, you NEED to have billing set up (AKA paid account). You can set up paid account at https://platform.openai.com/account/billing/overview. Setting Your Cache Type By default, Auto-GPT is going to use LocalCache instead of redis or Pinecone. To switch to either, change the MEMORY_BACKEND env variable to the value that you want: local (default) uses a local JSON cache file pinecone uses the Pinecone.io account you configured in your ENV settings
#Pinecone API Key Setup
Pinecone enables the storage of vast amounts of vector-based memory, allowing for only relevant memories to be loaded for the agent at any given time. Go to pinecone and make an account if you don’t already have one. Choose the Starter plan to avoid being charged. Find your API key and region under the default project in the left sidebar.
In the .env file set: PINECONE_API_KEY PINECONE_ENV (example: “us-east4-gcp”) MEMORY_BACKEND=pinecone
Alternatively, you can set them from the command line (advanced): MacOS or Linux: export PINECONE_API_KEY=”<YOUR_PINECONE_API_KEY>” export PINECONE_ENV=”<YOUR_PINECONE_REGION>” # e.g: “us-east4-gcp” export MEMORY_BACKEND=”pinecone”
⚠️ Run the AI without user authorization, 100% automated. Continuous mode is NOT recommended. It is potentially dangerous and may cause your AI to run forever or carry out actions you would not usually authorize. Use at your own risk. Run the autogpt python module in your terminal:
python -m autogpt –speak –continuous
To exit the program, press Ctrl + C It is recommended to use a virtual machine for tasks that require high security measures to prevent any potential harm to the main computer’s system and data.
Have a great week everyone & Happy Hump Day!
Check out my most recent article on SUPERAGI!