From aa63ffc75414a4d01d800d3985498a03f78ccae1 Mon Sep 17 00:00:00 2001 From: mtuszowski Date: Thu, 14 Nov 2024 22:56:34 +0100 Subject: [PATCH] aha --- ai_functions.py | 1 - test_ai.py | 39 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 39 insertions(+), 1 deletion(-) create mode 100644 test_ai.py diff --git a/ai_functions.py b/ai_functions.py index f83c2f3..9cb4aa4 100644 --- a/ai_functions.py +++ b/ai_functions.py @@ -337,7 +337,6 @@ async def hammer_assitant_chat(message): thread_id=assistant_data[3].id ) reply_content = messsages.first().content - reply_content.text.value logger.info(reply_content) logger.info(reply_content.text.value) done = True diff --git a/test_ai.py b/test_ai.py new file mode 100644 index 0000000..9077295 --- /dev/null +++ b/test_ai.py @@ -0,0 +1,39 @@ +Message( + id='msg_3eWSdgbcU8sbCmJK2momOgQQ', + assistant_id='asst_06eZiwvYNK3MR34suFP60gvg', + attachments=[], + completed_at=None, + content=[TextContentBlock(text=Text( + annotations=[], + value='Cześć! Oto coś do przemyślenia: \n\n„Sukces to suma niewielkich wysiłków powtarzanych dzień po dniu.” — Robert Collier\n\nTo przypomina nam, że często to nie wielkie działania, ale konsekwentne, małe kroki prowadzą do osiągnięcia celu. Jak mogę Ci dzisiaj pomóc?'), + type='text')], + created_at=1731620112, + incomplete_at=None, + incomplete_details=None, + metadata={}, + object='thread.message', + role='assistant', + run_id='run_JGjWQTCEkDcEYpyCJnrkZU8Q', + status=None, + thread_id='thread_dDEjGbGm6ICfG75u0KKpoVxD'), +Message( + id='msg_GFcnfCFgAthGm2D3oE5d0ZkQ', + assistant_id=None, + attachments=[], + completed_at=None, + content=[ + TextContentBlock(text=Text( + annotations=[], + value='Cześć! Powiedz coś mądrego'), + type='text')], + created_at=1731620110, + incomplete_at=None, + incomplete_details=None, + metadata={}, + object='thread.message', + role='user', + run_id=None, + status=None, + thread_id='thread_dDEjGbGm6ICfG75u0KKpoVxD')], + object='list', +first_id='msg_3eWSdgbcU8sbCmJK2momOgQQ', last_id='msg_GFcnfCFgAthGm2D3oE5d0ZkQ', has_more=False)