From 171809a1352c624dc27395773f4c812c20eb5638 Mon Sep 17 00:00:00 2001 From: Kye Date: Tue, 4 Jul 2023 10:03:48 -0400 Subject: [PATCH] now commences tool clean up --- requirements.txt | 3 ++- setup.py | 1 + swarms/tools/main.py | 4 ++-- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/requirements.txt b/requirements.txt index 557dbbbe..7157252c 100644 --- a/requirements.txt +++ b/requirements.txt @@ -53,4 +53,5 @@ O365 # whisperx pytube pydub -git+https://github.com/m-bain/whisperx.git \ No newline at end of file +git+https://github.com/m-bain/whisperx.git +llama-index \ No newline at end of file diff --git a/setup.py b/setup.py index 38f8bd58..ef7d2850 100644 --- a/setup.py +++ b/setup.py @@ -37,6 +37,7 @@ setup( "controlnet-aux", "diffusers", "einops", + 'llama-index', "gradio", "imageio", "imageio-ffmpeg", diff --git a/swarms/tools/main.py b/swarms/tools/main.py index 329d3a92..4f9c6e45 100644 --- a/swarms/tools/main.py +++ b/swarms/tools/main.py @@ -15,7 +15,7 @@ from langchain.llms.base import BaseLLM import requests from bs4 import BeautifulSoup -from llama_index import GPTSimpleVectorIndex +from llama_index import GPTVectorStoreIndex from llama_index.readers.database import DatabaseReader from env import settings @@ -135,7 +135,7 @@ class WineDB(BaseToolSet): FROM wine """ documents = db.load_data(query=query) - self.index = GPTSimpleVectorIndex(documents) + self.index = GPTVectorStoreIndex(documents) @tool( name="Wine Recommendation",