From 3b79b8a38f9a0d200e5c47779f76c8d65d49ade7 Mon Sep 17 00:00:00 2001 From: Jeff Vestal <53237856+jeffvestal@users.noreply.github.com> Date: Wed, 12 Apr 2023 10:35:31 -0500 Subject: [PATCH] Update README.md --- README.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/README.md b/README.md index 394b257..5188985 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,17 @@ # ElasticDocs_GPT Combining the search power of Elasticsearch with the Question Answering power of GPT + +![diagram](https://raw.githubusercontent.com/jeffvestal/ElasticDocs_GPT/main/ElasticChat%20GPT%20Diagram%20-%20No%20line%20text.jpeg) + +1. Python interface accepts user questions +- Generate a hybrid search request for Elasticsearch +- BM25 match on the title field +- kNN search on the title-vector field +- Boost kNN search results to align scores +- Set size=1 to return only the top scored document +2. Search request is sent to Elasticsearch +3. Documentation body and original url are returned to python +4. API call is made to OpenAI ChatCompletion +- Prompt: "answer this question using only this document " +5. Generated response is returned to python +6. Python adds on original documentation source url to generated response and prints it to the screen for the user