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

EPIC: refactor API logic #144

Closed K-Schubert closed 1 month ago

K-Schubert commented 2 months ago

Description

Refactor API logic with one folder in eak-copilot repo per service.

Move logic for autocomplete from api/ to autocomplete/. Rename "fastapi" service to "autocomplete" in docker-compose.yml. Update dependency on fastapi to autocomplete service. Rename /search to /exact_match. Add /fuzzy_match and /semantic_search_match endpoints to autocomplete/app/main.py Delete "chatbot" folder and chatbot service in docker-compose.yml Update .env.example REACT_APP_QUERY_AUTOCOMPLETE_API_URL with autocomplete service url. Update autocomplete/requirements.txt with up-to-date library versions. Merge feature/setup-baseline-rag branch with feature/144-refactor-api-logic branch. Update rag/requirements.txt. Refactor API logic with asyncpg instead of psycopg2. Create 'faq_embeddings' table in db/init.sql. Add indexing/app/main.py, indexing/Dockerfile and indexing/requirements.txt with dummy endpoints. Add Add indexing service in docker-compose.yml.

Refactor API endpoints according to best practice naming conventions and functionality.

171

143

148

33

149

150