From af54b7cfefa9842cddac15b44bb45899fe775f09 Mon Sep 17 00:00:00 2001 From: Alex Date: Sun, 26 Jan 2025 13:06:00 +0000 Subject: [PATCH 1/3] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index ca512c2f..2e261fe9 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@
-video-example-of-docs-gpt +video-example-of-docs-gpt

Key Features: From 254582da89684ca9b83fc91c6eaa8544d05f6802 Mon Sep 17 00:00:00 2001 From: Alex Date: Sun, 26 Jan 2025 13:10:29 +0000 Subject: [PATCH 2/3] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 2e261fe9..41e50fe9 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@
-video-example-of-docs-gpt +video-example-of-docs-gpt

Key Features: From 6d68b89ea0ff723563e4bf11f73fd594b6534c4e Mon Sep 17 00:00:00 2001 From: Alex Date: Sun, 26 Jan 2025 15:42:47 +0000 Subject: [PATCH 3/3] fix: history bug on 2nd message --- application/retriever/brave_search.py | 2 +- application/retriever/classic_rag.py | 2 +- application/retriever/duckduck_search.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/application/retriever/brave_search.py b/application/retriever/brave_search.py index efcae8ab..08b16bc0 100644 --- a/application/retriever/brave_search.py +++ b/application/retriever/brave_search.py @@ -71,7 +71,7 @@ class BraveRetSearch(BaseRetriever): for doc in docs: yield {"source": doc} - if len(self.chat_history) > 1: + if len(self.chat_history) > 0: for i in self.chat_history: if "prompt" in i and "response" in i: messages_combine.append({"role": "user", "content": i["prompt"]}) diff --git a/application/retriever/classic_rag.py b/application/retriever/classic_rag.py index b3735a96..d4c7d755 100644 --- a/application/retriever/classic_rag.py +++ b/application/retriever/classic_rag.py @@ -71,7 +71,7 @@ class ClassicRAG(BaseRetriever): for doc in docs: yield {"source": doc} - if len(self.chat_history) > 1: + if len(self.chat_history) > 0: for i in self.chat_history: if "prompt" in i and "response" in i: messages_combine.append({"role": "user", "content": i["prompt"]}) diff --git a/application/retriever/duckduck_search.py b/application/retriever/duckduck_search.py index 321c6fd9..c6386410 100644 --- a/application/retriever/duckduck_search.py +++ b/application/retriever/duckduck_search.py @@ -88,7 +88,7 @@ class DuckDuckSearch(BaseRetriever): for doc in docs: yield {"source": doc} - if len(self.chat_history) > 1: + if len(self.chat_history) > 0: for i in self.chat_history: if "prompt" in i and "response" in i: messages_combine.append({"role": "user", "content": i["prompt"]})