Spaces:
Sleeping
Sleeping
ddovidovich
commited on
Commit
·
e9b54ed
1
Parent(s):
cb863f0
Update app.py
Browse files
app.py
CHANGED
@@ -125,7 +125,7 @@ def main():
|
|
125 |
if st.button("Apply"):
|
126 |
query = prompt
|
127 |
st.write("in progress")
|
128 |
-
text_splitter = CharacterTextSplitter(chunk_size=
|
129 |
texts = text_splitter.split_text(input_text)
|
130 |
embeddings = OpenAIEmbeddings()
|
131 |
docsearch = Chroma.from_texts(texts, embeddings, metadatas=[{"source": str(i)} for i in range(len(texts))]).as_retriever()
|
|
|
125 |
if st.button("Apply"):
|
126 |
query = prompt
|
127 |
st.write("in progress")
|
128 |
+
text_splitter = CharacterTextSplitter(chunk_size=4096, chunk_overlap=0)
|
129 |
texts = text_splitter.split_text(input_text)
|
130 |
embeddings = OpenAIEmbeddings()
|
131 |
docsearch = Chroma.from_texts(texts, embeddings, metadatas=[{"source": str(i)} for i in range(len(texts))]).as_retriever()
|