Spaces:
Running
Running
ryanrwatkins
commited on
Commit
•
d77bab0
1
Parent(s):
0600933
Update app.py
Browse files
app.py
CHANGED
@@ -254,7 +254,7 @@ vectorstore,search_type="similarity",k=4,score_threshold=None
|
|
254 |
|
255 |
# similarity search
|
256 |
#base_retriever_OpenAI = Vectorstore_backed_retriever(vector_store_OpenAI,"similarity",k=10)
|
257 |
-
|
258 |
base_retriever_HF = Vectorstore_backed_retriever(vector_store_HF,"similarity",k=10)
|
259 |
|
260 |
|
@@ -474,7 +474,7 @@ answer_prompt.invoke(
|
|
474 |
|
475 |
|
476 |
|
477 |
-
|
478 |
# Instantiate the retriever and the ConversationalRetrievalChain :
|
479 |
|
480 |
retriever_Google = retrieval_blocks(
|
@@ -487,7 +487,7 @@ retriever_Google = retrieval_blocks(
|
|
487 |
cohere_api_key=cohere_api_key,cohere_top_n=10,
|
488 |
)
|
489 |
|
490 |
-
|
491 |
chain_gemini,memory_gemini = custom_ConversationalRetrievalChain(
|
492 |
llm = instantiate_LLM(
|
493 |
LLM_provider="Google",api_key=google_api_key,temperature=0.5,model_name="gemini-pro"
|
@@ -512,7 +512,7 @@ chain = ConversationalRetrievalChain.from_llm(
|
|
512 |
LLM_provider="Google",api_key=google_api_key,temperature=0.1,
|
513 |
model_name="gemini-pro"),
|
514 |
memory=create_memory("gemini-pro"),
|
515 |
-
retriever =
|
516 |
llm=instantiate_LLM(
|
517 |
LLM_provider="Google",api_key=google_api_key,temperature=0.5,
|
518 |
model_name="gemini-pro"),
|
|
|
254 |
|
255 |
# similarity search
|
256 |
#base_retriever_OpenAI = Vectorstore_backed_retriever(vector_store_OpenAI,"similarity",k=10)
|
257 |
+
base_retriever_google = Vectorstore_backed_retriever(vector_store_google,"similarity",k=10)
|
258 |
base_retriever_HF = Vectorstore_backed_retriever(vector_store_HF,"similarity",k=10)
|
259 |
|
260 |
|
|
|
474 |
|
475 |
|
476 |
|
477 |
+
"""
|
478 |
# Instantiate the retriever and the ConversationalRetrievalChain :
|
479 |
|
480 |
retriever_Google = retrieval_blocks(
|
|
|
487 |
cohere_api_key=cohere_api_key,cohere_top_n=10,
|
488 |
)
|
489 |
|
490 |
+
|
491 |
chain_gemini,memory_gemini = custom_ConversationalRetrievalChain(
|
492 |
llm = instantiate_LLM(
|
493 |
LLM_provider="Google",api_key=google_api_key,temperature=0.5,model_name="gemini-pro"
|
|
|
512 |
LLM_provider="Google",api_key=google_api_key,temperature=0.1,
|
513 |
model_name="gemini-pro"),
|
514 |
memory=create_memory("gemini-pro"),
|
515 |
+
retriever = base_retriever_google, #base_retriever_HF
|
516 |
llm=instantiate_LLM(
|
517 |
LLM_provider="Google",api_key=google_api_key,temperature=0.5,
|
518 |
model_name="gemini-pro"),
|