Skip to content

Commit

Permalink
📟 ChatCLI Example
Browse files Browse the repository at this point in the history
  • Loading branch information
shroominic committed Sep 3, 2023
1 parent 9ca775b commit 80cbbab
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions examples/chat_cli.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
from codeinterpreterapi import CodeInterpreterSession, settings

settings.MODEL = "gpt-4"

print(
"AI: Hello, I am the "
"code interpreter agent.\n"
"Ask me todo something and "
"I will use python to do it!\n"
)

with CodeInterpreterSession() as session:
while True:
session.generate_response_sync(input("\nUser: ")).show()

0 comments on commit 80cbbab

Please sign in to comment.