feat(providers): add GitHub Models as free provider (#2344)

Integrated into release/v3.8.0 — adds GitHub Models as a free provider with 14 models (GPT-4.1, o3, DeepSeek-R1, Llama 4, Grok 3 etc.)
This commit is contained in:
Paijo
2026-05-18 05:40:50 +07:00
committed by GitHub
parent 749197466f
commit c2451038a0
2 changed files with 49 additions and 0 deletions

View File

@@ -933,6 +933,43 @@ export const REGISTRY: Record<string, RegistryEntry> = {
],
},
"github-models": {
id: "github-models",
alias: "ghm",
format: "openai",
executor: "default",
baseUrl: "https://models.github.ai/inference/chat/completions",
modelsUrl: "https://models.github.ai/inference/models",
authType: "apikey",
authHeader: "Authorization",
authPrefix: "Bearer",
headers: {
"X-GitHub-Api-Version": "2022-11-28",
Accept: "application/vnd.github+json",
},
defaultContextLength: 128000,
models: [
{ id: "openai/gpt-4.1", name: "GPT-4.1 (Free)", contextLength: 1047576 },
{ id: "openai/gpt-4o", name: "GPT-4o (Free)", contextLength: 128000 },
{ id: "openai/gpt-4o-mini", name: "GPT-4o Mini (Free)", contextLength: 128000 },
{ id: "openai/o1", name: "o1 (Free)", contextLength: 200000 },
{ id: "openai/o3", name: "o3 (Free)", contextLength: 200000 },
{ id: "openai/o4-mini", name: "o4-mini (Free)", contextLength: 200000 },
{ id: "deepseek/DeepSeek-R1", name: "DeepSeek R1 (Free)", contextLength: 131072 },
{
id: "meta/Llama-4-Maverick-17B-128E-Instruct",
name: "Llama 4 Maverick (Free)",
contextLength: 131072,
},
{ id: "xai/grok-3", name: "Grok 3 (Free)", contextLength: 131072 },
{ id: "mistral-ai/Mistral-Medium-3", name: "Mistral Medium 3 (Free)", contextLength: 128000 },
{ id: "cohere/Cohere-command-a", name: "Cohere Command A (Free)", contextLength: 128000 },
{ id: "microsoft/Phi-4", name: "Phi-4 (Free)", contextLength: 16384 },
{ id: "openai/text-embedding-3-large", name: "Text Embedding 3 Large (Free)" },
{ id: "openai/text-embedding-3-small", name: "Text Embedding 3 Small (Free)" },
],
},
kiro: {
id: "kiro",
alias: "kr",

View File

@@ -876,6 +876,18 @@ export const APIKEY_PROVIDERS = {
passthroughModels: true,
authHint: "No auth required. API accepts any non-empty string as key for identification.",
},
"github-models": {
id: "github-models",
alias: "ghm",
name: "GitHub Models",
icon: "code",
color: "#238636",
textIcon: "GH",
website: "https://github.com/marketplace/models",
hasFree: true,
freeNote: "Free GPT-5, o-series, DeepSeek-R1, Llama 4, Grok 3 — GitHub account only.",
authHint: "Create a GitHub PAT with 'models: read' scope at github.com/settings/tokens",
},
"cloudflare-ai": {
id: "cloudflare-ai",
alias: "cf",