sabazo commited on
Commit
bf2279b
1 Parent(s): b6db668

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -19,9 +19,12 @@ from langchain.chains import RetrievalQA
19
  #loader = WebBaseLoader(web_links)
20
  #documents = loader.load()
21
 
 
 
22
  #texts = text_splitter.split_documents(documents)
23
- db = Chroma.from_documents(persist_directory='chroma_db', embedding_function=embeddings)
24
  retriever = db.as_retriever()
 
25
  global qa
26
  qa = RetrievalQA.from_chain_type(llm=model_id, chain_type="stuff", retriever=retriever, return_source_documents=True)
27
 
 
19
  #loader = WebBaseLoader(web_links)
20
  #documents = loader.load()
21
 
22
+ db = Chroma(persist_directory="./chroma_db", embedding_function=embeddings)
23
+ db.get()
24
  #texts = text_splitter.split_documents(documents)
25
+ #db = Chroma.from_documents(texts, embedding_function=embeddings)
26
  retriever = db.as_retriever()
27
+
28
  global qa
29
  qa = RetrievalQA.from_chain_type(llm=model_id, chain_type="stuff", retriever=retriever, return_source_documents=True)
30