text: Skip to main contentğŸ¦œï¸�ğŸ”— LangChainDocsUse casesIntegrationsAPILangSmithJS/TS DocsCTRLKUse casesQA and Chat over DocumentsAnalyzing structured dataExtractionInteracting with APIsChatbotsSummarizationCode UnderstandingAgent simulationsAgentsAutonomous (long-running) agentsAutoGPTBabyAGI User GuideBabyAGI with ToolsHuggingGPTmarathon_timesMeta-PromptMulti-modalUse casesAutonomous (long-running) agentsAutoGPTOn this pageAutoGPTImplementation of https://github.com/Significant-Gravitas/Auto-GPT but with LangChain primitives (LLMs, PromptTemplates, VectorStores, Embeddings, Tools)Set up toolsâ€‹We'll set up an AutoGPT with a search tool, and write-file tool, and a read-file toolfrom langchain.utilities import SerpAPIWrapperfrom langchain.agents import Toolfrom langchain.tools.file_management.write import WriteFileToolfrom langchain.tools.file_management.read import ReadFileToolsearch = SerpAPIWrapper()tools = [    Tool(        name="search",        func=search.run,        description="useful for when you need to answer questions about current events. You should ask targeted questions",    ),    WriteFileTool(),    ReadFileTool(),]Set up memoryâ€‹The memory here is used for the agents intermediate stepsfrom langchain.vectorstores import FAISSfrom langchain.docstore import InMemoryDocstorefrom langchain.embeddings import OpenAIEmbeddings# Define your embedding modelembeddings_model = OpenAIEmbeddings()# Initialize the vectorstore as emptyimport faissembedding_size = 1536index = faiss.IndexFlatL2(embedding_size)vectorstore =