Coder Social home page Coder Social logo

Comments (5)

RohitX0X avatar RohitX0X commented on June 24, 2024 1

#5

solved here^

from gpt-investor.

magiccub04 avatar magiccub04 commented on June 24, 2024

I use OpenAI model gpt-3.5-turbo-0613 to run this code but i get
Error code: 404 - {'error': {'message': 'The model API_MODEL does not exist or you do not have access to it.', 'type': 'invalid_request_error', 'param': None, 'code': 'model_not_found'}}

from openai import AzureOpenAI, OpenAI
load_dotenv()
API_KEY = "OpenAI_key"  # Replace with your OpenAI API or AzureOpenAI key
client = OpenAI(api_key = API_KEY)

HOSTED_IN_AZURE_PLATFORM = False  # Make it to True/False if your service is Azure Open AI or OpenAI respectively.
if(HOSTED_IN_AZURE_PLATFORM):
    API_ENDPOINT= "<Your_Azure_API_endpoint>"
    API_MODEL="<gpt-3.5-turbo-0613>"
    API_VERSION="<Your_Azure_API_version>"

    client = AzureOpenAI(api_key = API_KEY,api_version=API_VERSION,azure_endpoint=API_ENDPOINT)

from gpt-investor.

RohitX0X avatar RohitX0X commented on June 24, 2024

The issue is with client.chat completions… if you are using open ai then remove model in the create() call….

Edit: sorry, i read the error mssg wrongly ,

firstly, put API_MODEL="gpt-3.5-turbo-0613" just below the API_KEY line
Also , You need to name it as , API_MODEL="gpt-3.5-turbo-0613" instead of API_MODEL="<gpt-3.5-turbo-0613>"

from gpt-investor.

RohitX0X avatar RohitX0X commented on June 24, 2024

Updated my PR , you can check the corrections

from gpt-investor.

arsaboo avatar arsaboo commented on June 24, 2024

May be out of scope for this PR, but can we include support for local llms (e.g., Ollama).

from gpt-investor.

Related Issues (10)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.