diff --git a/pilot/vector_store/extract_tovec.py b/pilot/vector_store/extract_tovec.py index e571ac54f..ccfe7bda0 100644 --- a/pilot/vector_store/extract_tovec.py +++ b/pilot/vector_store/extract_tovec.py @@ -34,7 +34,7 @@ def knownledge_tovec_st(filename): text_splitter = CharacterTextSplitter(chunk_size=1000, chunk_overlap=0) - texts = text_splitter(knownledge) + texts = text_splitter.split_text(knownledge) docsearch = Chroma.from_texts(texts, embeddings, metadatas=[{"source": str(i)} for i in range(len(texts))]) return docsearch diff --git a/requirements.txt b/requirements.txt index 50354b3b4..f0ddf8fb5 100644 --- a/requirements.txt +++ b/requirements.txt @@ -50,4 +50,6 @@ notebook gradio==3.24.1 gradio-client==0.0.8 wandb -fschat=0.1.10 \ No newline at end of file +fschat=0.1.10 +llama-index=0.5.27 +pymysql \ No newline at end of file