Skip to content

Commit

Permalink
test: add simple_chatbot_async.py
Browse files Browse the repository at this point in the history
  • Loading branch information
luochen1990 committed Aug 11, 2024
1 parent 26917a2 commit 318ce37
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions test/examples/chat_bot/simple_chatbot_async.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import pytest
from ai_powered import ChatBot
from ai_powered.colors import gray, green

@pytest.mark.asyncio
async def test_simple_chatbot_async():
bot = ChatBot()
print(green(await bot.chat('hello, please tell me the result of 2^10 + 3^4')))
print(green(await bot.chat('and what is above result divided by 2?')))
print(gray(f"{bot.conversation}"))

0 comments on commit 318ce37

Please sign in to comment.