mirror of
https://github.com/StanGirard/quivr.git
synced 2024-11-23 21:22:35 +03:00
ea227df30e
https://github.com/StanGirard/quivr/assets/63923024/08554dd5-2765-436a-b900-48b38d582f6c https://github.com/StanGirard/quivr/issues/1389
14 lines
378 B
Python
14 lines
378 B
Python
from typing import Optional
|
|
from uuid import UUID
|
|
|
|
from models import Chat, get_supabase_db
|
|
from models.databases.supabase.chats import QuestionAndAnswer
|
|
|
|
|
|
def add_question_and_answer(
|
|
chat_id: UUID, question_and_answer: QuestionAndAnswer
|
|
) -> Optional[Chat]:
|
|
supabase_db = get_supabase_db()
|
|
|
|
return supabase_db.add_question_and_answer(chat_id, question_and_answer)
|