Never stop coding. Free MIT AI gateway: one endpoint, 375 providers (150+ free), 1,400+ models Kimi, Claude, GPT, Gemini, GLM, DeepSeek, MiniMax. Works with Claude Code, Codex, Cursor, OpenCode, Cline & Copilot. Quota-aware auto-fallback, RTK+Caveman compression saves 15-95% tokens, MCP/A2A, Desktop/PWA. Built by 900+ contributors
TypeScript a2aai-agentsai-gatewayanthropicclaudeclaude-codeclinecodexcopilotcursordeepseekfree-aigeminikimillm-gatewaymcpopenaiopenai-proxyqwentoken-saver
// Antigravity CLI (`agy`) model catalog.
//
// Models are derived from the shared Antigravity catalog (antigravitySharedModels.ts)
// which is the single source of truth for both agy and antigravity surfaces.
// The `agy` provider reuses the `antigravity` executor/translator (identical backend).
//
// To add a model to both surfaces: edit antigravitySharedModels.ts.
// To add a model to CLI only: add an entry to `add` below.
// To hide a model from CLI only: add its id to `remove` below.
import { ANTIGRAVITY_QUOTA_VISIBLE_NON_CHAT_MODEL_IDS } from "./antigravityModelAliases.ts";
import { ANTIGRAVITY_SHARED_MODELS, buildSurfaceCatalog } from "./antigravitySharedModels.ts";
export const AGY_PUBLIC_MODELS = buildSurfaceCatalog(ANTIGRAVITY_SHARED_MODELS, {
add: [], // CLI-only models (currently none)
remove: [], // Models hidden from CLI (currently none)
});
const AGY_PUBLIC_MODEL_IDS = new Set(AGY_PUBLIC_MODELS.map((model) => model.id));
const AGY_NON_CHAT_MODEL_IDS = new Set(["tab_flash_lite_preview", "tab_jump_flash_lite_preview"]);
const AGY_NON_CHAT_MODEL_PATTERN =
/(?:^|[-_])(image|imagen|audio|tts|embedding|embed|video|veo)(?:[-_]|$)/i;
const AGY_RETIRED_MODEL_IDS = new Set([
"gemini-3-pro-preview",
"gemini-3.1-pro",
// Per-tier 3.7 ids are absent from the live roster (discussion #15568) and alias onto the
// shared "-tiered" id. `gemini-3.7-flash-tiered`, `gemini-3.6-flash-tiered` and
// `gemini-3-flash` ARE still served live, so they are deliberately NOT retired here.
"gemini-3.7-flash",
"gemini-3.7-flash-high",
"gemini-3.7-flash-medium",
"gemini-3.7-flash-low",
"gemini-3.6-flash-high",
"gemini-3.6-flash-medium",
"gemini-3.6-flash-low",
"gemini-3-flash-agent",
"gemini-3.5-flash",
"gemini-3.5-flash-extra-low",
"gemini-3.5-flash-low",
"gemini-3.5-flash-high",
"gemini-3.5-flash-medium",
"gemini-3.5-flash-preview",
"gemini-2.5-pro",
"gemini-2.5-flash-thinking",
"gemini-2.5-flash",
"gemini-2.5-flash-lite",
"gemini-2.5-computer-use-preview-10-2025",
]);
const AGY_CLIENT_VISIBLE_MODEL_NAMES = Object.freeze(
AGY_PUBLIC_MODELS.reduce<Record<string, string>>((acc, model) => {
acc[model.id] = model.name;
return acc;
}, {})
);
export function getClientVisibleAgyModelName(modelId: string, fallbackName?: string): string {
return AGY_CLIENT_VISIBLE_MODEL_NAMES[modelId] || fallbackName || modelId;
}
export function isUserCallableAgyModelId(modelId: string): boolean {
return !!modelId && AGY_PUBLIC_MODEL_IDS.has(modelId);
}
export function isDiscoverableAgyModelId(modelId: string): boolean {
const id = modelId ? modelId.trim() : "";
return (
!!id &&
!id.startsWith("chat_") &&
!id.startsWith("tab_") &&
!id.endsWith("_weekly") &&
!AGY_NON_CHAT_MODEL_IDS.has(id) &&
!AGY_RETIRED_MODEL_IDS.has(id) &&
!AGY_NON_CHAT_MODEL_PATTERN.test(id)
);
}
/**
* Quota visibility is broader than chat discovery (same rule as Antigravity): image-only models
* keep their live quota buckets in Provider Limits even though they are not chat models, so
* `AGY_NON_CHAT_MODEL_PATTERN` must not hide them.
*/
export function isUserVisibleAgyQuotaModelId(modelId: string): boolean {
const id = modelId.trim();
if (!id) return false;
return isDiscoverableAgyModelId(id) || ANTIGRAVITY_QUOTA_VISIBLE_NON_CHAT_MODEL_IDS.has(id);
}