choonkeat / elm-openai / OpenAI.Model

The OpenAI API is powered by a family of models with different capabilities and price points. You can also customize our base models for your specific use case with fine-tuning.

See https://beta.openai.com/docs/models

getModel : OpenAI.ModelID.ModelID -> Ext.Http.TaskInput (Ext.Http.Error String) Model

https://beta.openai.com/docs/api-reference/models/retrieve

Retrieves a model instance, providing basic information about the model such as the owner and permissioning.

listModels : Ext.Http.TaskInput (Ext.Http.Error String) (List Model)

https://beta.openai.com/docs/api-reference/models/list

Lists the currently available models, and provides basic information about each one such as the owner and availability.


type alias Model =
{ id : String
, object : String
, owned_by : String
, permission : List Permission 
}

You can refer to the Models documentation to understand what models are available and the differences between them.

https://platform.openai.com/docs/models


type alias Permission =
{ id : String
, object : String
, created : Time.Posix
, allow_create_engine : Basics.Bool
, allow_sampling : Basics.Bool
, allow_logprobs : Basics.Bool
, allow_search_indices : Basics.Bool
, allow_view : Basics.Bool
, allow_fine_tuning : Basics.Bool
, organization : String
, group : Maybe String
, is_blocking : Basics.Bool 
}