openai4j icon indicating copy to clipboard operation
openai4j copied to clipboard

List models

Open the-gigi opened this issue 1 year ago • 0 comments

Is your feature request related to a problem? Please describe.

It looks like there is no way to list the models.

See https://platform.openai.com/docs/api-reference/models

Describe the solution you'd like I would like a listModels() method that returns all the models.

Describe alternatives you've considered I can get it myself using any HTTP client, but it breaks the experience of working with a Java library that wraps an API.

The other alternative is of course to use another library :-)

Additional context

btw, the terminology of openai4j, which uses Model to describe its domain objects: ChatCompletionModel, ImageCompletionModel, etc is confusing when dealing with language models. Ideally , there shouldn't be overloading of the term Model.

the-gigi avatar Jan 28 '24 17:01 the-gigi