Skip to content

Forum in maintenance, we will back soon 🙂

Connect Python with...
 
Notifications
Clear all

Connect Python with Open AI API

14 Posts
6 Users
3 Reactions
703 Views
(@sivaram-bandaru)
Posts: 43
Trusted Member Customer
Topic starter
 

When I am running my first API by trying the code Hassan showed in the course, I get the below message. This is my first trial and it already says I exceeded the quota. Do I need to upgrade?

"You exceeded your current quota, please check your plan and billing details"

 
Posted : 09/09/2023 6:07 pm
Mahim reacted
Hasan Aboul Hasan
(@admin)
Posts: 1253
Member Admin
 

you need an active subscription to work with the API

 
Posted : 09/10/2023 7:12 am
(@sivaram-bandaru)
Posts: 43
Trusted Member Customer
Topic starter
 

Which subscription Hasan? Is it given in the course? If yes, can you please point me to the course page?

 
Posted : 09/10/2023 7:49 pm
Hasan Aboul Hasan
(@admin)
Posts: 1253
Member Admin
 

I mean an active OpenAI subscription.

 
Posted : 09/11/2023 3:57 pm
SSAdvisor
(@ssadvisor)
Posts: 1139
Noble Member
 

@sivaram-bandaru go to https://platform.openai.com/account/billing/payment-methods and add your payment method.

Regards,
Earnie Boyd, CEO
Seasoned Solutions Advisor LLC
Schedule 1-on-1 help
Join me on Slack

 
Posted : 11/03/2023 2:48 pm
(@mahim21)
Posts: 1
New Member
 

The idea seems exciting. Connecting python with OpeAi. Need to take a quick peak 😮 

 

 

 
Posted : 11/22/2023 9:36 am
(@husein)
Posts: 531
Member Moderator
 

@mahim21 It really is! Hasan even shows many interesting examples and beneficial automation scripts in the course. 

I advise you to enroll it is very beneficial.

 
Posted : 11/22/2023 10:55 am
(@google-solarnebula)
Posts: 5
Member
 

I am learning the course biulding an api and followed the google suggestions api in the first section. but it is showing error and saying the method is changed.

 

image

 

 
Posted : 01/13/2024 11:11 pm
SSAdvisor
(@ssadvisor)
Posts: 1139
Noble Member
 

@google-solarnebula I don't see an error just the warning that you're using a development server. Did you try going to http://localhost:5000/ and http://localhost:5000/example?

Regards,
Earnie Boyd, CEO
Seasoned Solutions Advisor LLC
Schedule 1-on-1 help
Join me on Slack

 
Posted : 01/14/2024 4:00 am
(@husein)
Posts: 531
Member Moderator
 

@google-solarnebula Hello friend I see you're a premium member, make sure to add your questions on the premium forum, usually the response is much faster over there. And join the discord channel if you still havent.

 
Posted : 01/14/2024 3:10 pm
SSAdvisor reacted
(@google-solarnebula)
Posts: 5
Member
 

I got the same error. did you find the solution?

 

You tried to access openai.ChatCompletion, but this is no longer supported in openai>=1.0.0 - see the README at https://github.com/openai/openai-python for the API.

You can run `openai migrate` to automatically upgrade your codebase to use the 1.0.0 interface.

Alternatively, you can pin your installation to the old version, e.g. `pip install openai==0.28`

A detailed migration guide is available here: https://github.com/openai/openai-python/discussions/742

 
Posted : 01/17/2024 6:58 pm
(@google-solarnebula)
Posts: 5
Member
 

@ssadvisor I tried, but there is no output in the host

 
Posted : 01/17/2024 7:00 pm
SSAdvisor
(@ssadvisor)
Posts: 1139
Noble Member
 

@google-solarnebula

yes, the openai module has been upgraded. You can use the previous version with

pip install --upgrade openai==0.28

which will work with the course code or you can update the course libraries by downloading the zip file at

https://github.com/hassancs91/PE-Course-codes

which contains the updated code for the new version of the openai module.

Regards,
Earnie Boyd, CEO
Seasoned Solutions Advisor LLC
Schedule 1-on-1 help
Join me on Slack

 
Posted : 01/17/2024 7:39 pm
Hasan Aboul Hasan
(@admin)
Posts: 1253
Member Admin
 

@google-solarnebula, please update your codes and get my new codes from the course; this is outdated as openAI updated their packages.

 
Posted : 01/20/2024 9:00 am
Share: