diff --git a/internal/registry/model_definitions.go b/internal/registry/model_definitions.go index 86d119fa..1b69021d 100644 --- a/internal/registry/model_definitions.go +++ b/internal/registry/model_definitions.go @@ -129,7 +129,19 @@ func LookupStaticModelInfo(modelID string) *ModelInfo { // These models are available through the GitHub Copilot API at api.githubcopilot.com. func GetGitHubCopilotModels() []*ModelInfo { now := int64(1732752000) // 2024-11-27 - return []*ModelInfo{ + gpt4oEntries := []struct { + ID string + DisplayName string + Description string + }{ + {ID: "gpt-4o-2024-11-20", DisplayName: "GPT-4o (2024-11-20)", Description: "OpenAI GPT-4o 2024-11-20 via GitHub Copilot"}, + {ID: "gpt-4o-2024-08-06", DisplayName: "GPT-4o (2024-08-06)", Description: "OpenAI GPT-4o 2024-08-06 via GitHub Copilot"}, + {ID: "gpt-4o-2024-05-13", DisplayName: "GPT-4o (2024-05-13)", Description: "OpenAI GPT-4o 2024-05-13 via GitHub Copilot"}, + {ID: "gpt-4o", DisplayName: "GPT-4o", Description: "OpenAI GPT-4o via GitHub Copilot"}, + {ID: "gpt-4-o-preview", DisplayName: "GPT-4-o Preview", Description: "OpenAI GPT-4-o Preview via GitHub Copilot"}, + } + + models := []*ModelInfo{ { ID: "gpt-4.1", Object: "model", @@ -141,6 +153,23 @@ func GetGitHubCopilotModels() []*ModelInfo { ContextLength: 128000, MaxCompletionTokens: 16384, }, + } + + for _, entry := range gpt4oEntries { + models = append(models, &ModelInfo{ + ID: entry.ID, + Object: "model", + Created: now, + OwnedBy: "github-copilot", + Type: "github-copilot", + DisplayName: entry.DisplayName, + Description: entry.Description, + ContextLength: 128000, + MaxCompletionTokens: 16384, + }) + } + + return append(models, []*ModelInfo{ { ID: "gpt-5", Object: "model", @@ -422,7 +451,7 @@ func GetGitHubCopilotModels() []*ModelInfo { MaxCompletionTokens: 16384, SupportedEndpoints: []string{"/chat/completions", "/responses"}, }, - } + }...) } // GetKiroModels returns the Kiro (AWS CodeWhisperer) model definitions