From cdae4ec6269f35a60cc2bd3b9671b99a1db6c1e2 Mon Sep 17 00:00:00 2001 From: star-nox Date: Tue, 30 Jan 2024 18:19:54 -0600 Subject: [PATCH 1/2] testing onResponseCompletion --- ai_ta_backend/nomic_logging.py | 1 + 1 file changed, 1 insertion(+) diff --git a/ai_ta_backend/nomic_logging.py b/ai_ta_backend/nomic_logging.py index 604041da..8f15bb34 100644 --- a/ai_ta_backend/nomic_logging.py +++ b/ai_ta_backend/nomic_logging.py @@ -64,6 +64,7 @@ def log_convo_to_nomic(course_name: str, conversation) -> str: """ print(f"in log_convo_to_nomic() for course: {course_name}") + print("type of conversation:", type(conversation)) conversation = json.loads(conversation) messages = conversation['conversation']['messages'] user_email = conversation['conversation']['user_email'] From 22314b532f6ed633a442c4122cff1811e03a4d88 Mon Sep 17 00:00:00 2001 From: star-nox Date: Tue, 30 Jan 2024 18:35:07 -0600 Subject: [PATCH 2/2] commented json.loads() inside log function --- ai_ta_backend/nomic_logging.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ai_ta_backend/nomic_logging.py b/ai_ta_backend/nomic_logging.py index 8f15bb34..43946bee 100644 --- a/ai_ta_backend/nomic_logging.py +++ b/ai_ta_backend/nomic_logging.py @@ -65,7 +65,7 @@ def log_convo_to_nomic(course_name: str, conversation) -> str: print(f"in log_convo_to_nomic() for course: {course_name}") print("type of conversation:", type(conversation)) - conversation = json.loads(conversation) + #conversation = json.loads(conversation) messages = conversation['conversation']['messages'] user_email = conversation['conversation']['user_email'] conversation_id = conversation['conversation']['id']