-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
The official OpenAI API has an endpoint at /v1/models to list available models. Our current /models endpoint is a native one.
To improve compatibility, we should add the official /v1/models endpoint.
Acceptance Criteria
- A new GET endpoint is created at
/v1/models. - The endpoint reuses the existing list_models logic but formats the response to exactly match the OpenAI specification.
- The JSON response should look like this:
{
"object": "list",
"data": [
{
"id": "model-id-0",
"object": "model",
"created": 1686935002,
"owned_by": "organization-owner"
},
{
"id": "model-id-1",
"object": "model",
"created": 1686935002,
"owned_by": "organization-owner",
},
{
"id": "model-id-2",
"object": "model",
"created": 1686935002,
"owned_by": "openai"
},
],
"object": "list"
}