CdC-SI / eak-copilot

The official repository of the EAK-Copilot project as part of the Innovation Fellowship 2024.
https://cdc-si.github.io/eak-copilot/
GNU General Public License v3.0
4 stars 0 forks source link

setup /get_docs endpoint in backend #134

Closed K-Schubert closed 2 months ago

K-Schubert commented 2 months ago

Setup a document retrieval endpoint in backend.

Do a semantic similarity match (cosine similarity) on indexed documents in postgres vector DB.

Takes as input a user query such as: {"query": query} and returns a response such as {"contextDocs": docs, "sourceUrl": url}.

Will be called from the frontend when a user inputs a query that doesn't match an autocomplete suggestion.