From e02094de5baac85613855c8a6c9ae1298324ad0e Mon Sep 17 00:00:00 2001 From: "t.me/xtekky" <98614666+xtekky@users.noreply.github.com> Date: Sun, 30 Apr 2023 12:42:21 +0100 Subject: added a site and some refratoring --- testing/theb_test.py | 5 +++++ testing/useless_test.py | 27 +++++++++++++++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 testing/theb_test.py create mode 100644 testing/useless_test.py (limited to 'testing') diff --git a/testing/theb_test.py b/testing/theb_test.py new file mode 100644 index 00000000..0fd2ec8b --- /dev/null +++ b/testing/theb_test.py @@ -0,0 +1,5 @@ +from gpt4free import theb + +for token in theb.Completion.create('hello world'): + print(token, end='', flush=True) + print('asdsos') \ No newline at end of file diff --git a/testing/useless_test.py b/testing/useless_test.py new file mode 100644 index 00000000..9b613aac --- /dev/null +++ b/testing/useless_test.py @@ -0,0 +1,27 @@ +from gpt4free import usesless + +message_id = "" +while True: + prompt = input("Question: ") + if prompt == "!stop": + break + + req = usesless.Completion.create(prompt=prompt, parentMessageId=message_id) + + print(f"Answer: {req['text']}") + message_id = req["id"] + + +import gpt4free + +message_id = "" +while True: + prompt = input("Question: ") + if prompt == "!stop": + break + + req = gpt4free.Completion.create(provider = gpt4free.Provider.UseLess, + prompt=prompt, parentMessageId=message_id) + + print(f"Answer: {req['text']}") + message_id = req["id"] \ No newline at end of file -- cgit v1.2.3