AGI is here! (AutoGPT) Detailed Tutorial + Real Example

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
Welcome to the future of AI,   where GPT models autonomously define and  execute tasks to achieve your objectives. In today's video I'll guide you  through setting up the number one   trending GitHub project AutoGPT, an AGI  experiment that's transforming the game. With capabilities like Google search, long-term  memory, local file storage and text-to-speech,   AutoGPT easily helped me develop these two  brand concepts with minimal human interaction. Get ready to experience AGI as we dive into this   groundbreaking technology that's  redefining the boundaries of AI. Hi I'm Appy Dave and my goal is to build  an app a day using the power of AI. Today I explored autonomous GPT through  AutoGPT and I used this automatic bot to   create a product that combined yoga mats  with meditation music and incense candles. And from there I was able to develop concepts  for Pure Bliss Essentials and Tranquility Heaven. Let me walk you through how I set this all up. Here we have a GitHub application called  AutoGPT. This is essentially an automation   bot that uses Python to interact with  GPT-4, Pinecone text embeddings, Elevenlabs,   text-to-speech and Google search and  is extendable to use other services.   What this means is that it can learn from  itself, it can speak out loud the responses   it has, it can automatically create documents  and spreadsheets, it can get smarter over time   through human interactions and it can search  the internet for up-to-date information. And   I'm sure it won't be long before you can speak to  it. Now I'm going to show you how to set it up. But rather than follow the instructions directly,   I'm going to let ChatGPT read the  instructions and tell us how to install it. So first, we're going to find  the README file and click on it.   When that's open, you can click on the  RAW button so that we can copy RAW text. Now, move down to the table of contents and then  just select all the text from that point to the   bottom of the page and copy it. From here, you can  open ChatGPT. I like to select the GPT-4 model.   I then paste the README file directly into  the chat. And then I tell GPT to read it and   say ‘yay’ if it understands. I tell Chat  that I want it to help me set up AutoGPT.   I also mention the type of computer  and the version of Python I am running. I got instructions on how to open my terminal,  how to clone this particular repository onto   my computer, how to change directories into the  new repo, and how to use Python to install this   application. It then gave some additional  information about renaming the environment   template so that I could configure OpenAI, Eleven  Labs, Pinecone, and Google with access tokens. Now when I access Python or the Python package  manager on my computer, I use Python 3 or pip3,   and I just wanted to mention this to the chat  so it can give me more accurate commands.   And now it's just rewriting the  commands with the minor change. I'm installed, so I now ask it what to do next.  It tells me to cd into the folder and run python   main.py as the main entry file. One of the  things I noticed is that I'm using Python 3   and it did not get that right. It is also a little  bit premature in asking me to run the app straight   away. And the reason for that is we haven't  done any configuration. So I go back up through   the file and look for the configurations for  ElevenLabs, OpenAI, Pinecone and Google Search.   I then just asked GPT where the steps were for  configuration. It told me that I needed to copy   the.env.template file into a file called.env.  I also asked what the difference was between   Pinecone and Google in this context. I was  aware that Pinecone was a vector database,   but I wasn't sure whether Google was playing a  similar role. It told me that Google was being   used for the live search on the internet. Here I'm  creating my .env file. I follow the instructions   and go to the OpenAI account information, click  on API keys and I create myself a new API key   just for using this application. Then I paste  it against the OpenAI API environment variable. ElevenLabs is very similar. Go to the profile,  display the API key by clicking the show button,   paste it against the environment variable  ElevelLabs API key. To set up Pinecone I asked   chat how to do this. It gave me a link to the  Pinecone website. It also gave me the environment   variables to alter. I signed up for a new Pinecone  account and followed the instructions to go to the   default project. Copied the environment over  to pinecone underscore env then clicked the   show API key, copied it and pasted it into the  pinecone API underscore key. Lastly I asked chat   gpt how to set up the google search API key. There was a link that it gave me. I went to   the Google Cloud Console, found a little  drop down near the top left of the screen,   where I was able to see a dialogue and select  new project. I named my project Autonomous GPT.   After creation, I was able to click  APIs and Services under Quick Access. There was a little button  called Enable APIs and Services,   and the name of the service I  wanted was called Custom Search. You can then create credentials by clicking  on the Credentials button on the left,   then click the blue Create Credentials  link at the top of the page. A dialogue will appear, and you can copy the API   key and paste it over to the  Google environment variable. ChatGPT also told me that I needed to set up  a Custom Search engine, and it gave me a link,   so I clicked on Custom search engine and when I  saw all search engines I clicked the add button.   I selected the “search the  entire web” radio button.   I also had to give it a name  and fill in the capture card   before creation. Now your custom search engine  will be created and there will be a little ID   that you need to copy. Just paste that ID against  the custom search engine ID environment variable.   I asked chat GPT if there was anything else  that I had to set up. It said I was okay but   I did spend the next hour trying to debug the  library to fix one little problem that was   easy to solve in retrospect. The issue  was that the open API base environment   that GPT was giving me, api.openai.com  as an answer, was incorrect. The issue was around the  OPENAI_API_BASE environment variable GPT was giving me api.openai.com as an answer, but  the correct answer was actually api.openai.com/v1.   After this final bit of configuration, I was  able to get AutoGPT running. But I will say   it took three or four attempts before I could  get it to do a useful chat. There are still a   number of issues within this project that need to  be addressed before it becomes production worthy. In the next section, I will talk about  one simple continuous chat that I did get,   to come up with a product concept for a business. I gave the AI a name. I  called it Product Inventor.  Next, I gave it a role, and its role was to take   three products and come up with a  new product that blends the ideas. Finally, I gave it three products, scented  candles, yoga mats, and relaxing music. Now I can enter up to five but if you press enter  on an empty line it'll just kick off the bot. Now the first thing that the bot  does is it reflects on what its   own thoughts are on the project.  The goal is to come up with a new   product that blends the ideas of scented  candles, yoga mats and relaxation music. So it works out that it should research the  benefits that these products bring by finding   the commonalities between them. It then reasons  for itself that it needs a deeper understanding   of the products and how blending them can inform  its future decisions. It also understands that   it needs to create a product that will be  revolutionary. So it comes up with a plan,   conduct research on scented candles,  yoga mats and relaxation music, look for   their commonalities and brainstorm  ideas for potential new products. The last piece, criticism, is really powerful  because Bots can have a problem with going down   rabbit holes in a direction that the author  didn't intend. And so it tells us that it   needs to ensure that it's taking the time to  thoroughly research each product and should   not jump to any conclusions too quickly. It then  creates its next command and asks for guidance. So   the command is a Google search on the benefits of  scented candles, yoga mats, and relaxation music.   So now it's looking for input from the user. So  let's break this down. If you just want it to   execute the next command, press yes to authorize.  If you want to steer the way it's thinking,   then just give it some feedback in the  form of a prompt. If you are finished   with all the commands that the bot has  run, you can press N to exit the program.   You might've noticed that I skipped the continuous  command, which is yes followed by “ y -N””. The reason is that the chatbot will  actually run automatically and spawn   a lot of requests to different services  such as the Google Search API, the Chat   GPT API, the Pinecone API and you could rack up  a really hefty bill with some of these services   if you are not paying attention. Now with  this understanding in place let's press Y. So we can see at this point it's  gone and researched some information   on various websites like Lullify,  Studio Growth, Healthline and it's   putting all this information into  its long-term memory in Pinecone. Now if you look at the inventor  thoughts, reasoning, plan and criticism,   you'll notice that there's not a lot of  difference in this next action it's about   to take and the previous action. So we'll  press Y and see what it does differently.   And it looks like it's just  continuing its research. It's gone to Twitter, Amazon, Yogarascals  and other URLs to get information.   It now looks like the bot has done enough research  on the products themselves and decided that what   it needs to do now is, how can it blend these  products together in a unique and effective way.   And now it's coming up with a lot of  information that it's committing to its   long-term memory in Pinecone. And from this  information decides to research marketing   strategies around wellness products, followed  by consumer preferences for wellness products.   Now I let the bot run for a while, pressing  yes each time, until I get to this section.   Because here it ran a new command called  write to file and you can see it's written   out a file called product_pitch.test with  a whole lot of content. Now what's great   is that it's not just in the Pinecone memory,  but it's now out in a file where I can use it. So the bot continues for a little while doing  different searches building up a knowledge base   and then it gets to this section. It's about to  write a report for me in markdown format and this   will be great because I'll be able to use it to  develop presentations and social media assets. Now   the bot actually had an error and failed to write  out the report to the file but as you can see it   is all here so I just copied this and put it into  my own markdown file and you can view it here. I then used a manual prompt asking it to give me a  hierarchical list of tasks that it had worked on.   It failed with the command but it still gave the   list and I was able to just move  this straight into a mind map. I pressed no to exit then I  proceeded to develop a bunch   of assets in mid-journey and Canva  and create these two presentations. The interesting thing is that Canva has an API  so a lot of the presentation work could have   been done automatically as well and while  Midjourney doesn't currently have an API,   other platforms like Stable Diffusion, DALI  and the up-and-coming Firefly by Adobe will.  If you are interested in writing your  own AGI then subscribe to the channel.   Part 2 in this series will be about  reverse engineering autonomous bots.
Info
Channel: AppyDave
Views: 110,867
Rating: undefined out of 5
Keywords: auto gpt, autonomous ai, gpt 4, artificial intelligence, chatgpt, ai, gpt 3, gpt 4 demo, chat gpt explained, auto gpt setup, auto gpt tutorial, auto gpt howto, agi, auto gtp agi, open ai, open ai chat gpt, pinecone, auto gpt github, pinecode setup, gpt4, gpt-4
Id: YYPlNs7lw6c
Channel Id: undefined
Length: 14min 36sec (876 seconds)
Published: Sun Apr 09 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.