Spaces:
Running
Running
Update README.md
Browse files
README.md
CHANGED
@@ -14,14 +14,13 @@ Do you want to consult with a Dentist? Speaking Hebrew? Consulting with Dentist
|
|
14 |
|
15 |
Warning: The Agent (Chatbot) can still hallucinate and make up "fake" facts and shouldn’t be an alternative for an expert Dentist. the use of this Chatbot is on your responsibility only.
|
16 |
|
17 |
-
This RAG Agent based on Q&A data collected from 3 top Israeli forums. Data was collected using scraper, and saved into a SQL DB. Then, the titles & questions were embedded into vectors using free 'MPA/sambert' HuggingFace Encoder Model (this model found to be performing well on Hebrew Medical Jargon). The Vectors were
|
|
|
18 |
Now, all is left is the the RAG Agent which is composed from a Retriever, Reranker, and a Generator:
|
19 |
4) The Retriever embeds the user question (using the free 'MPA/sambert' HuggingFace Encoder Model) uses an ANN search with a cosine similarity metric and the top_k variable equals to 50.
|
20 |
-
5) The Reranker
|
21 |
6) The Generator used is from a paid API -Anthropic Claude Sonnet 3.5 - a decoder that is not trained over the medical jargon - however with the right prompt and the right context the results are pretty good.
|
22 |
|
23 |
-
Disclaimer: So far, the Agent has only one question at a time capacity, a problem that will be addressed in the future. Stay tuned.
|
24 |
-
|
25 |
The whole work from inception to completion was done by me (Eli Borodach)
|
26 |
|
27 |
|
|
|
14 |
|
15 |
Warning: The Agent (Chatbot) can still hallucinate and make up "fake" facts and shouldn’t be an alternative for an expert Dentist. the use of this Chatbot is on your responsibility only.
|
16 |
|
17 |
+
This RAG Agent based on Q&A data collected from 3 top Israeli forums. Data was collected using scraper, and saved into a SQL DB. Then, the titles & questions were embedded into vectors using free 'MPA/sambert' HuggingFace Encoder Model (this model found to be performing well on Hebrew Medical Jargon). The Vectors were stored a hundread at a time, into NoSQL Pinecone Vector Database, with answer_id as metadata.
|
18 |
+
The answers were converted into vector embedding using the same free Encoder ('MPA/sambert'), and stored in Pinecone with different key and with the answer as metadata
|
19 |
Now, all is left is the the RAG Agent which is composed from a Retriever, Reranker, and a Generator:
|
20 |
4) The Retriever embeds the user question (using the free 'MPA/sambert' HuggingFace Encoder Model) uses an ANN search with a cosine similarity metric and the top_k variable equals to 50.
|
21 |
+
5) The Reranker fetches the answers vectors suing their list of top_k ids and answers as metadata in a second scan from the PineCone database resorts the answers, then cosine similarity is calculated using the sklearn method. Afterwards, it selects the the top_n (equal to 5) answers, when each answer should be similar to the question embedding with a threshold of 0.7 or higher.
|
22 |
6) The Generator used is from a paid API -Anthropic Claude Sonnet 3.5 - a decoder that is not trained over the medical jargon - however with the right prompt and the right context the results are pretty good.
|
23 |
|
|
|
|
|
24 |
The whole work from inception to completion was done by me (Eli Borodach)
|
25 |
|
26 |
|