monarch-initiative / ontogpt

LLM-based ontological extraction tools, including SPIRES
https://monarch-initiative.github.io/ontogpt/
BSD 3-Clause "New" or "Revised" License
548 stars 68 forks source link

Update default model for OpenAI #364

Closed caufieldjh closed 2 months ago

caufieldjh commented 2 months ago

The model gpt3.5 doesn't work with the OpenAI API anymore. Using it will produce an error like this:

ERROR:ontogpt.clients.openai_client:OpenAI API connection error: Error code: 404 - {'error': {'message': 'The model `gpt3.5` does not exist or you do not have access to it.', 'type': 'invalid_request_error', 'param': None, 'code': 'model_not_found'}}

That's the default model (set in DEFAULT_MODEL) and should be updated.

caufieldjh commented 2 months ago

The actual issue here is that some functions are passing the first of the alternative_names for a given model rather than the canonical_name. Still going to update the default OpenAI model to gpt-4-turbo.