From 45bd26f9991df93f62aaccca98528960a0775cc2 Mon Sep 17 00:00:00 2001 From: Bigad Soleiman Date: Tue, 7 Nov 2023 12:22:21 +0000 Subject: [PATCH] Disable streaming for condense prompts --- .../langchain/functions/request-handler/adapters/base/base.py | 2 +- lib/user-interface/index.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/model-interfaces/langchain/functions/request-handler/adapters/base/base.py b/lib/model-interfaces/langchain/functions/request-handler/adapters/base/base.py index 971e9547a..95529c9f6 100644 --- a/lib/model-interfaces/langchain/functions/request-handler/adapters/base/base.py +++ b/lib/model-interfaces/langchain/functions/request-handler/adapters/base/base.py @@ -90,7 +90,7 @@ def run_with_chain(self, user_prompt, workspace_id=None): conversation = ConversationalRetrievalChain.from_llm( self.llm, WorkspaceRetriever(workspace_id=workspace_id), - condense_question_llm=self.get_llm(streaming=False), + condense_question_llm=self.get_llm({"streaming": False}), condense_question_prompt=self.get_condense_question_prompt(), combine_docs_chain_kwargs={"prompt": self.get_qa_prompt()}, return_source_documents=True, diff --git a/lib/user-interface/index.ts b/lib/user-interface/index.ts index e602ffe82..1189418ee 100644 --- a/lib/user-interface/index.ts +++ b/lib/user-interface/index.ts @@ -275,6 +275,7 @@ export class UserInterface extends Construct { }); new s3deploy.BucketDeployment(this, "UserInterfaceDeployment", { + prune: false, sources: [asset, exportsAsset], destinationBucket: websiteBucket, distribution,