From c7f00a9dac6701f025f5494de268e3aaf680ea6a Mon Sep 17 00:00:00 2001 From: "t.me/xtekky" <98614666+xtekky@users.noreply.github.com> Date: Tue, 25 Apr 2023 18:36:51 +0100 Subject: _ --- ora/_jwt.py | 4 ++-- ora_test.py | 15 +++++++++++++++ testing/ora_test.py | 15 --------------- 3 files changed, 17 insertions(+), 17 deletions(-) create mode 100644 ora_test.py delete mode 100644 testing/ora_test.py diff --git a/ora/_jwt.py b/ora/_jwt.py index cc8b2349..61f71332 100644 --- a/ora/_jwt.py +++ b/ora/_jwt.py @@ -62,14 +62,14 @@ spd4eADxTm2m0GR7bhVEIbYfc0aAzIoWDpVs4V3vmx+bdRbppFxV1aS/r0g= header = { 'alg': 'RS256', 'typ': 'JWT', - 'kid': '0d1bb0d7-45e4-445c-889e-57419470a570' + 'kid': '1c8a5da7-527e-4bee-aa8d-aabda16c59ce' } payload = { **json_data, 'iat': int(datetime.now().timestamp()), 'exp': int((datetime.now() + timedelta(minutes=10)).timestamp()), - 'iss': 'https://ora.sh' + 'iss': 'https://rick.roll' } return jwt.encode(payload, private_key, algorithm='RS256', headers=header) \ No newline at end of file diff --git a/ora_test.py b/ora_test.py new file mode 100644 index 00000000..5144be14 --- /dev/null +++ b/ora_test.py @@ -0,0 +1,15 @@ +import ora + + +# create model +model = ora.CompletionModel.create( + system_prompt = 'You are ChatGPT, a large language model trained by OpenAI. Answer as concisely as possible', + description = 'ChatGPT Openai Language Model', + name = 'gpt-3.5') + +# init conversation (will give you a conversationId) +init = ora.Completion.create( + model = model, + prompt = 'hello world') + +print(init.completion.choices[0].text) \ No newline at end of file diff --git a/testing/ora_test.py b/testing/ora_test.py deleted file mode 100644 index 5144be14..00000000 --- a/testing/ora_test.py +++ /dev/null @@ -1,15 +0,0 @@ -import ora - - -# create model -model = ora.CompletionModel.create( - system_prompt = 'You are ChatGPT, a large language model trained by OpenAI. Answer as concisely as possible', - description = 'ChatGPT Openai Language Model', - name = 'gpt-3.5') - -# init conversation (will give you a conversationId) -init = ora.Completion.create( - model = model, - prompt = 'hello world') - -print(init.completion.choices[0].text) \ No newline at end of file -- cgit v1.2.3