feat(ai): separate generated model data (#6765)
This commit is contained in:
@@ -8,6 +8,7 @@ dist/
|
||||
packages/*/dist/
|
||||
packages/*/dist-chrome/
|
||||
packages/*/dist-firefox/
|
||||
packages/ai/src/providers/data/
|
||||
*.cpuprofile
|
||||
|
||||
# Environment
|
||||
|
||||
@@ -1553,7 +1553,7 @@ Add a lazy wrapper `src/api/<api-id>.lazy.ts` (`<name>Api()` via `lazyApi()`) so
|
||||
#### 3. Model Generation (`scripts/generate-models.ts`, `scripts/generate-image-models.ts`)
|
||||
|
||||
- Add logic to fetch and parse models from the provider's source (e.g., models.dev API)
|
||||
- Map chat/tool-capable provider model data to the standardized `Model` interface via `scripts/generate-models.ts`; regeneration emits `src/providers/<id>.models.ts` and the aggregator
|
||||
- Map chat/tool-capable provider model data to the standardized `Model` interface via `scripts/generate-models.ts`; regeneration emits structural `src/providers/<id>.models.ts` shards, ignored values in `src/providers/data/`, and the aggregator
|
||||
- Map image-generation provider model data to the standardized `ImagesModel` interface via `scripts/generate-image-models.ts`
|
||||
- Handle provider-specific quirks (pricing format, capability flags, model ID transformations)
|
||||
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
"generate-models": "node scripts/generate-models.ts",
|
||||
"generate-model-catalog": "node scripts/generate-models.ts --strict --json-only --json-output ../../.artifacts/model-catalog",
|
||||
"generate-image-models": "node scripts/generate-image-models.ts",
|
||||
"build": "tsgo -p tsconfig.build.json",
|
||||
"build": "npm run generate-models && tsgo -p tsconfig.build.json && shx rm -rf dist/providers/data && shx cp -r src/providers/data dist/providers/data",
|
||||
"test": "vitest --run",
|
||||
"prepublishOnly": "npm run clean && npm run build"
|
||||
},
|
||||
|
||||
@@ -2287,74 +2287,56 @@ async function generateModels() {
|
||||
}
|
||||
|
||||
const sortedProviderIds = Object.keys(providers).sort();
|
||||
const jsonProviders: Record<string, Record<string, Model<any>>> = {};
|
||||
for (const providerId of sortedProviderIds) {
|
||||
jsonProviders[providerId] = {};
|
||||
for (const modelId of Object.keys(providers[providerId]).sort()) {
|
||||
jsonProviders[providerId][modelId] = providers[providerId][modelId];
|
||||
}
|
||||
}
|
||||
const writeJson = (path: string, value: unknown) => writeFileSync(path, `${JSON.stringify(value)}\n`);
|
||||
|
||||
if (!generatorOptions.jsonOnly) {
|
||||
// Generate TypeScript files: one catalog per provider plus an aggregator
|
||||
// Generate TypeScript structural catalogs and adjacent JSON values.
|
||||
const generatedHeader = `// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
`;
|
||||
const catalogConstName = (providerId: string) =>
|
||||
`${providerId.toUpperCase().replace(/[^A-Z0-9]+/g, "_")}_MODELS`;
|
||||
const providersDir = join(packageRoot, "src/providers");
|
||||
const dataDir = join(providersDir, "data");
|
||||
|
||||
function emitModel(model: Model<any>, indent: string): string {
|
||||
let output = `${indent}"${model.id}": {\n`;
|
||||
output += `${indent}\tid: "${model.id}",\n`;
|
||||
output += `${indent}\tname: "${model.name}",\n`;
|
||||
output += `${indent}\tapi: "${model.api}",\n`;
|
||||
output += `${indent}\tprovider: "${model.provider}",\n`;
|
||||
if (model.baseUrl !== undefined) {
|
||||
output += `${indent}\tbaseUrl: "${model.baseUrl}",\n`;
|
||||
}
|
||||
if (model.headers) {
|
||||
output += `${indent}\theaders: ${JSON.stringify(model.headers)},\n`;
|
||||
}
|
||||
if (model.compat) {
|
||||
output += `${indent}\tcompat: ${JSON.stringify(model.compat)},\n`;
|
||||
}
|
||||
output += `${indent}\treasoning: ${model.reasoning},\n`;
|
||||
if (model.thinkingLevelMap) {
|
||||
output += `${indent}\tthinkingLevelMap: ${JSON.stringify(model.thinkingLevelMap)},\n`;
|
||||
}
|
||||
output += `${indent}\tinput: [${model.input.map(i => `"${i}"`).join(", ")}],\n`;
|
||||
output += `${indent}\tcost: {\n`;
|
||||
output += `${indent}\t\tinput: ${model.cost.input},\n`;
|
||||
output += `${indent}\t\toutput: ${model.cost.output},\n`;
|
||||
output += `${indent}\t\tcacheRead: ${model.cost.cacheRead},\n`;
|
||||
output += `${indent}\t\tcacheWrite: ${model.cost.cacheWrite},\n`;
|
||||
if (model.cost.tiers) {
|
||||
output += `${indent}\t\ttiers: ${JSON.stringify(model.cost.tiers)},\n`;
|
||||
}
|
||||
output += `${indent}\t},\n`;
|
||||
output += `${indent}\tcontextWindow: ${model.contextWindow},\n`;
|
||||
output += `${indent}\tmaxTokens: ${model.maxTokens},\n`;
|
||||
output += `${indent}} satisfies Model<"${model.api}">,\n`;
|
||||
return output;
|
||||
function emitModelShape(model: Model<any>, indent: string): string {
|
||||
return `${indent}${JSON.stringify(model.id)}: Model<${JSON.stringify(model.api)}> & {\n${indent}\tid: ${JSON.stringify(model.id)};\n${indent}\tprovider: ${JSON.stringify(model.provider)};\n${indent}};\n`;
|
||||
}
|
||||
|
||||
const providersDir = join(packageRoot, "src/providers");
|
||||
|
||||
// Remove stale per-provider catalogs
|
||||
// Remove stale per-provider catalogs and their generated values.
|
||||
for (const entry of readdirSync(providersDir)) {
|
||||
if (entry.endsWith(".models.ts")) {
|
||||
rmSync(join(providersDir, entry));
|
||||
}
|
||||
}
|
||||
rmSync(dataDir, { recursive: true, force: true });
|
||||
mkdirSync(dataDir, { recursive: true });
|
||||
|
||||
// Per-provider catalogs (sorted for deterministic output)
|
||||
// Per-provider catalog structure and values (sorted for deterministic output).
|
||||
for (const providerId of sortedProviderIds) {
|
||||
const models = providers[providerId];
|
||||
let output = generatedHeader;
|
||||
output += `import type { Model } from "../types.ts";\n\n`;
|
||||
output += `export const ${catalogConstName(providerId)} = {\n`;
|
||||
const sortedModelIds = Object.keys(models).sort();
|
||||
let output = generatedHeader;
|
||||
output += `import values from "./data/${providerId}.json" with { type: "json" };\n`;
|
||||
output += `import type { Model } from "../types.ts";\n\n`;
|
||||
output += `export const ${catalogConstName(providerId)} = values as {\n`;
|
||||
for (const modelId of sortedModelIds) {
|
||||
output += emitModel(models[modelId], "\t");
|
||||
output += emitModelShape(models[modelId], "\t");
|
||||
}
|
||||
output += `} as const;\n`;
|
||||
output += `};\n`;
|
||||
writeFileSync(join(providersDir, `${providerId}.models.ts`), output);
|
||||
writeJson(join(dataDir, `${providerId}.json`), jsonProviders[providerId]);
|
||||
}
|
||||
console.log(`Generated ${sortedProviderIds.length} catalogs under src/providers/`);
|
||||
console.log(`Generated ${sortedProviderIds.length} catalog structures under src/providers/`);
|
||||
console.log("Generated JSON model values under src/providers/data/");
|
||||
|
||||
// Aggregator
|
||||
let output = generatedHeader;
|
||||
@@ -2371,18 +2353,9 @@ async function generateModels() {
|
||||
}
|
||||
|
||||
if (generatorOptions.jsonOutputDir) {
|
||||
const jsonProviders: Record<string, Record<string, Model<any>>> = {};
|
||||
for (const providerId of sortedProviderIds) {
|
||||
jsonProviders[providerId] = {};
|
||||
for (const modelId of Object.keys(providers[providerId]).sort()) {
|
||||
jsonProviders[providerId][modelId] = providers[providerId][modelId];
|
||||
}
|
||||
}
|
||||
|
||||
const providerOutputDir = join(generatorOptions.jsonOutputDir, "providers");
|
||||
rmSync(generatorOptions.jsonOutputDir, { recursive: true, force: true });
|
||||
mkdirSync(providerOutputDir, { recursive: true });
|
||||
const writeJson = (path: string, value: unknown) => writeFileSync(path, `${JSON.stringify(value)}\n`);
|
||||
writeJson(join(generatorOptions.jsonOutputDir, "models.json"), jsonProviders);
|
||||
writeJson(join(generatorOptions.jsonOutputDir, "providers.json"), sortedProviderIds);
|
||||
for (const providerId of sortedProviderIds) {
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,62 +1,20 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/ant-ling.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const ANT_LING_MODELS = {
|
||||
"Ling-2.6-1T": {
|
||||
id: "Ling-2.6-1T",
|
||||
name: "Ling 2.6 1T",
|
||||
api: "openai-completions",
|
||||
provider: "ant-ling",
|
||||
baseUrl: "https://api.ant-ling.com/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"ant-ling","supportsLongCacheRetention":false},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.06,
|
||||
output: 0.25,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"Ling-2.6-flash": {
|
||||
id: "Ling-2.6-flash",
|
||||
name: "Ling 2.6 Flash",
|
||||
api: "openai-completions",
|
||||
provider: "ant-ling",
|
||||
baseUrl: "https://api.ant-ling.com/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"ant-ling","supportsLongCacheRetention":false},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.01,
|
||||
output: 0.02,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"Ring-2.6-1T": {
|
||||
id: "Ring-2.6-1T",
|
||||
name: "Ring 2.6 1T",
|
||||
api: "openai-completions",
|
||||
provider: "ant-ling",
|
||||
baseUrl: "https://api.ant-ling.com/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"ant-ling","supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null,"low":null,"medium":null,"high":"high","xhigh":"xhigh"},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.06,
|
||||
output: 0.25,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const ANT_LING_MODELS = values as {
|
||||
"Ling-2.6-1T": Model<"openai-completions"> & {
|
||||
id: "Ling-2.6-1T";
|
||||
provider: "ant-ling";
|
||||
};
|
||||
"Ling-2.6-flash": Model<"openai-completions"> & {
|
||||
id: "Ling-2.6-flash";
|
||||
provider: "ant-ling";
|
||||
};
|
||||
"Ring-2.6-1T": Model<"openai-completions"> & {
|
||||
id: "Ring-2.6-1T";
|
||||
provider: "ant-ling";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,257 +1,64 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/anthropic.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const ANTHROPIC_MODELS = {
|
||||
"claude-fable-5": {
|
||||
id: "claude-fable-5",
|
||||
name: "Claude Fable 5",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
compat: {"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 10,
|
||||
output: 50,
|
||||
cacheRead: 1,
|
||||
cacheWrite: 12.5,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-haiku-4-5": {
|
||||
id: "claude-haiku-4-5",
|
||||
name: "Claude Haiku 4.5 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1,
|
||||
output: 5,
|
||||
cacheRead: 0.1,
|
||||
cacheWrite: 1.25,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-haiku-4-5-20251001": {
|
||||
id: "claude-haiku-4-5-20251001",
|
||||
name: "Claude Haiku 4.5",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1,
|
||||
output: 5,
|
||||
cacheRead: 0.1,
|
||||
cacheWrite: 1.25,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4-1": {
|
||||
id: "claude-opus-4-1",
|
||||
name: "Claude Opus 4.1 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 15,
|
||||
output: 75,
|
||||
cacheRead: 1.5,
|
||||
cacheWrite: 18.75,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 32000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4-1-20250805": {
|
||||
id: "claude-opus-4-1-20250805",
|
||||
name: "Claude Opus 4.1",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 15,
|
||||
output: 75,
|
||||
cacheRead: 1.5,
|
||||
cacheWrite: 18.75,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 32000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4-5": {
|
||||
id: "claude-opus-4-5",
|
||||
name: "Claude Opus 4.5 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 25,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4-5-20251101": {
|
||||
id: "claude-opus-4-5-20251101",
|
||||
name: "Claude Opus 4.5",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 25,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4-6": {
|
||||
id: "claude-opus-4-6",
|
||||
name: "Claude Opus 4.6",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
compat: {"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 25,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4-7": {
|
||||
id: "claude-opus-4-7",
|
||||
name: "Claude Opus 4.7",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
compat: {"forceAdaptiveThinking":true,"supportsTemperature":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 25,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4-8": {
|
||||
id: "claude-opus-4-8",
|
||||
name: "Claude Opus 4.8",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
compat: {"forceAdaptiveThinking":true,"supportsTemperature":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 25,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-sonnet-4-5": {
|
||||
id: "claude-sonnet-4-5",
|
||||
name: "Claude Sonnet 4.5 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 3.75,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-sonnet-4-5-20250929": {
|
||||
id: "claude-sonnet-4-5-20250929",
|
||||
name: "Claude Sonnet 4.5",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 3.75,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-sonnet-4-6": {
|
||||
id: "claude-sonnet-4-6",
|
||||
name: "Claude Sonnet 4.6",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
compat: {"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 3.75,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-sonnet-5": {
|
||||
id: "claude-sonnet-5",
|
||||
name: "Claude Sonnet 5",
|
||||
api: "anthropic-messages",
|
||||
provider: "anthropic",
|
||||
baseUrl: "https://api.anthropic.com",
|
||||
compat: {"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 10,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 2.5,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
} as const;
|
||||
export const ANTHROPIC_MODELS = values as {
|
||||
"claude-fable-5": Model<"anthropic-messages"> & {
|
||||
id: "claude-fable-5";
|
||||
provider: "anthropic";
|
||||
};
|
||||
"claude-haiku-4-5": Model<"anthropic-messages"> & {
|
||||
id: "claude-haiku-4-5";
|
||||
provider: "anthropic";
|
||||
};
|
||||
"claude-haiku-4-5-20251001": Model<"anthropic-messages"> & {
|
||||
id: "claude-haiku-4-5-20251001";
|
||||
provider: "anthropic";
|
||||
};
|
||||
"claude-opus-4-1": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4-1";
|
||||
provider: "anthropic";
|
||||
};
|
||||
"claude-opus-4-1-20250805": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4-1-20250805";
|
||||
provider: "anthropic";
|
||||
};
|
||||
"claude-opus-4-5": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4-5";
|
||||
provider: "anthropic";
|
||||
};
|
||||
"claude-opus-4-5-20251101": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4-5-20251101";
|
||||
provider: "anthropic";
|
||||
};
|
||||
"claude-opus-4-6": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4-6";
|
||||
provider: "anthropic";
|
||||
};
|
||||
"claude-opus-4-7": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4-7";
|
||||
provider: "anthropic";
|
||||
};
|
||||
"claude-opus-4-8": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4-8";
|
||||
provider: "anthropic";
|
||||
};
|
||||
"claude-sonnet-4-5": Model<"anthropic-messages"> & {
|
||||
id: "claude-sonnet-4-5";
|
||||
provider: "anthropic";
|
||||
};
|
||||
"claude-sonnet-4-5-20250929": Model<"anthropic-messages"> & {
|
||||
id: "claude-sonnet-4-5-20250929";
|
||||
provider: "anthropic";
|
||||
};
|
||||
"claude-sonnet-4-6": Model<"anthropic-messages"> & {
|
||||
id: "claude-sonnet-4-6";
|
||||
provider: "anthropic";
|
||||
};
|
||||
"claude-sonnet-5": Model<"anthropic-messages"> & {
|
||||
id: "claude-sonnet-5";
|
||||
provider: "anthropic";
|
||||
};
|
||||
};
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,61 +1,20 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/cerebras.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const CEREBRAS_MODELS = {
|
||||
"gemma-4-31b": {
|
||||
id: "gemma-4-31b",
|
||||
name: "Gemma 4 31B IT",
|
||||
api: "openai-completions",
|
||||
provider: "cerebras",
|
||||
baseUrl: "https://api.cerebras.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.99,
|
||||
output: 1.49,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 40960,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"gpt-oss-120b": {
|
||||
id: "gpt-oss-120b",
|
||||
name: "GPT OSS 120B",
|
||||
api: "openai-completions",
|
||||
provider: "cerebras",
|
||||
baseUrl: "https://api.cerebras.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.35,
|
||||
output: 0.75,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 40960,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"zai-glm-4.7": {
|
||||
id: "zai-glm-4.7",
|
||||
name: "Z.AI GLM-4.7",
|
||||
api: "openai-completions",
|
||||
provider: "cerebras",
|
||||
baseUrl: "https://api.cerebras.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 2.25,
|
||||
output: 2.75,
|
||||
cacheRead: 2.25,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 40960,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const CEREBRAS_MODELS = values as {
|
||||
"gemma-4-31b": Model<"openai-completions"> & {
|
||||
id: "gemma-4-31b";
|
||||
provider: "cerebras";
|
||||
};
|
||||
"gpt-oss-120b": Model<"openai-completions"> & {
|
||||
id: "gpt-oss-120b";
|
||||
provider: "cerebras";
|
||||
};
|
||||
"zai-glm-4.7": Model<"openai-completions"> & {
|
||||
id: "zai-glm-4.7";
|
||||
provider: "cerebras";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,760 +1,176 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/cloudflare-ai-gateway.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const CLOUDFLARE_AI_GATEWAY_MODELS = {
|
||||
"claude-3-5-haiku": {
|
||||
id: "claude-3-5-haiku",
|
||||
name: "Claude Haiku 3.5 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true},
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.8,
|
||||
output: 4,
|
||||
cacheRead: 0.08,
|
||||
cacheWrite: 1,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 8192,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-3-haiku": {
|
||||
id: "claude-3-haiku",
|
||||
name: "Claude Haiku 3",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true},
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.25,
|
||||
output: 1.25,
|
||||
cacheRead: 0.03,
|
||||
cacheWrite: 0.3,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 4096,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-3-opus": {
|
||||
id: "claude-3-opus",
|
||||
name: "Claude Opus 3",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true},
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 15,
|
||||
output: 75,
|
||||
cacheRead: 1.5,
|
||||
cacheWrite: 18.75,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 4096,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-3-sonnet": {
|
||||
id: "claude-3-sonnet",
|
||||
name: "Claude Sonnet 3",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true},
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 0.3,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 4096,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-3.5-haiku": {
|
||||
id: "claude-3.5-haiku",
|
||||
name: "Claude Haiku 3.5 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true},
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.8,
|
||||
output: 4,
|
||||
cacheRead: 0.08,
|
||||
cacheWrite: 1,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 8192,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-3.5-sonnet": {
|
||||
id: "claude-3.5-sonnet",
|
||||
name: "Claude Sonnet 3.5 v2",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true},
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 3.75,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 8192,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-fable-5": {
|
||||
id: "claude-fable-5",
|
||||
name: "Claude Fable 5",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true,"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 10,
|
||||
output: 50,
|
||||
cacheRead: 1,
|
||||
cacheWrite: 12.5,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-haiku-4-5": {
|
||||
id: "claude-haiku-4-5",
|
||||
name: "Claude Haiku 4.5 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1,
|
||||
output: 5,
|
||||
cacheRead: 0.1,
|
||||
cacheWrite: 1.25,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4": {
|
||||
id: "claude-opus-4",
|
||||
name: "Claude Opus 4 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 15,
|
||||
output: 75,
|
||||
cacheRead: 1.5,
|
||||
cacheWrite: 18.75,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 32000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4-1": {
|
||||
id: "claude-opus-4-1",
|
||||
name: "Claude Opus 4.1 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 15,
|
||||
output: 75,
|
||||
cacheRead: 1.5,
|
||||
cacheWrite: 18.75,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 32000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4-5": {
|
||||
id: "claude-opus-4-5",
|
||||
name: "Claude Opus 4.5 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 25,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4-6": {
|
||||
id: "claude-opus-4-6",
|
||||
name: "Claude Opus 4.6 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true,"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 25,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4-7": {
|
||||
id: "claude-opus-4-7",
|
||||
name: "Claude Opus 4.7",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true,"forceAdaptiveThinking":true,"supportsTemperature":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 25,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4-8": {
|
||||
id: "claude-opus-4-8",
|
||||
name: "Claude Opus 4.8",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true,"forceAdaptiveThinking":true,"supportsTemperature":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 25,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-sonnet-4": {
|
||||
id: "claude-sonnet-4",
|
||||
name: "Claude Sonnet 4 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 3.75,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-sonnet-4-5": {
|
||||
id: "claude-sonnet-4-5",
|
||||
name: "Claude Sonnet 4.5 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 3.75,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-sonnet-4-6": {
|
||||
id: "claude-sonnet-4-6",
|
||||
name: "Claude Sonnet 4.6",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true,"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 3.75,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-sonnet-5": {
|
||||
id: "claude-sonnet-5",
|
||||
name: "Claude Sonnet 5",
|
||||
api: "anthropic-messages",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/anthropic",
|
||||
compat: {"sendSessionAffinityHeaders":true,"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 10,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 2.5,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"gpt-4": {
|
||||
id: "gpt-4",
|
||||
name: "GPT-4",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 30,
|
||||
output: 60,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 8192,
|
||||
maxTokens: 8192,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-4-turbo": {
|
||||
id: "gpt-4-turbo",
|
||||
name: "GPT-4 Turbo",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 10,
|
||||
output: 30,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 4096,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-4o": {
|
||||
id: "gpt-4o",
|
||||
name: "GPT-4o",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2.5,
|
||||
output: 10,
|
||||
cacheRead: 1.25,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-4o-mini": {
|
||||
id: "gpt-4o-mini",
|
||||
name: "GPT-4o mini",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.15,
|
||||
output: 0.6,
|
||||
cacheRead: 0.08,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.1": {
|
||||
id: "gpt-5.1",
|
||||
name: "GPT-5.1",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.25,
|
||||
output: 10,
|
||||
cacheRead: 0.13,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 400000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.1-codex": {
|
||||
id: "gpt-5.1-codex",
|
||||
name: "GPT-5.1 Codex",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.25,
|
||||
output: 10,
|
||||
cacheRead: 0.125,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 400000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.2": {
|
||||
id: "gpt-5.2",
|
||||
name: "GPT-5.2",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"xhigh":"xhigh"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.75,
|
||||
output: 14,
|
||||
cacheRead: 0.175,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 400000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.2-codex": {
|
||||
id: "gpt-5.2-codex",
|
||||
name: "GPT-5.2 Codex",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"xhigh":"xhigh"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.75,
|
||||
output: 14,
|
||||
cacheRead: 0.175,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 400000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.3-codex": {
|
||||
id: "gpt-5.3-codex",
|
||||
name: "GPT-5.3 Codex",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"xhigh":"xhigh"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.75,
|
||||
output: 14,
|
||||
cacheRead: 0.175,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 400000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.4": {
|
||||
id: "gpt-5.4",
|
||||
name: "GPT-5.4",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"xhigh":"xhigh"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2.5,
|
||||
output: 15,
|
||||
cacheRead: 0.25,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1050000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.5": {
|
||||
id: "gpt-5.5",
|
||||
name: "GPT-5.5",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"xhigh":"xhigh"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 30,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1050000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.6-luna": {
|
||||
id: "gpt-5.6-luna",
|
||||
name: "GPT-5.6 Luna",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1,
|
||||
output: 6,
|
||||
cacheRead: 0.1,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1050000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.6-sol": {
|
||||
id: "gpt-5.6-sol",
|
||||
name: "GPT-5.6 Sol",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 30,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1050000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.6-terra": {
|
||||
id: "gpt-5.6-terra",
|
||||
name: "GPT-5.6 Terra",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2.5,
|
||||
output: 15,
|
||||
cacheRead: 0.25,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1050000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"o1": {
|
||||
id: "o1",
|
||||
name: "o1",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 15,
|
||||
output: 60,
|
||||
cacheRead: 7.5,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 100000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"o3": {
|
||||
id: "o3",
|
||||
name: "o3",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 8,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 100000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"o3-mini": {
|
||||
id: "o3-mini",
|
||||
name: "o3-mini",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.1,
|
||||
output: 4.4,
|
||||
cacheRead: 0.55,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 100000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"o3-pro": {
|
||||
id: "o3-pro",
|
||||
name: "o3-pro",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 20,
|
||||
output: 80,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 100000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"o4-mini": {
|
||||
id: "o4-mini",
|
||||
name: "o4-mini",
|
||||
api: "openai-responses",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/openai",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.1,
|
||||
output: 4.4,
|
||||
cacheRead: 0.28,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 100000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"workers-ai/@cf/moonshotai/kimi-k2.5": {
|
||||
id: "workers-ai/@cf/moonshotai/kimi-k2.5",
|
||||
name: "Kimi K2.5",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/compat",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 3,
|
||||
cacheRead: 0.1,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 256000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"workers-ai/@cf/moonshotai/kimi-k2.6": {
|
||||
id: "workers-ai/@cf/moonshotai/kimi-k2.6",
|
||||
name: "Kimi K2.6",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/compat",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.16,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 256000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"workers-ai/@cf/nvidia/nemotron-3-120b-a12b": {
|
||||
id: "workers-ai/@cf/nvidia/nemotron-3-120b-a12b",
|
||||
name: "Nemotron 3 Super 120B",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/compat",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.5,
|
||||
output: 1.5,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 256000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"workers-ai/@cf/zai-org/glm-4.7-flash": {
|
||||
id: "workers-ai/@cf/zai-org/glm-4.7-flash",
|
||||
name: "GLM-4.7-Flash",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/compat",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.06,
|
||||
output: 0.4,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"workers-ai/@cf/zai-org/glm-5.2": {
|
||||
id: "workers-ai/@cf/zai-org/glm-5.2",
|
||||
name: "Glm 5.2",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-ai-gateway",
|
||||
baseUrl: "https://gateway.ai.cloudflare.com/v1/{CLOUDFLARE_ACCOUNT_ID}/{CLOUDFLARE_GATEWAY_ID}/compat",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.4,
|
||||
output: 4.4,
|
||||
cacheRead: 0.26,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const CLOUDFLARE_AI_GATEWAY_MODELS = values as {
|
||||
"claude-3-5-haiku": Model<"anthropic-messages"> & {
|
||||
id: "claude-3-5-haiku";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-3-haiku": Model<"anthropic-messages"> & {
|
||||
id: "claude-3-haiku";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-3-opus": Model<"anthropic-messages"> & {
|
||||
id: "claude-3-opus";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-3-sonnet": Model<"anthropic-messages"> & {
|
||||
id: "claude-3-sonnet";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-3.5-haiku": Model<"anthropic-messages"> & {
|
||||
id: "claude-3.5-haiku";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-3.5-sonnet": Model<"anthropic-messages"> & {
|
||||
id: "claude-3.5-sonnet";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-fable-5": Model<"anthropic-messages"> & {
|
||||
id: "claude-fable-5";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-haiku-4-5": Model<"anthropic-messages"> & {
|
||||
id: "claude-haiku-4-5";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-opus-4": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-opus-4-1": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4-1";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-opus-4-5": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4-5";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-opus-4-6": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4-6";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-opus-4-7": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4-7";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-opus-4-8": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4-8";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-sonnet-4": Model<"anthropic-messages"> & {
|
||||
id: "claude-sonnet-4";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-sonnet-4-5": Model<"anthropic-messages"> & {
|
||||
id: "claude-sonnet-4-5";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-sonnet-4-6": Model<"anthropic-messages"> & {
|
||||
id: "claude-sonnet-4-6";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"claude-sonnet-5": Model<"anthropic-messages"> & {
|
||||
id: "claude-sonnet-5";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-4": Model<"openai-responses"> & {
|
||||
id: "gpt-4";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-4-turbo": Model<"openai-responses"> & {
|
||||
id: "gpt-4-turbo";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-4o": Model<"openai-responses"> & {
|
||||
id: "gpt-4o";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-4o-mini": Model<"openai-responses"> & {
|
||||
id: "gpt-4o-mini";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-5.1": Model<"openai-responses"> & {
|
||||
id: "gpt-5.1";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-5.1-codex": Model<"openai-responses"> & {
|
||||
id: "gpt-5.1-codex";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-5.2": Model<"openai-responses"> & {
|
||||
id: "gpt-5.2";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-5.2-codex": Model<"openai-responses"> & {
|
||||
id: "gpt-5.2-codex";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-5.3-codex": Model<"openai-responses"> & {
|
||||
id: "gpt-5.3-codex";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-5.4": Model<"openai-responses"> & {
|
||||
id: "gpt-5.4";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-5.5": Model<"openai-responses"> & {
|
||||
id: "gpt-5.5";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-5.6-luna": Model<"openai-responses"> & {
|
||||
id: "gpt-5.6-luna";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-5.6-sol": Model<"openai-responses"> & {
|
||||
id: "gpt-5.6-sol";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"gpt-5.6-terra": Model<"openai-responses"> & {
|
||||
id: "gpt-5.6-terra";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"o1": Model<"openai-responses"> & {
|
||||
id: "o1";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"o3": Model<"openai-responses"> & {
|
||||
id: "o3";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"o3-mini": Model<"openai-responses"> & {
|
||||
id: "o3-mini";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"o3-pro": Model<"openai-responses"> & {
|
||||
id: "o3-pro";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"o4-mini": Model<"openai-responses"> & {
|
||||
id: "o4-mini";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"workers-ai/@cf/moonshotai/kimi-k2.5": Model<"openai-completions"> & {
|
||||
id: "workers-ai/@cf/moonshotai/kimi-k2.5";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"workers-ai/@cf/moonshotai/kimi-k2.6": Model<"openai-completions"> & {
|
||||
id: "workers-ai/@cf/moonshotai/kimi-k2.6";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"workers-ai/@cf/nvidia/nemotron-3-120b-a12b": Model<"openai-completions"> & {
|
||||
id: "workers-ai/@cf/nvidia/nemotron-3-120b-a12b";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"workers-ai/@cf/zai-org/glm-4.7-flash": Model<"openai-completions"> & {
|
||||
id: "workers-ai/@cf/zai-org/glm-4.7-flash";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
"workers-ai/@cf/zai-org/glm-5.2": Model<"openai-completions"> & {
|
||||
id: "workers-ai/@cf/zai-org/glm-5.2";
|
||||
provider: "cloudflare-ai-gateway";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,241 +1,60 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/cloudflare-workers-ai.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const CLOUDFLARE_WORKERS_AI_MODELS = {
|
||||
"@cf/google/gemma-4-26b-a4b-it": {
|
||||
id: "@cf/google/gemma-4-26b-a4b-it",
|
||||
name: "Gemma 4 26B A4B IT",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-workers-ai",
|
||||
baseUrl: "https://api.cloudflare.com/client/v4/accounts/{CLOUDFLARE_ACCOUNT_ID}/ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.1,
|
||||
output: 0.3,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"@cf/ibm-granite/granite-4.0-h-micro": {
|
||||
id: "@cf/ibm-granite/granite-4.0-h-micro",
|
||||
name: "Granite 4.0 H Micro",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-workers-ai",
|
||||
baseUrl: "https://api.cloudflare.com/client/v4/accounts/{CLOUDFLARE_ACCOUNT_ID}/ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.017,
|
||||
output: 0.112,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131000,
|
||||
maxTokens: 131000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"@cf/meta/llama-3.3-70b-instruct-fp8-fast": {
|
||||
id: "@cf/meta/llama-3.3-70b-instruct-fp8-fast",
|
||||
name: "Llama 3.3 70B Instruct fp8 Fast",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-workers-ai",
|
||||
baseUrl: "https://api.cloudflare.com/client/v4/accounts/{CLOUDFLARE_ACCOUNT_ID}/ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.293,
|
||||
output: 2.253,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 24000,
|
||||
maxTokens: 24000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"@cf/meta/llama-4-scout-17b-16e-instruct": {
|
||||
id: "@cf/meta/llama-4-scout-17b-16e-instruct",
|
||||
name: "Llama 4 Scout 17B 16E Instruct",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-workers-ai",
|
||||
baseUrl: "https://api.cloudflare.com/client/v4/accounts/{CLOUDFLARE_ACCOUNT_ID}/ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.27,
|
||||
output: 0.85,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131000,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"@cf/mistralai/mistral-small-3.1-24b-instruct": {
|
||||
id: "@cf/mistralai/mistral-small-3.1-24b-instruct",
|
||||
name: "Mistral Small 3.1 24B Instruct",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-workers-ai",
|
||||
baseUrl: "https://api.cloudflare.com/client/v4/accounts/{CLOUDFLARE_ACCOUNT_ID}/ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.351,
|
||||
output: 0.555,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"@cf/moonshotai/kimi-k2.6": {
|
||||
id: "@cf/moonshotai/kimi-k2.6",
|
||||
name: "Kimi K2.6",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-workers-ai",
|
||||
baseUrl: "https://api.cloudflare.com/client/v4/accounts/{CLOUDFLARE_ACCOUNT_ID}/ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.16,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 256000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"@cf/moonshotai/kimi-k2.7-code": {
|
||||
id: "@cf/moonshotai/kimi-k2.7-code",
|
||||
name: "Kimi K2.7 Code",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-workers-ai",
|
||||
baseUrl: "https://api.cloudflare.com/client/v4/accounts/{CLOUDFLARE_ACCOUNT_ID}/ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.19,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"@cf/nvidia/nemotron-3-120b-a12b": {
|
||||
id: "@cf/nvidia/nemotron-3-120b-a12b",
|
||||
name: "Nemotron 3 Super 120B",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-workers-ai",
|
||||
baseUrl: "https://api.cloudflare.com/client/v4/accounts/{CLOUDFLARE_ACCOUNT_ID}/ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.5,
|
||||
output: 1.5,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 256000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"@cf/openai/gpt-oss-120b": {
|
||||
id: "@cf/openai/gpt-oss-120b",
|
||||
name: "GPT OSS 120B",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-workers-ai",
|
||||
baseUrl: "https://api.cloudflare.com/client/v4/accounts/{CLOUDFLARE_ACCOUNT_ID}/ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.35,
|
||||
output: 0.75,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"@cf/openai/gpt-oss-20b": {
|
||||
id: "@cf/openai/gpt-oss-20b",
|
||||
name: "GPT OSS 20B",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-workers-ai",
|
||||
baseUrl: "https://api.cloudflare.com/client/v4/accounts/{CLOUDFLARE_ACCOUNT_ID}/ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.2,
|
||||
output: 0.3,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"@cf/qwen/qwen3-30b-a3b-fp8": {
|
||||
id: "@cf/qwen/qwen3-30b-a3b-fp8",
|
||||
name: "Qwen3 30B A3b fp8",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-workers-ai",
|
||||
baseUrl: "https://api.cloudflare.com/client/v4/accounts/{CLOUDFLARE_ACCOUNT_ID}/ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.0509,
|
||||
output: 0.335,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 32768,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"@cf/zai-org/glm-4.7-flash": {
|
||||
id: "@cf/zai-org/glm-4.7-flash",
|
||||
name: "GLM-4.7-Flash",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-workers-ai",
|
||||
baseUrl: "https://api.cloudflare.com/client/v4/accounts/{CLOUDFLARE_ACCOUNT_ID}/ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.0605,
|
||||
output: 0.4,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"@cf/zai-org/glm-5.2": {
|
||||
id: "@cf/zai-org/glm-5.2",
|
||||
name: "Glm 5.2",
|
||||
api: "openai-completions",
|
||||
provider: "cloudflare-workers-ai",
|
||||
baseUrl: "https://api.cloudflare.com/client/v4/accounts/{CLOUDFLARE_ACCOUNT_ID}/ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsLongCacheRetention":false,"sendSessionAffinityHeaders":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.4,
|
||||
output: 4.4,
|
||||
cacheRead: 0.26,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const CLOUDFLARE_WORKERS_AI_MODELS = values as {
|
||||
"@cf/google/gemma-4-26b-a4b-it": Model<"openai-completions"> & {
|
||||
id: "@cf/google/gemma-4-26b-a4b-it";
|
||||
provider: "cloudflare-workers-ai";
|
||||
};
|
||||
"@cf/ibm-granite/granite-4.0-h-micro": Model<"openai-completions"> & {
|
||||
id: "@cf/ibm-granite/granite-4.0-h-micro";
|
||||
provider: "cloudflare-workers-ai";
|
||||
};
|
||||
"@cf/meta/llama-3.3-70b-instruct-fp8-fast": Model<"openai-completions"> & {
|
||||
id: "@cf/meta/llama-3.3-70b-instruct-fp8-fast";
|
||||
provider: "cloudflare-workers-ai";
|
||||
};
|
||||
"@cf/meta/llama-4-scout-17b-16e-instruct": Model<"openai-completions"> & {
|
||||
id: "@cf/meta/llama-4-scout-17b-16e-instruct";
|
||||
provider: "cloudflare-workers-ai";
|
||||
};
|
||||
"@cf/mistralai/mistral-small-3.1-24b-instruct": Model<"openai-completions"> & {
|
||||
id: "@cf/mistralai/mistral-small-3.1-24b-instruct";
|
||||
provider: "cloudflare-workers-ai";
|
||||
};
|
||||
"@cf/moonshotai/kimi-k2.6": Model<"openai-completions"> & {
|
||||
id: "@cf/moonshotai/kimi-k2.6";
|
||||
provider: "cloudflare-workers-ai";
|
||||
};
|
||||
"@cf/moonshotai/kimi-k2.7-code": Model<"openai-completions"> & {
|
||||
id: "@cf/moonshotai/kimi-k2.7-code";
|
||||
provider: "cloudflare-workers-ai";
|
||||
};
|
||||
"@cf/nvidia/nemotron-3-120b-a12b": Model<"openai-completions"> & {
|
||||
id: "@cf/nvidia/nemotron-3-120b-a12b";
|
||||
provider: "cloudflare-workers-ai";
|
||||
};
|
||||
"@cf/openai/gpt-oss-120b": Model<"openai-completions"> & {
|
||||
id: "@cf/openai/gpt-oss-120b";
|
||||
provider: "cloudflare-workers-ai";
|
||||
};
|
||||
"@cf/openai/gpt-oss-20b": Model<"openai-completions"> & {
|
||||
id: "@cf/openai/gpt-oss-20b";
|
||||
provider: "cloudflare-workers-ai";
|
||||
};
|
||||
"@cf/qwen/qwen3-30b-a3b-fp8": Model<"openai-completions"> & {
|
||||
id: "@cf/qwen/qwen3-30b-a3b-fp8";
|
||||
provider: "cloudflare-workers-ai";
|
||||
};
|
||||
"@cf/zai-org/glm-4.7-flash": Model<"openai-completions"> & {
|
||||
id: "@cf/zai-org/glm-4.7-flash";
|
||||
provider: "cloudflare-workers-ai";
|
||||
};
|
||||
"@cf/zai-org/glm-5.2": Model<"openai-completions"> & {
|
||||
id: "@cf/zai-org/glm-5.2";
|
||||
provider: "cloudflare-workers-ai";
|
||||
};
|
||||
};
|
||||
|
||||
+4
@@ -0,0 +1,4 @@
|
||||
declare module "*.json" {
|
||||
const value: unknown;
|
||||
export default value;
|
||||
}
|
||||
@@ -1,45 +1,16 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/deepseek.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const DEEPSEEK_MODELS = {
|
||||
"deepseek-v4-flash": {
|
||||
id: "deepseek-v4-flash",
|
||||
name: "DeepSeek V4 Flash",
|
||||
api: "openai-completions",
|
||||
provider: "deepseek",
|
||||
baseUrl: "https://api.deepseek.com",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null,"high":"high","max":"max"},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.14,
|
||||
output: 0.28,
|
||||
cacheRead: 0.0028,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 384000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"deepseek-v4-pro": {
|
||||
id: "deepseek-v4-pro",
|
||||
name: "DeepSeek V4 Pro",
|
||||
api: "openai-completions",
|
||||
provider: "deepseek",
|
||||
baseUrl: "https://api.deepseek.com",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null,"high":"high","max":"max"},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.435,
|
||||
output: 0.87,
|
||||
cacheRead: 0.003625,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 384000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const DEEPSEEK_MODELS = values as {
|
||||
"deepseek-v4-flash": Model<"openai-completions"> & {
|
||||
id: "deepseek-v4-flash";
|
||||
provider: "deepseek";
|
||||
};
|
||||
"deepseek-v4-pro": Model<"openai-completions"> & {
|
||||
id: "deepseek-v4-pro";
|
||||
provider: "deepseek";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,297 +1,72 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/fireworks.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const FIREWORKS_MODELS = {
|
||||
"accounts/fireworks/models/deepseek-v4-flash": {
|
||||
id: "accounts/fireworks/models/deepseek-v4-flash",
|
||||
name: "DeepSeek V4 Flash",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.14,
|
||||
output: 0.28,
|
||||
cacheRead: 0.028,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 384000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"accounts/fireworks/models/deepseek-v4-pro": {
|
||||
id: "accounts/fireworks/models/deepseek-v4-pro",
|
||||
name: "DeepSeek V4 Pro",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.74,
|
||||
output: 3.48,
|
||||
cacheRead: 0.145,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 384000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"accounts/fireworks/models/glm-5p1": {
|
||||
id: "accounts/fireworks/models/glm-5p1",
|
||||
name: "GLM 5.1",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.4,
|
||||
output: 4.4,
|
||||
cacheRead: 0.26,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 202800,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"accounts/fireworks/models/glm-5p2": {
|
||||
id: "accounts/fireworks/models/glm-5p2",
|
||||
name: "GLM 5.2",
|
||||
api: "openai-completions",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":"none","minimal":null,"low":"high","medium":"high","max":"max"},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.4,
|
||||
output: 4.4,
|
||||
cacheRead: 0.14,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048575,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"accounts/fireworks/models/gpt-oss-120b": {
|
||||
id: "accounts/fireworks/models/gpt-oss-120b",
|
||||
name: "GPT OSS 120B",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.15,
|
||||
output: 0.6,
|
||||
cacheRead: 0.015,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"accounts/fireworks/models/gpt-oss-20b": {
|
||||
id: "accounts/fireworks/models/gpt-oss-20b",
|
||||
name: "GPT OSS 20B",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.07,
|
||||
output: 0.3,
|
||||
cacheRead: 0.035,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"accounts/fireworks/models/kimi-k2p6": {
|
||||
id: "accounts/fireworks/models/kimi-k2p6",
|
||||
name: "Kimi K2.6",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.16,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262000,
|
||||
maxTokens: 262000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"accounts/fireworks/models/kimi-k2p7-code": {
|
||||
id: "accounts/fireworks/models/kimi-k2p7-code",
|
||||
name: "Kimi K2.7 Code",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.19,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262000,
|
||||
maxTokens: 262000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"accounts/fireworks/models/minimax-m2p7": {
|
||||
id: "accounts/fireworks/models/minimax-m2p7",
|
||||
name: "MiniMax-M2.7",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 1.2,
|
||||
cacheRead: 0.06,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 196608,
|
||||
maxTokens: 196608,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"accounts/fireworks/models/minimax-m3": {
|
||||
id: "accounts/fireworks/models/minimax-m3",
|
||||
name: "MiniMax-M3",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 1.2,
|
||||
cacheRead: 0.06,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 512000,
|
||||
maxTokens: 512000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"accounts/fireworks/models/qwen3p7-plus": {
|
||||
id: "accounts/fireworks/models/qwen3p7-plus",
|
||||
name: "Qwen 3.7 Plus",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.4,
|
||||
output: 1.6,
|
||||
cacheRead: 0.08,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"accounts/fireworks/routers/glm-5p1-fast": {
|
||||
id: "accounts/fireworks/routers/glm-5p1-fast",
|
||||
name: "GLM 5.1 Fast",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 2.8,
|
||||
output: 8.8,
|
||||
cacheRead: 0.52,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 202800,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"accounts/fireworks/routers/glm-5p2-fast": {
|
||||
id: "accounts/fireworks/routers/glm-5p2-fast",
|
||||
name: "GLM 5.2 Fast",
|
||||
api: "openai-completions",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":"none","minimal":null,"low":"high","medium":"high","max":"max"},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 2.1,
|
||||
output: 6.6,
|
||||
cacheRead: 0.21,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048575,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"accounts/fireworks/routers/kimi-k2p6-fast": {
|
||||
id: "accounts/fireworks/routers/kimi-k2p6-fast",
|
||||
name: "Kimi K2.6 Fast",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 8,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262000,
|
||||
maxTokens: 262000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"accounts/fireworks/routers/kimi-k2p6-turbo": {
|
||||
id: "accounts/fireworks/routers/kimi-k2p6-turbo",
|
||||
name: "Kimi K2.6 Turbo",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 8,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262000,
|
||||
maxTokens: 262000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"accounts/fireworks/routers/kimi-k2p7-code-fast": {
|
||||
id: "accounts/fireworks/routers/kimi-k2p7-code-fast",
|
||||
name: "Kimi K2.7 Code Fast",
|
||||
api: "anthropic-messages",
|
||||
provider: "fireworks",
|
||||
baseUrl: "https://api.fireworks.ai/inference",
|
||||
compat: {"sendSessionAffinityHeaders":true,"supportsEagerToolInputStreaming":false,"supportsCacheControlOnTools":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.9,
|
||||
output: 8,
|
||||
cacheRead: 0.38,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262000,
|
||||
maxTokens: 262000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
} as const;
|
||||
export const FIREWORKS_MODELS = values as {
|
||||
"accounts/fireworks/models/deepseek-v4-flash": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/models/deepseek-v4-flash";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/models/deepseek-v4-pro": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/models/deepseek-v4-pro";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/models/glm-5p1": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/models/glm-5p1";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/models/glm-5p2": Model<"openai-completions"> & {
|
||||
id: "accounts/fireworks/models/glm-5p2";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/models/gpt-oss-120b": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/models/gpt-oss-120b";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/models/gpt-oss-20b": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/models/gpt-oss-20b";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/models/kimi-k2p6": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/models/kimi-k2p6";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/models/kimi-k2p7-code": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/models/kimi-k2p7-code";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/models/minimax-m2p7": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/models/minimax-m2p7";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/models/minimax-m3": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/models/minimax-m3";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/models/qwen3p7-plus": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/models/qwen3p7-plus";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/routers/glm-5p1-fast": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/routers/glm-5p1-fast";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/routers/glm-5p2-fast": Model<"openai-completions"> & {
|
||||
id: "accounts/fireworks/routers/glm-5p2-fast";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/routers/kimi-k2p6-fast": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/routers/kimi-k2p6-fast";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/routers/kimi-k2p6-turbo": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/routers/kimi-k2p6-turbo";
|
||||
provider: "fireworks";
|
||||
};
|
||||
"accounts/fireworks/routers/kimi-k2p7-code-fast": Model<"anthropic-messages"> & {
|
||||
id: "accounts/fireworks/routers/kimi-k2p7-code-fast";
|
||||
provider: "fireworks";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,543 +1,120 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/github-copilot.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const GITHUB_COPILOT_MODELS = {
|
||||
"claude-fable-5": {
|
||||
id: "claude-fable-5",
|
||||
name: "Claude Fable 5",
|
||||
api: "openai-completions",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 10,
|
||||
output: 50,
|
||||
cacheRead: 1,
|
||||
cacheWrite: 12.5,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"claude-haiku-4.5": {
|
||||
id: "claude-haiku-4.5",
|
||||
name: "Claude Haiku 4.5 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"supportsEagerToolInputStreaming":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1,
|
||||
output: 5,
|
||||
cacheRead: 0.1,
|
||||
cacheWrite: 1.25,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4.5": {
|
||||
id: "claude-opus-4.5",
|
||||
name: "Claude Opus 4.5 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 25,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 32000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4.6": {
|
||||
id: "claude-opus-4.6",
|
||||
name: "Claude Opus 4.6",
|
||||
api: "anthropic-messages",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 25,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 32000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4.7": {
|
||||
id: "claude-opus-4.7",
|
||||
name: "Claude Opus 4.7",
|
||||
api: "anthropic-messages",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"forceAdaptiveThinking":true,"supportsTemperature":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","max":"max","minimal":"low"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 25,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 32000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-opus-4.8": {
|
||||
id: "claude-opus-4.8",
|
||||
name: "Claude Opus 4.8",
|
||||
api: "anthropic-messages",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"forceAdaptiveThinking":true,"supportsTemperature":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","max":"max","minimal":"low"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 25,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-sonnet-4": {
|
||||
id: "claude-sonnet-4",
|
||||
name: "Claude Sonnet 4 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"supportsEagerToolInputStreaming":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 3.75,
|
||||
},
|
||||
contextWindow: 216000,
|
||||
maxTokens: 16000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-sonnet-4.5": {
|
||||
id: "claude-sonnet-4.5",
|
||||
name: "Claude Sonnet 4.5 (latest)",
|
||||
api: "anthropic-messages",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"supportsEagerToolInputStreaming":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 3.75,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 32000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-sonnet-4.6": {
|
||||
id: "claude-sonnet-4.6",
|
||||
name: "Claude Sonnet 4.6",
|
||||
api: "anthropic-messages",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"max":"max","minimal":"low"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 3.75,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 32000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"claude-sonnet-5": {
|
||||
id: "claude-sonnet-5",
|
||||
name: "Claude Sonnet 5",
|
||||
api: "anthropic-messages",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 10,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 2.5,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"gemini-2.5-pro": {
|
||||
id: "gemini-2.5-pro",
|
||||
name: "Gemini 2.5 Pro",
|
||||
api: "openai-completions",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.25,
|
||||
output: 10,
|
||||
cacheRead: 0.125,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"gemini-3-flash-preview": {
|
||||
id: "gemini-3-flash-preview",
|
||||
name: "Gemini 3 Flash Preview",
|
||||
api: "openai-completions",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.5,
|
||||
output: 3,
|
||||
cacheRead: 0.05,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"gemini-3.1-pro-preview": {
|
||||
id: "gemini-3.1-pro-preview",
|
||||
name: "Gemini 3.1 Pro Preview",
|
||||
api: "openai-completions",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 12,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"gemini-3.5-flash": {
|
||||
id: "gemini-3.5-flash",
|
||||
name: "Gemini 3.5 Flash",
|
||||
api: "openai-completions",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.5,
|
||||
output: 9,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"gpt-4.1": {
|
||||
id: "gpt-4.1",
|
||||
name: "GPT-4.1",
|
||||
api: "openai-completions",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false},
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 8,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"gpt-5-mini": {
|
||||
id: "gpt-5-mini",
|
||||
name: "GPT-5 Mini",
|
||||
api: "openai-responses",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":"low"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.25,
|
||||
output: 2,
|
||||
cacheRead: 0.025,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 264000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.2": {
|
||||
id: "gpt-5.2",
|
||||
name: "GPT-5.2",
|
||||
api: "openai-responses",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":"low","xhigh":"xhigh"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.75,
|
||||
output: 14,
|
||||
cacheRead: 0.175,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 400000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.2-codex": {
|
||||
id: "gpt-5.2-codex",
|
||||
name: "GPT-5.2 Codex",
|
||||
api: "openai-responses",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":"low","xhigh":"xhigh"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.75,
|
||||
output: 14,
|
||||
cacheRead: 0.175,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 400000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.3-codex": {
|
||||
id: "gpt-5.3-codex",
|
||||
name: "GPT-5.3 Codex",
|
||||
api: "openai-responses",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":"low","xhigh":"xhigh"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.75,
|
||||
output: 14,
|
||||
cacheRead: 0.175,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.4": {
|
||||
id: "gpt-5.4",
|
||||
name: "GPT-5.4",
|
||||
api: "openai-responses",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":"low","xhigh":"xhigh"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2.5,
|
||||
output: 15,
|
||||
cacheRead: 0.25,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.4-mini": {
|
||||
id: "gpt-5.4-mini",
|
||||
name: "GPT-5.4 mini",
|
||||
api: "openai-responses",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":"low","xhigh":"xhigh"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.75,
|
||||
output: 4.5,
|
||||
cacheRead: 0.075,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 400000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.4-nano": {
|
||||
id: "gpt-5.4-nano",
|
||||
name: "GPT-5.4 nano",
|
||||
api: "openai-responses",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":"low","xhigh":"xhigh"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.2,
|
||||
output: 1.25,
|
||||
cacheRead: 0.02,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 400000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.5": {
|
||||
id: "gpt-5.5",
|
||||
name: "GPT-5.5",
|
||||
api: "openai-responses",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":"low","xhigh":"xhigh"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 30,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.6-luna": {
|
||||
id: "gpt-5.6-luna",
|
||||
name: "GPT-5.6 Luna",
|
||||
api: "openai-responses",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":"low","xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1,
|
||||
output: 6,
|
||||
cacheRead: 0.1,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1050000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.6-sol": {
|
||||
id: "gpt-5.6-sol",
|
||||
name: "GPT-5.6 Sol",
|
||||
api: "openai-responses",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":"low","xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 30,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1050000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"gpt-5.6-terra": {
|
||||
id: "gpt-5.6-terra",
|
||||
name: "GPT-5.6 Terra",
|
||||
api: "openai-responses",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":"low","xhigh":"xhigh","max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2.5,
|
||||
output: 15,
|
||||
cacheRead: 0.25,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1050000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"kimi-k2.7-code": {
|
||||
id: "kimi-k2.7-code",
|
||||
name: "Kimi K2.7 Code",
|
||||
api: "openai-completions",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.19,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 32000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mai-code-1-flash-picker": {
|
||||
id: "mai-code-1-flash-picker",
|
||||
name: "MAI-Code-1-Flash",
|
||||
api: "openai-responses",
|
||||
provider: "github-copilot",
|
||||
baseUrl: "https://api.individual.githubcopilot.com",
|
||||
headers: {"User-Agent":"GitHubCopilotChat/0.35.0","Editor-Version":"vscode/1.107.0","Editor-Plugin-Version":"copilot-chat/0.35.0","Copilot-Integration-Id":"vscode-chat"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.75,
|
||||
output: 4.5,
|
||||
cacheRead: 0.075,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
} as const;
|
||||
export const GITHUB_COPILOT_MODELS = values as {
|
||||
"claude-fable-5": Model<"openai-completions"> & {
|
||||
id: "claude-fable-5";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"claude-haiku-4.5": Model<"anthropic-messages"> & {
|
||||
id: "claude-haiku-4.5";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"claude-opus-4.5": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4.5";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"claude-opus-4.6": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4.6";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"claude-opus-4.7": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4.7";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"claude-opus-4.8": Model<"anthropic-messages"> & {
|
||||
id: "claude-opus-4.8";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"claude-sonnet-4": Model<"anthropic-messages"> & {
|
||||
id: "claude-sonnet-4";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"claude-sonnet-4.5": Model<"anthropic-messages"> & {
|
||||
id: "claude-sonnet-4.5";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"claude-sonnet-4.6": Model<"anthropic-messages"> & {
|
||||
id: "claude-sonnet-4.6";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"claude-sonnet-5": Model<"anthropic-messages"> & {
|
||||
id: "claude-sonnet-5";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gemini-2.5-pro": Model<"openai-completions"> & {
|
||||
id: "gemini-2.5-pro";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gemini-3-flash-preview": Model<"openai-completions"> & {
|
||||
id: "gemini-3-flash-preview";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gemini-3.1-pro-preview": Model<"openai-completions"> & {
|
||||
id: "gemini-3.1-pro-preview";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gemini-3.5-flash": Model<"openai-completions"> & {
|
||||
id: "gemini-3.5-flash";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gpt-4.1": Model<"openai-completions"> & {
|
||||
id: "gpt-4.1";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gpt-5-mini": Model<"openai-responses"> & {
|
||||
id: "gpt-5-mini";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gpt-5.2": Model<"openai-responses"> & {
|
||||
id: "gpt-5.2";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gpt-5.2-codex": Model<"openai-responses"> & {
|
||||
id: "gpt-5.2-codex";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gpt-5.3-codex": Model<"openai-responses"> & {
|
||||
id: "gpt-5.3-codex";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gpt-5.4": Model<"openai-responses"> & {
|
||||
id: "gpt-5.4";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gpt-5.4-mini": Model<"openai-responses"> & {
|
||||
id: "gpt-5.4-mini";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gpt-5.4-nano": Model<"openai-responses"> & {
|
||||
id: "gpt-5.4-nano";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gpt-5.5": Model<"openai-responses"> & {
|
||||
id: "gpt-5.5";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gpt-5.6-luna": Model<"openai-responses"> & {
|
||||
id: "gpt-5.6-luna";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gpt-5.6-sol": Model<"openai-responses"> & {
|
||||
id: "gpt-5.6-sol";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"gpt-5.6-terra": Model<"openai-responses"> & {
|
||||
id: "gpt-5.6-terra";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"kimi-k2.7-code": Model<"openai-completions"> & {
|
||||
id: "kimi-k2.7-code";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
"mai-code-1-flash-picker": Model<"openai-responses"> & {
|
||||
id: "mai-code-1-flash-picker";
|
||||
provider: "github-copilot";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,184 +1,48 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/google-vertex.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const GOOGLE_VERTEX_MODELS = {
|
||||
"gemini-2.5-flash": {
|
||||
id: "gemini-2.5-flash",
|
||||
name: "Gemini 2.5 Flash",
|
||||
api: "google-vertex",
|
||||
provider: "google-vertex",
|
||||
baseUrl: "https://{location}-aiplatform.googleapis.com",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 2.5,
|
||||
cacheRead: 0.03,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-vertex">,
|
||||
"gemini-2.5-flash-lite": {
|
||||
id: "gemini-2.5-flash-lite",
|
||||
name: "Gemini 2.5 Flash-Lite",
|
||||
api: "google-vertex",
|
||||
provider: "google-vertex",
|
||||
baseUrl: "https://{location}-aiplatform.googleapis.com",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.1,
|
||||
output: 0.4,
|
||||
cacheRead: 0.01,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-vertex">,
|
||||
"gemini-2.5-pro": {
|
||||
id: "gemini-2.5-pro",
|
||||
name: "Gemini 2.5 Pro",
|
||||
api: "google-vertex",
|
||||
provider: "google-vertex",
|
||||
baseUrl: "https://{location}-aiplatform.googleapis.com",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.25,
|
||||
output: 10,
|
||||
cacheRead: 0.125,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-vertex">,
|
||||
"gemini-3-flash-preview": {
|
||||
id: "gemini-3-flash-preview",
|
||||
name: "Gemini 3 Flash Preview",
|
||||
api: "google-vertex",
|
||||
provider: "google-vertex",
|
||||
baseUrl: "https://{location}-aiplatform.googleapis.com",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.5,
|
||||
output: 3,
|
||||
cacheRead: 0.05,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-vertex">,
|
||||
"gemini-3.1-flash-lite": {
|
||||
id: "gemini-3.1-flash-lite",
|
||||
name: "Gemini 3.1 Flash Lite",
|
||||
api: "google-vertex",
|
||||
provider: "google-vertex",
|
||||
baseUrl: "https://{location}-aiplatform.googleapis.com",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.25,
|
||||
output: 1.5,
|
||||
cacheRead: 0.025,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-vertex">,
|
||||
"gemini-3.1-pro-preview": {
|
||||
id: "gemini-3.1-pro-preview",
|
||||
name: "Gemini 3.1 Pro Preview",
|
||||
api: "google-vertex",
|
||||
provider: "google-vertex",
|
||||
baseUrl: "https://{location}-aiplatform.googleapis.com",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null,"low":"LOW","medium":null,"high":"HIGH"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 12,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-vertex">,
|
||||
"gemini-3.1-pro-preview-customtools": {
|
||||
id: "gemini-3.1-pro-preview-customtools",
|
||||
name: "Gemini 3.1 Pro Preview Custom Tools",
|
||||
api: "google-vertex",
|
||||
provider: "google-vertex",
|
||||
baseUrl: "https://{location}-aiplatform.googleapis.com",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null,"low":"LOW","medium":null,"high":"HIGH"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 12,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-vertex">,
|
||||
"gemini-3.5-flash": {
|
||||
id: "gemini-3.5-flash",
|
||||
name: "Gemini 3.5 Flash",
|
||||
api: "google-vertex",
|
||||
provider: "google-vertex",
|
||||
baseUrl: "https://{location}-aiplatform.googleapis.com",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.5,
|
||||
output: 9,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-vertex">,
|
||||
"gemini-flash-latest": {
|
||||
id: "gemini-flash-latest",
|
||||
name: "Gemini Flash Latest",
|
||||
api: "google-vertex",
|
||||
provider: "google-vertex",
|
||||
baseUrl: "https://{location}-aiplatform.googleapis.com",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.5,
|
||||
output: 9,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-vertex">,
|
||||
"gemini-flash-lite-latest": {
|
||||
id: "gemini-flash-lite-latest",
|
||||
name: "Gemini Flash-Lite Latest",
|
||||
api: "google-vertex",
|
||||
provider: "google-vertex",
|
||||
baseUrl: "https://{location}-aiplatform.googleapis.com",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.25,
|
||||
output: 1.5,
|
||||
cacheRead: 0.025,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-vertex">,
|
||||
} as const;
|
||||
export const GOOGLE_VERTEX_MODELS = values as {
|
||||
"gemini-2.5-flash": Model<"google-vertex"> & {
|
||||
id: "gemini-2.5-flash";
|
||||
provider: "google-vertex";
|
||||
};
|
||||
"gemini-2.5-flash-lite": Model<"google-vertex"> & {
|
||||
id: "gemini-2.5-flash-lite";
|
||||
provider: "google-vertex";
|
||||
};
|
||||
"gemini-2.5-pro": Model<"google-vertex"> & {
|
||||
id: "gemini-2.5-pro";
|
||||
provider: "google-vertex";
|
||||
};
|
||||
"gemini-3-flash-preview": Model<"google-vertex"> & {
|
||||
id: "gemini-3-flash-preview";
|
||||
provider: "google-vertex";
|
||||
};
|
||||
"gemini-3.1-flash-lite": Model<"google-vertex"> & {
|
||||
id: "gemini-3.1-flash-lite";
|
||||
provider: "google-vertex";
|
||||
};
|
||||
"gemini-3.1-pro-preview": Model<"google-vertex"> & {
|
||||
id: "gemini-3.1-pro-preview";
|
||||
provider: "google-vertex";
|
||||
};
|
||||
"gemini-3.1-pro-preview-customtools": Model<"google-vertex"> & {
|
||||
id: "gemini-3.1-pro-preview-customtools";
|
||||
provider: "google-vertex";
|
||||
};
|
||||
"gemini-3.5-flash": Model<"google-vertex"> & {
|
||||
id: "gemini-3.5-flash";
|
||||
provider: "google-vertex";
|
||||
};
|
||||
"gemini-flash-latest": Model<"google-vertex"> & {
|
||||
id: "gemini-flash-latest";
|
||||
provider: "google-vertex";
|
||||
};
|
||||
"gemini-flash-lite-latest": Model<"google-vertex"> & {
|
||||
id: "gemini-flash-lite-latest";
|
||||
provider: "google-vertex";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,290 +1,72 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/google.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const GOOGLE_MODELS = {
|
||||
"gemini-2.0-flash": {
|
||||
id: "gemini-2.0-flash",
|
||||
name: "Gemini 2.0 Flash",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.1,
|
||||
output: 0.4,
|
||||
cacheRead: 0.025,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 8192,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemini-2.0-flash-lite": {
|
||||
id: "gemini-2.0-flash-lite",
|
||||
name: "Gemini 2.0 Flash-Lite",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.075,
|
||||
output: 0.3,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 8192,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemini-2.5-flash": {
|
||||
id: "gemini-2.5-flash",
|
||||
name: "Gemini 2.5 Flash",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 2.5,
|
||||
cacheRead: 0.03,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemini-2.5-flash-lite": {
|
||||
id: "gemini-2.5-flash-lite",
|
||||
name: "Gemini 2.5 Flash-Lite",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.1,
|
||||
output: 0.4,
|
||||
cacheRead: 0.01,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemini-2.5-pro": {
|
||||
id: "gemini-2.5-pro",
|
||||
name: "Gemini 2.5 Pro",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.25,
|
||||
output: 10,
|
||||
cacheRead: 0.125,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemini-3-flash-preview": {
|
||||
id: "gemini-3-flash-preview",
|
||||
name: "Gemini 3 Flash Preview",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.5,
|
||||
output: 3,
|
||||
cacheRead: 0.05,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemini-3-pro-preview": {
|
||||
id: "gemini-3-pro-preview",
|
||||
name: "Gemini 3 Pro Preview",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null,"low":"LOW","medium":null,"high":"HIGH"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 12,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemini-3.1-flash-lite": {
|
||||
id: "gemini-3.1-flash-lite",
|
||||
name: "Gemini 3.1 Flash Lite",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.25,
|
||||
output: 1.5,
|
||||
cacheRead: 0.025,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemini-3.1-flash-lite-preview": {
|
||||
id: "gemini-3.1-flash-lite-preview",
|
||||
name: "Gemini 3.1 Flash Lite Preview",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.25,
|
||||
output: 1.5,
|
||||
cacheRead: 0.025,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemini-3.1-pro-preview": {
|
||||
id: "gemini-3.1-pro-preview",
|
||||
name: "Gemini 3.1 Pro Preview",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null,"low":"LOW","medium":null,"high":"HIGH"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 12,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemini-3.1-pro-preview-customtools": {
|
||||
id: "gemini-3.1-pro-preview-customtools",
|
||||
name: "Gemini 3.1 Pro Preview Custom Tools",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null,"low":"LOW","medium":null,"high":"HIGH"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 12,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemini-3.5-flash": {
|
||||
id: "gemini-3.5-flash",
|
||||
name: "Gemini 3.5 Flash",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.5,
|
||||
output: 9,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemini-flash-latest": {
|
||||
id: "gemini-flash-latest",
|
||||
name: "Gemini Flash Latest",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.5,
|
||||
output: 9,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemini-flash-lite-latest": {
|
||||
id: "gemini-flash-lite-latest",
|
||||
name: "Gemini Flash-Lite Latest",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.25,
|
||||
output: 1.5,
|
||||
cacheRead: 0.025,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemma-4-26b-a4b-it": {
|
||||
id: "gemma-4-26b-a4b-it",
|
||||
name: "Gemma 4 26B A4B IT",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":"MINIMAL","low":null,"medium":null,"high":"HIGH"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
"gemma-4-31b-it": {
|
||||
id: "gemma-4-31b-it",
|
||||
name: "Gemma 4 31B IT",
|
||||
api: "google-generative-ai",
|
||||
provider: "google",
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":"MINIMAL","low":null,"medium":null,"high":"HIGH"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"google-generative-ai">,
|
||||
} as const;
|
||||
export const GOOGLE_MODELS = values as {
|
||||
"gemini-2.0-flash": Model<"google-generative-ai"> & {
|
||||
id: "gemini-2.0-flash";
|
||||
provider: "google";
|
||||
};
|
||||
"gemini-2.0-flash-lite": Model<"google-generative-ai"> & {
|
||||
id: "gemini-2.0-flash-lite";
|
||||
provider: "google";
|
||||
};
|
||||
"gemini-2.5-flash": Model<"google-generative-ai"> & {
|
||||
id: "gemini-2.5-flash";
|
||||
provider: "google";
|
||||
};
|
||||
"gemini-2.5-flash-lite": Model<"google-generative-ai"> & {
|
||||
id: "gemini-2.5-flash-lite";
|
||||
provider: "google";
|
||||
};
|
||||
"gemini-2.5-pro": Model<"google-generative-ai"> & {
|
||||
id: "gemini-2.5-pro";
|
||||
provider: "google";
|
||||
};
|
||||
"gemini-3-flash-preview": Model<"google-generative-ai"> & {
|
||||
id: "gemini-3-flash-preview";
|
||||
provider: "google";
|
||||
};
|
||||
"gemini-3-pro-preview": Model<"google-generative-ai"> & {
|
||||
id: "gemini-3-pro-preview";
|
||||
provider: "google";
|
||||
};
|
||||
"gemini-3.1-flash-lite": Model<"google-generative-ai"> & {
|
||||
id: "gemini-3.1-flash-lite";
|
||||
provider: "google";
|
||||
};
|
||||
"gemini-3.1-flash-lite-preview": Model<"google-generative-ai"> & {
|
||||
id: "gemini-3.1-flash-lite-preview";
|
||||
provider: "google";
|
||||
};
|
||||
"gemini-3.1-pro-preview": Model<"google-generative-ai"> & {
|
||||
id: "gemini-3.1-pro-preview";
|
||||
provider: "google";
|
||||
};
|
||||
"gemini-3.1-pro-preview-customtools": Model<"google-generative-ai"> & {
|
||||
id: "gemini-3.1-pro-preview-customtools";
|
||||
provider: "google";
|
||||
};
|
||||
"gemini-3.5-flash": Model<"google-generative-ai"> & {
|
||||
id: "gemini-3.5-flash";
|
||||
provider: "google";
|
||||
};
|
||||
"gemini-flash-latest": Model<"google-generative-ai"> & {
|
||||
id: "gemini-flash-latest";
|
||||
provider: "google";
|
||||
};
|
||||
"gemini-flash-lite-latest": Model<"google-generative-ai"> & {
|
||||
id: "gemini-flash-lite-latest";
|
||||
provider: "google";
|
||||
};
|
||||
"gemma-4-26b-a4b-it": Model<"google-generative-ai"> & {
|
||||
id: "gemma-4-26b-a4b-it";
|
||||
provider: "google";
|
||||
};
|
||||
"gemma-4-31b-it": Model<"google-generative-ai"> & {
|
||||
id: "gemma-4-31b-it";
|
||||
provider: "google";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,127 +1,36 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/groq.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const GROQ_MODELS = {
|
||||
"llama-3.1-8b-instant": {
|
||||
id: "llama-3.1-8b-instant",
|
||||
name: "Llama 3.1 8B",
|
||||
api: "openai-completions",
|
||||
provider: "groq",
|
||||
baseUrl: "https://api.groq.com/openai/v1",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.05,
|
||||
output: 0.08,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"llama-3.3-70b-versatile": {
|
||||
id: "llama-3.3-70b-versatile",
|
||||
name: "Llama 3.3 70B",
|
||||
api: "openai-completions",
|
||||
provider: "groq",
|
||||
baseUrl: "https://api.groq.com/openai/v1",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.59,
|
||||
output: 0.79,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"meta-llama/llama-4-scout-17b-16e-instruct": {
|
||||
id: "meta-llama/llama-4-scout-17b-16e-instruct",
|
||||
name: "Llama 4 Scout 17B 16E",
|
||||
api: "openai-completions",
|
||||
provider: "groq",
|
||||
baseUrl: "https://api.groq.com/openai/v1",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.11,
|
||||
output: 0.34,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 8192,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"openai/gpt-oss-120b": {
|
||||
id: "openai/gpt-oss-120b",
|
||||
name: "GPT OSS 120B",
|
||||
api: "openai-completions",
|
||||
provider: "groq",
|
||||
baseUrl: "https://api.groq.com/openai/v1",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.15,
|
||||
output: 0.6,
|
||||
cacheRead: 0.075,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"openai/gpt-oss-20b": {
|
||||
id: "openai/gpt-oss-20b",
|
||||
name: "GPT OSS 20B",
|
||||
api: "openai-completions",
|
||||
provider: "groq",
|
||||
baseUrl: "https://api.groq.com/openai/v1",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.075,
|
||||
output: 0.3,
|
||||
cacheRead: 0.0375,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"openai/gpt-oss-safeguard-20b": {
|
||||
id: "openai/gpt-oss-safeguard-20b",
|
||||
name: "Safety GPT OSS 20B",
|
||||
api: "openai-completions",
|
||||
provider: "groq",
|
||||
baseUrl: "https://api.groq.com/openai/v1",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.075,
|
||||
output: 0.3,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"qwen/qwen3-32b": {
|
||||
id: "qwen/qwen3-32b",
|
||||
name: "Qwen3-32B",
|
||||
api: "openai-completions",
|
||||
provider: "groq",
|
||||
baseUrl: "https://api.groq.com/openai/v1",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null,"high":"default"},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.29,
|
||||
output: 0.59,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 40960,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const GROQ_MODELS = values as {
|
||||
"llama-3.1-8b-instant": Model<"openai-completions"> & {
|
||||
id: "llama-3.1-8b-instant";
|
||||
provider: "groq";
|
||||
};
|
||||
"llama-3.3-70b-versatile": Model<"openai-completions"> & {
|
||||
id: "llama-3.3-70b-versatile";
|
||||
provider: "groq";
|
||||
};
|
||||
"meta-llama/llama-4-scout-17b-16e-instruct": Model<"openai-completions"> & {
|
||||
id: "meta-llama/llama-4-scout-17b-16e-instruct";
|
||||
provider: "groq";
|
||||
};
|
||||
"openai/gpt-oss-120b": Model<"openai-completions"> & {
|
||||
id: "openai/gpt-oss-120b";
|
||||
provider: "groq";
|
||||
};
|
||||
"openai/gpt-oss-20b": Model<"openai-completions"> & {
|
||||
id: "openai/gpt-oss-20b";
|
||||
provider: "groq";
|
||||
};
|
||||
"openai/gpt-oss-safeguard-20b": Model<"openai-completions"> & {
|
||||
id: "openai/gpt-oss-safeguard-20b";
|
||||
provider: "groq";
|
||||
};
|
||||
"qwen/qwen3-32b": Model<"openai-completions"> & {
|
||||
id: "qwen/qwen3-32b";
|
||||
provider: "groq";
|
||||
};
|
||||
};
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,103 +1,28 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/kimi-coding.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const KIMI_CODING_MODELS = {
|
||||
"k2p7": {
|
||||
id: "k2p7",
|
||||
name: "Kimi K2.7 Code",
|
||||
api: "anthropic-messages",
|
||||
provider: "kimi-coding",
|
||||
baseUrl: "https://api.kimi.com/coding",
|
||||
headers: {"User-Agent":"KimiCLI/1.5"},
|
||||
compat: {"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.19,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"k3": {
|
||||
id: "k3",
|
||||
name: "Kimi K3",
|
||||
api: "anthropic-messages",
|
||||
provider: "kimi-coding",
|
||||
baseUrl: "https://api.kimi.com/coding",
|
||||
headers: {"User-Agent":"KimiCLI/1.5"},
|
||||
compat: {"allowEmptySignature":true,"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null,"low":null,"medium":null,"high":null,"xhigh":null,"max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"kimi-for-coding": {
|
||||
id: "kimi-for-coding",
|
||||
name: "Kimi For Coding",
|
||||
api: "anthropic-messages",
|
||||
provider: "kimi-coding",
|
||||
baseUrl: "https://api.kimi.com/coding",
|
||||
headers: {"User-Agent":"KimiCLI/1.5"},
|
||||
compat: {"allowEmptySignature":true,"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.19,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"kimi-for-coding-highspeed": {
|
||||
id: "kimi-for-coding-highspeed",
|
||||
name: "Kimi For Coding HighSpeed",
|
||||
api: "anthropic-messages",
|
||||
provider: "kimi-coding",
|
||||
baseUrl: "https://api.kimi.com/coding",
|
||||
headers: {"User-Agent":"KimiCLI/1.5"},
|
||||
compat: {"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.9,
|
||||
output: 8,
|
||||
cacheRead: 0.38,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"kimi-k2-thinking": {
|
||||
id: "kimi-k2-thinking",
|
||||
name: "Kimi K2 Thinking",
|
||||
api: "anthropic-messages",
|
||||
provider: "kimi-coding",
|
||||
baseUrl: "https://api.kimi.com/coding",
|
||||
headers: {"User-Agent":"KimiCLI/1.5"},
|
||||
compat: {"forceAdaptiveThinking":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 2.5,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
} as const;
|
||||
export const KIMI_CODING_MODELS = values as {
|
||||
"k2p7": Model<"anthropic-messages"> & {
|
||||
id: "k2p7";
|
||||
provider: "kimi-coding";
|
||||
};
|
||||
"k3": Model<"anthropic-messages"> & {
|
||||
id: "k3";
|
||||
provider: "kimi-coding";
|
||||
};
|
||||
"kimi-for-coding": Model<"anthropic-messages"> & {
|
||||
id: "kimi-for-coding";
|
||||
provider: "kimi-coding";
|
||||
};
|
||||
"kimi-for-coding-highspeed": Model<"anthropic-messages"> & {
|
||||
id: "kimi-for-coding-highspeed";
|
||||
provider: "kimi-coding";
|
||||
};
|
||||
"kimi-k2-thinking": Model<"anthropic-messages"> & {
|
||||
id: "kimi-k2-thinking";
|
||||
provider: "kimi-coding";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,58 +1,20 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/minimax-cn.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const MINIMAX_CN_MODELS = {
|
||||
"MiniMax-M2.7": {
|
||||
id: "MiniMax-M2.7",
|
||||
name: "MiniMax-M2.7",
|
||||
api: "anthropic-messages",
|
||||
provider: "minimax-cn",
|
||||
baseUrl: "https://api.minimaxi.com/anthropic",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 1.2,
|
||||
cacheRead: 0.06,
|
||||
cacheWrite: 0.375,
|
||||
},
|
||||
contextWindow: 204800,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"MiniMax-M2.7-highspeed": {
|
||||
id: "MiniMax-M2.7-highspeed",
|
||||
name: "MiniMax-M2.7-highspeed",
|
||||
api: "anthropic-messages",
|
||||
provider: "minimax-cn",
|
||||
baseUrl: "https://api.minimaxi.com/anthropic",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 2.4,
|
||||
cacheRead: 0.06,
|
||||
cacheWrite: 0.375,
|
||||
},
|
||||
contextWindow: 204800,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"MiniMax-M3": {
|
||||
id: "MiniMax-M3",
|
||||
name: "MiniMax-M3",
|
||||
api: "anthropic-messages",
|
||||
provider: "minimax-cn",
|
||||
baseUrl: "https://api.minimaxi.com/anthropic",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 1.2,
|
||||
cacheRead: 0.06,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
} as const;
|
||||
export const MINIMAX_CN_MODELS = values as {
|
||||
"MiniMax-M2.7": Model<"anthropic-messages"> & {
|
||||
id: "MiniMax-M2.7";
|
||||
provider: "minimax-cn";
|
||||
};
|
||||
"MiniMax-M2.7-highspeed": Model<"anthropic-messages"> & {
|
||||
id: "MiniMax-M2.7-highspeed";
|
||||
provider: "minimax-cn";
|
||||
};
|
||||
"MiniMax-M3": Model<"anthropic-messages"> & {
|
||||
id: "MiniMax-M3";
|
||||
provider: "minimax-cn";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,58 +1,20 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/minimax.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const MINIMAX_MODELS = {
|
||||
"MiniMax-M2.7": {
|
||||
id: "MiniMax-M2.7",
|
||||
name: "MiniMax-M2.7",
|
||||
api: "anthropic-messages",
|
||||
provider: "minimax",
|
||||
baseUrl: "https://api.minimax.io/anthropic",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 1.2,
|
||||
cacheRead: 0.06,
|
||||
cacheWrite: 0.375,
|
||||
},
|
||||
contextWindow: 204800,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"MiniMax-M2.7-highspeed": {
|
||||
id: "MiniMax-M2.7-highspeed",
|
||||
name: "MiniMax-M2.7-highspeed",
|
||||
api: "anthropic-messages",
|
||||
provider: "minimax",
|
||||
baseUrl: "https://api.minimax.io/anthropic",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 2.4,
|
||||
cacheRead: 0.06,
|
||||
cacheWrite: 0.375,
|
||||
},
|
||||
contextWindow: 204800,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"MiniMax-M3": {
|
||||
id: "MiniMax-M3",
|
||||
name: "MiniMax-M3",
|
||||
api: "anthropic-messages",
|
||||
provider: "minimax",
|
||||
baseUrl: "https://api.minimax.io/anthropic",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 1.2,
|
||||
cacheRead: 0.06,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
} as const;
|
||||
export const MINIMAX_MODELS = values as {
|
||||
"MiniMax-M2.7": Model<"anthropic-messages"> & {
|
||||
id: "MiniMax-M2.7";
|
||||
provider: "minimax";
|
||||
};
|
||||
"MiniMax-M2.7-highspeed": Model<"anthropic-messages"> & {
|
||||
id: "MiniMax-M2.7-highspeed";
|
||||
provider: "minimax";
|
||||
};
|
||||
"MiniMax-M3": Model<"anthropic-messages"> & {
|
||||
id: "MiniMax-M3";
|
||||
provider: "minimax";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,517 +1,128 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/mistral.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const MISTRAL_MODELS = {
|
||||
"codestral-latest": {
|
||||
id: "codestral-latest",
|
||||
name: "Codestral (latest)",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 0.9,
|
||||
cacheRead: 0.03,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 4096,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"devstral-2512": {
|
||||
id: "devstral-2512",
|
||||
name: "Devstral 2",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.4,
|
||||
output: 2,
|
||||
cacheRead: 0.04,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"devstral-latest": {
|
||||
id: "devstral-latest",
|
||||
name: "Devstral 2",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.4,
|
||||
output: 2,
|
||||
cacheRead: 0.04,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"devstral-medium-2507": {
|
||||
id: "devstral-medium-2507",
|
||||
name: "Devstral Medium",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.4,
|
||||
output: 2,
|
||||
cacheRead: 0.04,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"devstral-medium-latest": {
|
||||
id: "devstral-medium-latest",
|
||||
name: "Devstral 2 (latest)",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.4,
|
||||
output: 2,
|
||||
cacheRead: 0.04,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"devstral-small-2505": {
|
||||
id: "devstral-small-2505",
|
||||
name: "Devstral Small 2505",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.1,
|
||||
output: 0.3,
|
||||
cacheRead: 0.01,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"devstral-small-2507": {
|
||||
id: "devstral-small-2507",
|
||||
name: "Devstral Small",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.1,
|
||||
output: 0.3,
|
||||
cacheRead: 0.01,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"labs-devstral-small-2512": {
|
||||
id: "labs-devstral-small-2512",
|
||||
name: "Devstral Small 2",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 256000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"magistral-medium-latest": {
|
||||
id: "magistral-medium-latest",
|
||||
name: "Magistral Medium (latest)",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 5,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"magistral-small": {
|
||||
id: "magistral-small",
|
||||
name: "Magistral Small",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.5,
|
||||
output: 1.5,
|
||||
cacheRead: 0.05,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"ministral-3b-latest": {
|
||||
id: "ministral-3b-latest",
|
||||
name: "Ministral 3B (latest)",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.04,
|
||||
output: 0.04,
|
||||
cacheRead: 0.004,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"ministral-8b-latest": {
|
||||
id: "ministral-8b-latest",
|
||||
name: "Ministral 8B (latest)",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.1,
|
||||
output: 0.1,
|
||||
cacheRead: 0.01,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"mistral-large-2411": {
|
||||
id: "mistral-large-2411",
|
||||
name: "Mistral Large 2.1",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 6,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"mistral-large-2512": {
|
||||
id: "mistral-large-2512",
|
||||
name: "Mistral Large 3",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.5,
|
||||
output: 1.5,
|
||||
cacheRead: 0.05,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"mistral-large-latest": {
|
||||
id: "mistral-large-latest",
|
||||
name: "Mistral Large (latest)",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.5,
|
||||
output: 1.5,
|
||||
cacheRead: 0.05,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"mistral-medium-2505": {
|
||||
id: "mistral-medium-2505",
|
||||
name: "Mistral Medium 3",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.4,
|
||||
output: 2,
|
||||
cacheRead: 0.04,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"mistral-medium-2508": {
|
||||
id: "mistral-medium-2508",
|
||||
name: "Mistral Medium 3.1",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.4,
|
||||
output: 2,
|
||||
cacheRead: 0.04,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"mistral-medium-2604": {
|
||||
id: "mistral-medium-2604",
|
||||
name: "Mistral Medium 3.5",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.5,
|
||||
output: 7.5,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"mistral-medium-3.5": {
|
||||
id: "mistral-medium-3.5",
|
||||
name: "Mistral Medium 3.5",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.5,
|
||||
output: 7.5,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"mistral-medium-latest": {
|
||||
id: "mistral-medium-latest",
|
||||
name: "Mistral Medium (latest)",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.5,
|
||||
output: 7.5,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"mistral-nemo": {
|
||||
id: "mistral-nemo",
|
||||
name: "Mistral Nemo",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.15,
|
||||
output: 0.15,
|
||||
cacheRead: 0.015,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"mistral-small-2506": {
|
||||
id: "mistral-small-2506",
|
||||
name: "Mistral Small 3.2",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.1,
|
||||
output: 0.3,
|
||||
cacheRead: 0.01,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"mistral-small-2603": {
|
||||
id: "mistral-small-2603",
|
||||
name: "Mistral Small 4",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.15,
|
||||
output: 0.6,
|
||||
cacheRead: 0.015,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 256000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"mistral-small-latest": {
|
||||
id: "mistral-small-latest",
|
||||
name: "Mistral Small (latest)",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.15,
|
||||
output: 0.6,
|
||||
cacheRead: 0.015,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 256000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"open-mistral-7b": {
|
||||
id: "open-mistral-7b",
|
||||
name: "Mistral 7B",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.25,
|
||||
output: 0.25,
|
||||
cacheRead: 0.025,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 8000,
|
||||
maxTokens: 8000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"open-mistral-nemo": {
|
||||
id: "open-mistral-nemo",
|
||||
name: "Open Mistral Nemo",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.15,
|
||||
output: 0.15,
|
||||
cacheRead: 0.015,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"open-mixtral-8x22b": {
|
||||
id: "open-mixtral-8x22b",
|
||||
name: "Mixtral 8x22B",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 6,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 64000,
|
||||
maxTokens: 64000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"open-mixtral-8x7b": {
|
||||
id: "open-mixtral-8x7b",
|
||||
name: "Mixtral 8x7B",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.7,
|
||||
output: 0.7,
|
||||
cacheRead: 0.07,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 32000,
|
||||
maxTokens: 32000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"pixtral-12b": {
|
||||
id: "pixtral-12b",
|
||||
name: "Pixtral 12B",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.15,
|
||||
output: 0.15,
|
||||
cacheRead: 0.015,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
"pixtral-large-latest": {
|
||||
id: "pixtral-large-latest",
|
||||
name: "Pixtral Large (latest)",
|
||||
api: "mistral-conversations",
|
||||
provider: "mistral",
|
||||
baseUrl: "https://api.mistral.ai",
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 6,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"mistral-conversations">,
|
||||
} as const;
|
||||
export const MISTRAL_MODELS = values as {
|
||||
"codestral-latest": Model<"mistral-conversations"> & {
|
||||
id: "codestral-latest";
|
||||
provider: "mistral";
|
||||
};
|
||||
"devstral-2512": Model<"mistral-conversations"> & {
|
||||
id: "devstral-2512";
|
||||
provider: "mistral";
|
||||
};
|
||||
"devstral-latest": Model<"mistral-conversations"> & {
|
||||
id: "devstral-latest";
|
||||
provider: "mistral";
|
||||
};
|
||||
"devstral-medium-2507": Model<"mistral-conversations"> & {
|
||||
id: "devstral-medium-2507";
|
||||
provider: "mistral";
|
||||
};
|
||||
"devstral-medium-latest": Model<"mistral-conversations"> & {
|
||||
id: "devstral-medium-latest";
|
||||
provider: "mistral";
|
||||
};
|
||||
"devstral-small-2505": Model<"mistral-conversations"> & {
|
||||
id: "devstral-small-2505";
|
||||
provider: "mistral";
|
||||
};
|
||||
"devstral-small-2507": Model<"mistral-conversations"> & {
|
||||
id: "devstral-small-2507";
|
||||
provider: "mistral";
|
||||
};
|
||||
"labs-devstral-small-2512": Model<"mistral-conversations"> & {
|
||||
id: "labs-devstral-small-2512";
|
||||
provider: "mistral";
|
||||
};
|
||||
"magistral-medium-latest": Model<"mistral-conversations"> & {
|
||||
id: "magistral-medium-latest";
|
||||
provider: "mistral";
|
||||
};
|
||||
"magistral-small": Model<"mistral-conversations"> & {
|
||||
id: "magistral-small";
|
||||
provider: "mistral";
|
||||
};
|
||||
"ministral-3b-latest": Model<"mistral-conversations"> & {
|
||||
id: "ministral-3b-latest";
|
||||
provider: "mistral";
|
||||
};
|
||||
"ministral-8b-latest": Model<"mistral-conversations"> & {
|
||||
id: "ministral-8b-latest";
|
||||
provider: "mistral";
|
||||
};
|
||||
"mistral-large-2411": Model<"mistral-conversations"> & {
|
||||
id: "mistral-large-2411";
|
||||
provider: "mistral";
|
||||
};
|
||||
"mistral-large-2512": Model<"mistral-conversations"> & {
|
||||
id: "mistral-large-2512";
|
||||
provider: "mistral";
|
||||
};
|
||||
"mistral-large-latest": Model<"mistral-conversations"> & {
|
||||
id: "mistral-large-latest";
|
||||
provider: "mistral";
|
||||
};
|
||||
"mistral-medium-2505": Model<"mistral-conversations"> & {
|
||||
id: "mistral-medium-2505";
|
||||
provider: "mistral";
|
||||
};
|
||||
"mistral-medium-2508": Model<"mistral-conversations"> & {
|
||||
id: "mistral-medium-2508";
|
||||
provider: "mistral";
|
||||
};
|
||||
"mistral-medium-2604": Model<"mistral-conversations"> & {
|
||||
id: "mistral-medium-2604";
|
||||
provider: "mistral";
|
||||
};
|
||||
"mistral-medium-3.5": Model<"mistral-conversations"> & {
|
||||
id: "mistral-medium-3.5";
|
||||
provider: "mistral";
|
||||
};
|
||||
"mistral-medium-latest": Model<"mistral-conversations"> & {
|
||||
id: "mistral-medium-latest";
|
||||
provider: "mistral";
|
||||
};
|
||||
"mistral-nemo": Model<"mistral-conversations"> & {
|
||||
id: "mistral-nemo";
|
||||
provider: "mistral";
|
||||
};
|
||||
"mistral-small-2506": Model<"mistral-conversations"> & {
|
||||
id: "mistral-small-2506";
|
||||
provider: "mistral";
|
||||
};
|
||||
"mistral-small-2603": Model<"mistral-conversations"> & {
|
||||
id: "mistral-small-2603";
|
||||
provider: "mistral";
|
||||
};
|
||||
"mistral-small-latest": Model<"mistral-conversations"> & {
|
||||
id: "mistral-small-latest";
|
||||
provider: "mistral";
|
||||
};
|
||||
"open-mistral-7b": Model<"mistral-conversations"> & {
|
||||
id: "open-mistral-7b";
|
||||
provider: "mistral";
|
||||
};
|
||||
"open-mistral-nemo": Model<"mistral-conversations"> & {
|
||||
id: "open-mistral-nemo";
|
||||
provider: "mistral";
|
||||
};
|
||||
"open-mixtral-8x22b": Model<"mistral-conversations"> & {
|
||||
id: "open-mixtral-8x22b";
|
||||
provider: "mistral";
|
||||
};
|
||||
"open-mixtral-8x7b": Model<"mistral-conversations"> & {
|
||||
id: "open-mixtral-8x7b";
|
||||
provider: "mistral";
|
||||
};
|
||||
"pixtral-12b": Model<"mistral-conversations"> & {
|
||||
id: "pixtral-12b";
|
||||
provider: "mistral";
|
||||
};
|
||||
"pixtral-large-latest": Model<"mistral-conversations"> & {
|
||||
id: "pixtral-large-latest";
|
||||
provider: "mistral";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,190 +1,48 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/moonshotai-cn.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const MOONSHOTAI_CN_MODELS = {
|
||||
"kimi-k2-0711-preview": {
|
||||
id: "kimi-k2-0711-preview",
|
||||
name: "Kimi K2 0711",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai-cn",
|
||||
baseUrl: "https://api.moonshot.cn/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 2.5,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2-0905-preview": {
|
||||
id: "kimi-k2-0905-preview",
|
||||
name: "Kimi K2 0905",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai-cn",
|
||||
baseUrl: "https://api.moonshot.cn/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 2.5,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2-thinking": {
|
||||
id: "kimi-k2-thinking",
|
||||
name: "Kimi K2 Thinking",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai-cn",
|
||||
baseUrl: "https://api.moonshot.cn/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 2.5,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2-thinking-turbo": {
|
||||
id: "kimi-k2-thinking-turbo",
|
||||
name: "Kimi K2 Thinking Turbo",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai-cn",
|
||||
baseUrl: "https://api.moonshot.cn/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.15,
|
||||
output: 8,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2-turbo-preview": {
|
||||
id: "kimi-k2-turbo-preview",
|
||||
name: "Kimi K2 Turbo",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai-cn",
|
||||
baseUrl: "https://api.moonshot.cn/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 2.4,
|
||||
output: 10,
|
||||
cacheRead: 0.6,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2.5": {
|
||||
id: "kimi-k2.5",
|
||||
name: "Kimi K2.5",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai-cn",
|
||||
baseUrl: "https://api.moonshot.cn/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 3,
|
||||
cacheRead: 0.1,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2.6": {
|
||||
id: "kimi-k2.6",
|
||||
name: "Kimi K2.6",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai-cn",
|
||||
baseUrl: "https://api.moonshot.cn/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.16,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2.7-code": {
|
||||
id: "kimi-k2.7-code",
|
||||
name: "Kimi K2.7 Code",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai-cn",
|
||||
baseUrl: "https://api.moonshot.cn/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.19,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2.7-code-highspeed": {
|
||||
id: "kimi-k2.7-code-highspeed",
|
||||
name: "Kimi K2.7 Code HighSpeed",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai-cn",
|
||||
baseUrl: "https://api.moonshot.cn/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.9,
|
||||
output: 8,
|
||||
cacheRead: 0.38,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k3": {
|
||||
id: "kimi-k3",
|
||||
name: "Kimi K3",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai-cn",
|
||||
baseUrl: "https://api.moonshot.cn/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek","requiresReasoningContentOnAssistantMessages":true,"deferredToolsMode":"kimi"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null,"low":null,"medium":null,"high":null,"xhigh":null,"max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const MOONSHOTAI_CN_MODELS = values as {
|
||||
"kimi-k2-0711-preview": Model<"openai-completions"> & {
|
||||
id: "kimi-k2-0711-preview";
|
||||
provider: "moonshotai-cn";
|
||||
};
|
||||
"kimi-k2-0905-preview": Model<"openai-completions"> & {
|
||||
id: "kimi-k2-0905-preview";
|
||||
provider: "moonshotai-cn";
|
||||
};
|
||||
"kimi-k2-thinking": Model<"openai-completions"> & {
|
||||
id: "kimi-k2-thinking";
|
||||
provider: "moonshotai-cn";
|
||||
};
|
||||
"kimi-k2-thinking-turbo": Model<"openai-completions"> & {
|
||||
id: "kimi-k2-thinking-turbo";
|
||||
provider: "moonshotai-cn";
|
||||
};
|
||||
"kimi-k2-turbo-preview": Model<"openai-completions"> & {
|
||||
id: "kimi-k2-turbo-preview";
|
||||
provider: "moonshotai-cn";
|
||||
};
|
||||
"kimi-k2.5": Model<"openai-completions"> & {
|
||||
id: "kimi-k2.5";
|
||||
provider: "moonshotai-cn";
|
||||
};
|
||||
"kimi-k2.6": Model<"openai-completions"> & {
|
||||
id: "kimi-k2.6";
|
||||
provider: "moonshotai-cn";
|
||||
};
|
||||
"kimi-k2.7-code": Model<"openai-completions"> & {
|
||||
id: "kimi-k2.7-code";
|
||||
provider: "moonshotai-cn";
|
||||
};
|
||||
"kimi-k2.7-code-highspeed": Model<"openai-completions"> & {
|
||||
id: "kimi-k2.7-code-highspeed";
|
||||
provider: "moonshotai-cn";
|
||||
};
|
||||
"kimi-k3": Model<"openai-completions"> & {
|
||||
id: "kimi-k3";
|
||||
provider: "moonshotai-cn";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,190 +1,48 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/moonshotai.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const MOONSHOTAI_MODELS = {
|
||||
"kimi-k2-0711-preview": {
|
||||
id: "kimi-k2-0711-preview",
|
||||
name: "Kimi K2 0711",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai",
|
||||
baseUrl: "https://api.moonshot.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 2.5,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2-0905-preview": {
|
||||
id: "kimi-k2-0905-preview",
|
||||
name: "Kimi K2 0905",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai",
|
||||
baseUrl: "https://api.moonshot.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 2.5,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2-thinking": {
|
||||
id: "kimi-k2-thinking",
|
||||
name: "Kimi K2 Thinking",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai",
|
||||
baseUrl: "https://api.moonshot.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 2.5,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2-thinking-turbo": {
|
||||
id: "kimi-k2-thinking-turbo",
|
||||
name: "Kimi K2 Thinking Turbo",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai",
|
||||
baseUrl: "https://api.moonshot.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.15,
|
||||
output: 8,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2-turbo-preview": {
|
||||
id: "kimi-k2-turbo-preview",
|
||||
name: "Kimi K2 Turbo",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai",
|
||||
baseUrl: "https://api.moonshot.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 2.4,
|
||||
output: 10,
|
||||
cacheRead: 0.6,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2.5": {
|
||||
id: "kimi-k2.5",
|
||||
name: "Kimi K2.5",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai",
|
||||
baseUrl: "https://api.moonshot.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 3,
|
||||
cacheRead: 0.1,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2.6": {
|
||||
id: "kimi-k2.6",
|
||||
name: "Kimi K2.6",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai",
|
||||
baseUrl: "https://api.moonshot.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.16,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2.7-code": {
|
||||
id: "kimi-k2.7-code",
|
||||
name: "Kimi K2.7 Code",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai",
|
||||
baseUrl: "https://api.moonshot.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.19,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2.7-code-highspeed": {
|
||||
id: "kimi-k2.7-code-highspeed",
|
||||
name: "Kimi K2.7 Code HighSpeed",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai",
|
||||
baseUrl: "https://api.moonshot.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.9,
|
||||
output: 8,
|
||||
cacheRead: 0.38,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k3": {
|
||||
id: "kimi-k3",
|
||||
name: "Kimi K3",
|
||||
api: "openai-completions",
|
||||
provider: "moonshotai",
|
||||
baseUrl: "https://api.moonshot.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"thinkingFormat":"deepseek","requiresReasoningContentOnAssistantMessages":true,"deferredToolsMode":"kimi"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null,"low":null,"medium":null,"high":null,"xhigh":null,"max":"max"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const MOONSHOTAI_MODELS = values as {
|
||||
"kimi-k2-0711-preview": Model<"openai-completions"> & {
|
||||
id: "kimi-k2-0711-preview";
|
||||
provider: "moonshotai";
|
||||
};
|
||||
"kimi-k2-0905-preview": Model<"openai-completions"> & {
|
||||
id: "kimi-k2-0905-preview";
|
||||
provider: "moonshotai";
|
||||
};
|
||||
"kimi-k2-thinking": Model<"openai-completions"> & {
|
||||
id: "kimi-k2-thinking";
|
||||
provider: "moonshotai";
|
||||
};
|
||||
"kimi-k2-thinking-turbo": Model<"openai-completions"> & {
|
||||
id: "kimi-k2-thinking-turbo";
|
||||
provider: "moonshotai";
|
||||
};
|
||||
"kimi-k2-turbo-preview": Model<"openai-completions"> & {
|
||||
id: "kimi-k2-turbo-preview";
|
||||
provider: "moonshotai";
|
||||
};
|
||||
"kimi-k2.5": Model<"openai-completions"> & {
|
||||
id: "kimi-k2.5";
|
||||
provider: "moonshotai";
|
||||
};
|
||||
"kimi-k2.6": Model<"openai-completions"> & {
|
||||
id: "kimi-k2.6";
|
||||
provider: "moonshotai";
|
||||
};
|
||||
"kimi-k2.7-code": Model<"openai-completions"> & {
|
||||
id: "kimi-k2.7-code";
|
||||
provider: "moonshotai";
|
||||
};
|
||||
"kimi-k2.7-code-highspeed": Model<"openai-completions"> & {
|
||||
id: "kimi-k2.7-code-highspeed";
|
||||
provider: "moonshotai";
|
||||
};
|
||||
"kimi-k3": Model<"openai-completions"> & {
|
||||
id: "kimi-k3";
|
||||
provider: "moonshotai";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,387 +1,88 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/nvidia.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const NVIDIA_MODELS = {
|
||||
"meta/llama-3.1-70b-instruct": {
|
||||
id: "meta/llama-3.1-70b-instruct",
|
||||
name: "Llama 3.1 70b Instruct",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 4096,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"meta/llama-3.1-8b-instruct": {
|
||||
id: "meta/llama-3.1-8b-instruct",
|
||||
name: "Llama 3.1 8B Instruct",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 16000,
|
||||
maxTokens: 4096,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"meta/llama-3.2-11b-vision-instruct": {
|
||||
id: "meta/llama-3.2-11b-vision-instruct",
|
||||
name: "Llama 3.2 11b Vision Instruct",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 4096,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"meta/llama-3.2-90b-vision-instruct": {
|
||||
id: "meta/llama-3.2-90b-vision-instruct",
|
||||
name: "Llama-3.2-90B-Vision-Instruct",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 8192,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"meta/llama-3.3-70b-instruct": {
|
||||
id: "meta/llama-3.3-70b-instruct",
|
||||
name: "Llama 3.3 70b Instruct",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 4096,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"minimaxai/minimax-m3": {
|
||||
id: "minimaxai/minimax-m3",
|
||||
name: "MiniMax-M3",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mistralai/mistral-large-3-675b-instruct-2512": {
|
||||
id: "mistralai/mistral-large-3-675b-instruct-2512",
|
||||
name: "Mistral Large 3 675B Instruct 2512",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: false,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mistralai/mistral-small-4-119b-2603": {
|
||||
id: "mistralai/mistral-small-4-119b-2603",
|
||||
name: "mistral-small-4-119b-2603",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 8192,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"moonshotai/kimi-k2.6": {
|
||||
id: "moonshotai/kimi-k2.6",
|
||||
name: "Kimi K2.6",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"nvidia/nemotron-3-nano-30b-a3b": {
|
||||
id: "nvidia/nemotron-3-nano-30b-a3b",
|
||||
name: "nemotron-3-nano-30b-a3b",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"nvidia/nemotron-3-nano-omni-30b-a3b-reasoning": {
|
||||
id: "nvidia/nemotron-3-nano-omni-30b-a3b-reasoning",
|
||||
name: "Nemotron 3 Nano Omni",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"nvidia/nemotron-3-super-120b-a12b": {
|
||||
id: "nvidia/nemotron-3-super-120b-a12b",
|
||||
name: "Nemotron 3 Super",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.2,
|
||||
output: 0.8,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"nvidia/nemotron-3-ultra-550b-a55b": {
|
||||
id: "nvidia/nemotron-3-ultra-550b-a55b",
|
||||
name: "Nemotron 3 Ultra 550B A55B",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.5,
|
||||
output: 2.5,
|
||||
cacheRead: 0.15,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"nvidia/nvidia-nemotron-nano-9b-v2": {
|
||||
id: "nvidia/nvidia-nemotron-nano-9b-v2",
|
||||
name: "nvidia-nemotron-nano-9b-v2",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"openai/gpt-oss-120b": {
|
||||
id: "openai/gpt-oss-120b",
|
||||
name: "GPT-OSS-120B",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 8192,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"openai/gpt-oss-20b": {
|
||||
id: "openai/gpt-oss-20b",
|
||||
name: "GPT OSS 20B",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"qwen/qwen3.5-122b-a10b": {
|
||||
id: "qwen/qwen3.5-122b-a10b",
|
||||
name: "Qwen3.5 122B-A10B",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"stepfun-ai/step-3.5-flash": {
|
||||
id: "stepfun-ai/step-3.5-flash",
|
||||
name: "Step 3.5 Flash",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"stepfun-ai/step-3.7-flash": {
|
||||
id: "stepfun-ai/step-3.7-flash",
|
||||
name: "Step 3.7 Flash",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 16384,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"z-ai/glm-5.2": {
|
||||
id: "z-ai/glm-5.2",
|
||||
name: "GLM-5.2",
|
||||
api: "openai-completions",
|
||||
provider: "nvidia",
|
||||
baseUrl: "https://integrate.api.nvidia.com/v1",
|
||||
headers: {"NVCF-POLL-SECONDS":"3600"},
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const NVIDIA_MODELS = values as {
|
||||
"meta/llama-3.1-70b-instruct": Model<"openai-completions"> & {
|
||||
id: "meta/llama-3.1-70b-instruct";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"meta/llama-3.1-8b-instruct": Model<"openai-completions"> & {
|
||||
id: "meta/llama-3.1-8b-instruct";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"meta/llama-3.2-11b-vision-instruct": Model<"openai-completions"> & {
|
||||
id: "meta/llama-3.2-11b-vision-instruct";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"meta/llama-3.2-90b-vision-instruct": Model<"openai-completions"> & {
|
||||
id: "meta/llama-3.2-90b-vision-instruct";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"meta/llama-3.3-70b-instruct": Model<"openai-completions"> & {
|
||||
id: "meta/llama-3.3-70b-instruct";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"minimaxai/minimax-m3": Model<"openai-completions"> & {
|
||||
id: "minimaxai/minimax-m3";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"mistralai/mistral-large-3-675b-instruct-2512": Model<"openai-completions"> & {
|
||||
id: "mistralai/mistral-large-3-675b-instruct-2512";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"mistralai/mistral-small-4-119b-2603": Model<"openai-completions"> & {
|
||||
id: "mistralai/mistral-small-4-119b-2603";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"moonshotai/kimi-k2.6": Model<"openai-completions"> & {
|
||||
id: "moonshotai/kimi-k2.6";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"nvidia/nemotron-3-nano-30b-a3b": Model<"openai-completions"> & {
|
||||
id: "nvidia/nemotron-3-nano-30b-a3b";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"nvidia/nemotron-3-nano-omni-30b-a3b-reasoning": Model<"openai-completions"> & {
|
||||
id: "nvidia/nemotron-3-nano-omni-30b-a3b-reasoning";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"nvidia/nemotron-3-super-120b-a12b": Model<"openai-completions"> & {
|
||||
id: "nvidia/nemotron-3-super-120b-a12b";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"nvidia/nemotron-3-ultra-550b-a55b": Model<"openai-completions"> & {
|
||||
id: "nvidia/nemotron-3-ultra-550b-a55b";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"nvidia/nvidia-nemotron-nano-9b-v2": Model<"openai-completions"> & {
|
||||
id: "nvidia/nvidia-nemotron-nano-9b-v2";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"openai/gpt-oss-120b": Model<"openai-completions"> & {
|
||||
id: "openai/gpt-oss-120b";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"openai/gpt-oss-20b": Model<"openai-completions"> & {
|
||||
id: "openai/gpt-oss-20b";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"qwen/qwen3.5-122b-a10b": Model<"openai-completions"> & {
|
||||
id: "qwen/qwen3.5-122b-a10b";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"stepfun-ai/step-3.5-flash": Model<"openai-completions"> & {
|
||||
id: "stepfun-ai/step-3.5-flash";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"stepfun-ai/step-3.7-flash": Model<"openai-completions"> & {
|
||||
id: "stepfun-ai/step-3.7-flash";
|
||||
provider: "nvidia";
|
||||
};
|
||||
"z-ai/glm-5.2": Model<"openai-completions"> & {
|
||||
id: "z-ai/glm-5.2";
|
||||
provider: "nvidia";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,144 +1,36 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/openai-codex.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const OPENAI_CODEX_MODELS = {
|
||||
"gpt-5.3-codex-spark": {
|
||||
id: "gpt-5.3-codex-spark",
|
||||
name: "GPT-5.3 Codex Spark",
|
||||
api: "openai-codex-responses",
|
||||
provider: "openai-codex",
|
||||
baseUrl: "https://chatgpt.com/backend-api",
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","minimal":"low"},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.75,
|
||||
output: 14,
|
||||
cacheRead: 0.175,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 128000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-codex-responses">,
|
||||
"gpt-5.4": {
|
||||
id: "gpt-5.4",
|
||||
name: "GPT-5.4",
|
||||
api: "openai-codex-responses",
|
||||
provider: "openai-codex",
|
||||
baseUrl: "https://chatgpt.com/backend-api",
|
||||
compat: {"supportsToolSearch":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","minimal":"low"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2.5,
|
||||
output: 15,
|
||||
cacheRead: 0.25,
|
||||
cacheWrite: 0,
|
||||
tiers: [{"inputTokensAbove":272000,"input":5,"output":22.5,"cacheRead":0.5,"cacheWrite":0}],
|
||||
},
|
||||
contextWindow: 272000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-codex-responses">,
|
||||
"gpt-5.4-mini": {
|
||||
id: "gpt-5.4-mini",
|
||||
name: "GPT-5.4 mini",
|
||||
api: "openai-codex-responses",
|
||||
provider: "openai-codex",
|
||||
baseUrl: "https://chatgpt.com/backend-api",
|
||||
compat: {"supportsToolSearch":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","minimal":"low"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.75,
|
||||
output: 4.5,
|
||||
cacheRead: 0.075,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 272000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-codex-responses">,
|
||||
"gpt-5.5": {
|
||||
id: "gpt-5.5",
|
||||
name: "GPT-5.5",
|
||||
api: "openai-codex-responses",
|
||||
provider: "openai-codex",
|
||||
baseUrl: "https://chatgpt.com/backend-api",
|
||||
compat: {"supportsToolSearch":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","minimal":"low"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 30,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 0,
|
||||
tiers: [{"inputTokensAbove":272000,"input":10,"output":45,"cacheRead":1,"cacheWrite":0}],
|
||||
},
|
||||
contextWindow: 272000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-codex-responses">,
|
||||
"gpt-5.6-luna": {
|
||||
id: "gpt-5.6-luna",
|
||||
name: "GPT-5.6 Luna",
|
||||
api: "openai-codex-responses",
|
||||
provider: "openai-codex",
|
||||
baseUrl: "https://chatgpt.com/backend-api",
|
||||
compat: {"supportsToolSearch":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","max":"max","minimal":"low"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1,
|
||||
output: 6,
|
||||
cacheRead: 0.1,
|
||||
cacheWrite: 1.25,
|
||||
tiers: [{"inputTokensAbove":272000,"input":2,"output":9,"cacheRead":0.2,"cacheWrite":2.5}],
|
||||
},
|
||||
contextWindow: 372000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-codex-responses">,
|
||||
"gpt-5.6-sol": {
|
||||
id: "gpt-5.6-sol",
|
||||
name: "GPT-5.6 Sol",
|
||||
api: "openai-codex-responses",
|
||||
provider: "openai-codex",
|
||||
baseUrl: "https://chatgpt.com/backend-api",
|
||||
compat: {"supportsToolSearch":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","max":"max","minimal":"low"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 5,
|
||||
output: 30,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 6.25,
|
||||
tiers: [{"inputTokensAbove":272000,"input":10,"output":45,"cacheRead":1,"cacheWrite":12.5}],
|
||||
},
|
||||
contextWindow: 372000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-codex-responses">,
|
||||
"gpt-5.6-terra": {
|
||||
id: "gpt-5.6-terra",
|
||||
name: "GPT-5.6 Terra",
|
||||
api: "openai-codex-responses",
|
||||
provider: "openai-codex",
|
||||
baseUrl: "https://chatgpt.com/backend-api",
|
||||
compat: {"supportsToolSearch":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"xhigh":"xhigh","max":"max","minimal":"low"},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2.5,
|
||||
output: 15,
|
||||
cacheRead: 0.25,
|
||||
cacheWrite: 3.125,
|
||||
tiers: [{"inputTokensAbove":272000,"input":5,"output":22.5,"cacheRead":0.5,"cacheWrite":6.25}],
|
||||
},
|
||||
contextWindow: 372000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-codex-responses">,
|
||||
} as const;
|
||||
export const OPENAI_CODEX_MODELS = values as {
|
||||
"gpt-5.3-codex-spark": Model<"openai-codex-responses"> & {
|
||||
id: "gpt-5.3-codex-spark";
|
||||
provider: "openai-codex";
|
||||
};
|
||||
"gpt-5.4": Model<"openai-codex-responses"> & {
|
||||
id: "gpt-5.4";
|
||||
provider: "openai-codex";
|
||||
};
|
||||
"gpt-5.4-mini": Model<"openai-codex-responses"> & {
|
||||
id: "gpt-5.4-mini";
|
||||
provider: "openai-codex";
|
||||
};
|
||||
"gpt-5.5": Model<"openai-codex-responses"> & {
|
||||
id: "gpt-5.5";
|
||||
provider: "openai-codex";
|
||||
};
|
||||
"gpt-5.6-luna": Model<"openai-codex-responses"> & {
|
||||
id: "gpt-5.6-luna";
|
||||
provider: "openai-codex";
|
||||
};
|
||||
"gpt-5.6-sol": Model<"openai-codex-responses"> & {
|
||||
id: "gpt-5.6-sol";
|
||||
provider: "openai-codex";
|
||||
};
|
||||
"gpt-5.6-terra": Model<"openai-codex-responses"> & {
|
||||
id: "gpt-5.6-terra";
|
||||
provider: "openai-codex";
|
||||
};
|
||||
};
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,278 +1,68 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/opencode-go.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const OPENCODE_GO_MODELS = {
|
||||
"deepseek-v4-flash": {
|
||||
id: "deepseek-v4-flash",
|
||||
name: "DeepSeek V4 Flash",
|
||||
api: "openai-completions",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"maxTokensField":"max_tokens","requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null,"high":"high","max":"max"},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.14,
|
||||
output: 0.28,
|
||||
cacheRead: 0.0028,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 384000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"deepseek-v4-pro": {
|
||||
id: "deepseek-v4-pro",
|
||||
name: "DeepSeek V4 Pro",
|
||||
api: "openai-completions",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"maxTokensField":"max_tokens","requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null,"high":"high","max":"max"},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.74,
|
||||
output: 3.48,
|
||||
cacheRead: 0.0145,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 384000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"glm-5.1": {
|
||||
id: "glm-5.1",
|
||||
name: "GLM-5.1",
|
||||
api: "openai-completions",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"maxTokensField":"max_tokens"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.4,
|
||||
output: 4.4,
|
||||
cacheRead: 0.26,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 202752,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"glm-5.2": {
|
||||
id: "glm-5.2",
|
||||
name: "GLM-5.2",
|
||||
api: "openai-completions",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"maxTokensField":"max_tokens"},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null,"low":null,"medium":null,"high":"high","max":"max"},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.4,
|
||||
output: 4.4,
|
||||
cacheRead: 0.26,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"grok-4.5": {
|
||||
id: "grok-4.5",
|
||||
name: "Grok 4.5",
|
||||
api: "openai-completions",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"maxTokensField":"max_tokens"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 6,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 500000,
|
||||
maxTokens: 500000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2.6": {
|
||||
id: "kimi-k2.6",
|
||||
name: "Kimi K2.6",
|
||||
api: "openai-completions",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"thinkingFormat":"deepseek","supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.16,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k2.7-code": {
|
||||
id: "kimi-k2.7-code",
|
||||
name: "Kimi K2.7 Code",
|
||||
api: "openai-completions",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"maxTokensField":"max_tokens"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.19,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"kimi-k3": {
|
||||
id: "kimi-k3",
|
||||
name: "Kimi K3",
|
||||
api: "openai-completions",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"maxTokensField":"max_tokens"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 3,
|
||||
output: 15,
|
||||
cacheRead: 0.3,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mimo-v2.5": {
|
||||
id: "mimo-v2.5",
|
||||
name: "MiMo V2.5",
|
||||
api: "openai-completions",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"maxTokensField":"max_tokens"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.14,
|
||||
output: 0.28,
|
||||
cacheRead: 0.0028,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mimo-v2.5-pro": {
|
||||
id: "mimo-v2.5-pro",
|
||||
name: "MiMo V2.5 Pro",
|
||||
api: "openai-completions",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"maxTokensField":"max_tokens"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.74,
|
||||
output: 3.48,
|
||||
cacheRead: 0.0145,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 128000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"minimax-m2.7": {
|
||||
id: "minimax-m2.7",
|
||||
name: "MiniMax-M2.7",
|
||||
api: "openai-completions",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"maxTokensField":"max_tokens"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 1.2,
|
||||
cacheRead: 0.06,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 204800,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"minimax-m3": {
|
||||
id: "minimax-m3",
|
||||
name: "MiniMax-M3",
|
||||
api: "anthropic-messages",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 1.2,
|
||||
cacheRead: 0.06,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"qwen3.6-plus": {
|
||||
id: "qwen3.6-plus",
|
||||
name: "Qwen3.6 Plus",
|
||||
api: "openai-completions",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"thinkingFormat":"qwen","maxTokensField":"max_tokens"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.5,
|
||||
output: 3,
|
||||
cacheRead: 0.05,
|
||||
cacheWrite: 0.625,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"qwen3.7-max": {
|
||||
id: "qwen3.7-max",
|
||||
name: "Qwen3.7 Max",
|
||||
api: "anthropic-messages",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 2.5,
|
||||
output: 7.5,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 3.125,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
"qwen3.7-plus": {
|
||||
id: "qwen3.7-plus",
|
||||
name: "Qwen3.7 Plus",
|
||||
api: "anthropic-messages",
|
||||
provider: "opencode-go",
|
||||
baseUrl: "https://opencode.ai/zen/go",
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.4,
|
||||
output: 1.6,
|
||||
cacheRead: 0.04,
|
||||
cacheWrite: 0.5,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"anthropic-messages">,
|
||||
} as const;
|
||||
export const OPENCODE_GO_MODELS = values as {
|
||||
"deepseek-v4-flash": Model<"openai-completions"> & {
|
||||
id: "deepseek-v4-flash";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"deepseek-v4-pro": Model<"openai-completions"> & {
|
||||
id: "deepseek-v4-pro";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"glm-5.1": Model<"openai-completions"> & {
|
||||
id: "glm-5.1";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"glm-5.2": Model<"openai-completions"> & {
|
||||
id: "glm-5.2";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"grok-4.5": Model<"openai-completions"> & {
|
||||
id: "grok-4.5";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"kimi-k2.6": Model<"openai-completions"> & {
|
||||
id: "kimi-k2.6";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"kimi-k2.7-code": Model<"openai-completions"> & {
|
||||
id: "kimi-k2.7-code";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"kimi-k3": Model<"openai-completions"> & {
|
||||
id: "kimi-k3";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"mimo-v2.5": Model<"openai-completions"> & {
|
||||
id: "mimo-v2.5";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"mimo-v2.5-pro": Model<"openai-completions"> & {
|
||||
id: "mimo-v2.5-pro";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"minimax-m2.7": Model<"openai-completions"> & {
|
||||
id: "minimax-m2.7";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"minimax-m3": Model<"anthropic-messages"> & {
|
||||
id: "minimax-m3";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"qwen3.6-plus": Model<"openai-completions"> & {
|
||||
id: "qwen3.6-plus";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"qwen3.7-max": Model<"anthropic-messages"> & {
|
||||
id: "qwen3.7-max";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
"qwen3.7-plus": Model<"anthropic-messages"> & {
|
||||
id: "qwen3.7-plus";
|
||||
provider: "opencode-go";
|
||||
};
|
||||
};
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1,382 +1,88 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/together.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const TOGETHER_MODELS = {
|
||||
"MiniMaxAI/MiniMax-M2.7": {
|
||||
id: "MiniMaxAI/MiniMax-M2.7",
|
||||
name: "MiniMax-M2.7",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null,"low":null,"medium":null},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 1.2,
|
||||
cacheRead: 0.06,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 202752,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"MiniMaxAI/MiniMax-M3": {
|
||||
id: "MiniMaxAI/MiniMax-M3",
|
||||
name: "MiniMax-M3",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 1.2,
|
||||
cacheRead: 0.06,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 524288,
|
||||
maxTokens: 250000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"Qwen/Qwen2.5-7B-Instruct-Turbo": {
|
||||
id: "Qwen/Qwen2.5-7B-Instruct-Turbo",
|
||||
name: "Qwen 2.5 7B Instruct Turbo",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.3,
|
||||
output: 0.3,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 32768,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"Qwen/Qwen3-235B-A22B-Instruct-2507-tput": {
|
||||
id: "Qwen/Qwen3-235B-A22B-Instruct-2507-tput",
|
||||
name: "Qwen3 235B A22B Instruct 2507 FP8",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.2,
|
||||
output: 0.6,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 262144,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"Qwen/Qwen3.5-397B-A17B": {
|
||||
id: "Qwen/Qwen3.5-397B-A17B",
|
||||
name: "Qwen3.5 397B A17B",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 3.6,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 130000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"Qwen/Qwen3.5-9B": {
|
||||
id: "Qwen/Qwen3.5-9B",
|
||||
name: "Qwen3.5 9B",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.17,
|
||||
output: 0.25,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"Qwen/Qwen3.6-Plus": {
|
||||
id: "Qwen/Qwen3.6-Plus",
|
||||
name: "Qwen3.6 Plus",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.5,
|
||||
output: 3,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 500000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"Qwen/Qwen3.7-Max": {
|
||||
id: "Qwen/Qwen3.7-Max",
|
||||
name: "Qwen3.7 Max",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.25,
|
||||
output: 3.75,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 500000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"deepseek-ai/DeepSeek-V4-Pro": {
|
||||
id: "deepseek-ai/DeepSeek-V4-Pro",
|
||||
name: "DeepSeek V4 Pro",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":true,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null,"high":"high","xhigh":null},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.74,
|
||||
output: 3.48,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 512000,
|
||||
maxTokens: 384000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"essentialai/Rnj-1-Instruct": {
|
||||
id: "essentialai/Rnj-1-Instruct",
|
||||
name: "Rnj-1 Instruct",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.15,
|
||||
output: 0.15,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 32768,
|
||||
maxTokens: 32768,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"google/gemma-4-31B-it": {
|
||||
id: "google/gemma-4-31B-it",
|
||||
name: "Gemma 4 31B Instruct",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.39,
|
||||
output: 0.97,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"meta-llama/Llama-3.3-70B-Instruct-Turbo": {
|
||||
id: "meta-llama/Llama-3.3-70B-Instruct-Turbo",
|
||||
name: "Llama 3.3 70B",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.04,
|
||||
output: 1.04,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"moonshotai/Kimi-K2.6": {
|
||||
id: "moonshotai/Kimi-K2.6",
|
||||
name: "Kimi K2.6",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.2,
|
||||
output: 4.5,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 131000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"moonshotai/Kimi-K2.7-Code": {
|
||||
id: "moonshotai/Kimi-K2.7-Code",
|
||||
name: "Kimi K2.7 Code",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.95,
|
||||
output: 4,
|
||||
cacheRead: 0.19,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"nvidia/nemotron-3-ultra-550b-a55b": {
|
||||
id: "nvidia/nemotron-3-ultra-550b-a55b",
|
||||
name: "Nemotron 3 Ultra 550B A55B",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.6,
|
||||
output: 3.6,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 512300,
|
||||
maxTokens: 512300,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"openai/gpt-oss-120b": {
|
||||
id: "openai/gpt-oss-120b",
|
||||
name: "GPT OSS 120B",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":true,"maxTokensField":"max_tokens","thinkingFormat":"openai","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.15,
|
||||
output: 0.6,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"openai/gpt-oss-20b": {
|
||||
id: "openai/gpt-oss-20b",
|
||||
name: "GPT OSS 20B",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":true,"maxTokensField":"max_tokens","thinkingFormat":"openai","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.05,
|
||||
output: 0.2,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"zai-org/GLM-5": {
|
||||
id: "zai-org/GLM-5",
|
||||
name: "GLM-5",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1,
|
||||
output: 3.2,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 202752,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"zai-org/GLM-5.1": {
|
||||
id: "zai-org/GLM-5.1",
|
||||
name: "GLM-5.1",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.4,
|
||||
output: 4.4,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 202752,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"zai-org/GLM-5.2": {
|
||||
id: "zai-org/GLM-5.2",
|
||||
name: "GLM-5.2",
|
||||
api: "openai-completions",
|
||||
provider: "together",
|
||||
baseUrl: "https://api.together.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"maxTokensField":"max_tokens","thinkingFormat":"together","supportsStrictMode":false,"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":null,"medium":null},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.4,
|
||||
output: 4.4,
|
||||
cacheRead: 0.26,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 164000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const TOGETHER_MODELS = values as {
|
||||
"MiniMaxAI/MiniMax-M2.7": Model<"openai-completions"> & {
|
||||
id: "MiniMaxAI/MiniMax-M2.7";
|
||||
provider: "together";
|
||||
};
|
||||
"MiniMaxAI/MiniMax-M3": Model<"openai-completions"> & {
|
||||
id: "MiniMaxAI/MiniMax-M3";
|
||||
provider: "together";
|
||||
};
|
||||
"Qwen/Qwen2.5-7B-Instruct-Turbo": Model<"openai-completions"> & {
|
||||
id: "Qwen/Qwen2.5-7B-Instruct-Turbo";
|
||||
provider: "together";
|
||||
};
|
||||
"Qwen/Qwen3-235B-A22B-Instruct-2507-tput": Model<"openai-completions"> & {
|
||||
id: "Qwen/Qwen3-235B-A22B-Instruct-2507-tput";
|
||||
provider: "together";
|
||||
};
|
||||
"Qwen/Qwen3.5-397B-A17B": Model<"openai-completions"> & {
|
||||
id: "Qwen/Qwen3.5-397B-A17B";
|
||||
provider: "together";
|
||||
};
|
||||
"Qwen/Qwen3.5-9B": Model<"openai-completions"> & {
|
||||
id: "Qwen/Qwen3.5-9B";
|
||||
provider: "together";
|
||||
};
|
||||
"Qwen/Qwen3.6-Plus": Model<"openai-completions"> & {
|
||||
id: "Qwen/Qwen3.6-Plus";
|
||||
provider: "together";
|
||||
};
|
||||
"Qwen/Qwen3.7-Max": Model<"openai-completions"> & {
|
||||
id: "Qwen/Qwen3.7-Max";
|
||||
provider: "together";
|
||||
};
|
||||
"deepseek-ai/DeepSeek-V4-Pro": Model<"openai-completions"> & {
|
||||
id: "deepseek-ai/DeepSeek-V4-Pro";
|
||||
provider: "together";
|
||||
};
|
||||
"essentialai/Rnj-1-Instruct": Model<"openai-completions"> & {
|
||||
id: "essentialai/Rnj-1-Instruct";
|
||||
provider: "together";
|
||||
};
|
||||
"google/gemma-4-31B-it": Model<"openai-completions"> & {
|
||||
id: "google/gemma-4-31B-it";
|
||||
provider: "together";
|
||||
};
|
||||
"meta-llama/Llama-3.3-70B-Instruct-Turbo": Model<"openai-completions"> & {
|
||||
id: "meta-llama/Llama-3.3-70B-Instruct-Turbo";
|
||||
provider: "together";
|
||||
};
|
||||
"moonshotai/Kimi-K2.6": Model<"openai-completions"> & {
|
||||
id: "moonshotai/Kimi-K2.6";
|
||||
provider: "together";
|
||||
};
|
||||
"moonshotai/Kimi-K2.7-Code": Model<"openai-completions"> & {
|
||||
id: "moonshotai/Kimi-K2.7-Code";
|
||||
provider: "together";
|
||||
};
|
||||
"nvidia/nemotron-3-ultra-550b-a55b": Model<"openai-completions"> & {
|
||||
id: "nvidia/nemotron-3-ultra-550b-a55b";
|
||||
provider: "together";
|
||||
};
|
||||
"openai/gpt-oss-120b": Model<"openai-completions"> & {
|
||||
id: "openai/gpt-oss-120b";
|
||||
provider: "together";
|
||||
};
|
||||
"openai/gpt-oss-20b": Model<"openai-completions"> & {
|
||||
id: "openai/gpt-oss-20b";
|
||||
provider: "together";
|
||||
};
|
||||
"zai-org/GLM-5": Model<"openai-completions"> & {
|
||||
id: "zai-org/GLM-5";
|
||||
provider: "together";
|
||||
};
|
||||
"zai-org/GLM-5.1": Model<"openai-completions"> & {
|
||||
id: "zai-org/GLM-5.1";
|
||||
provider: "together";
|
||||
};
|
||||
"zai-org/GLM-5.2": Model<"openai-completions"> & {
|
||||
id: "zai-org/GLM-5.2";
|
||||
provider: "together";
|
||||
};
|
||||
};
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,62 +1,20 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/xai.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const XAI_MODELS = {
|
||||
"grok-4.3": {
|
||||
id: "grok-4.3",
|
||||
name: "Grok 4.3",
|
||||
api: "openai-completions",
|
||||
provider: "xai",
|
||||
baseUrl: "https://api.x.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1.25,
|
||||
output: 2.5,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 30000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"grok-4.5": {
|
||||
id: "grok-4.5",
|
||||
name: "Grok 4.5",
|
||||
api: "openai-responses",
|
||||
provider: "xai",
|
||||
baseUrl: "https://api.x.ai/v1",
|
||||
compat: {"supportsLongCacheRetention":false},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"off":null,"minimal":null},
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 2,
|
||||
output: 6,
|
||||
cacheRead: 0.5,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 500000,
|
||||
maxTokens: 500000,
|
||||
} satisfies Model<"openai-responses">,
|
||||
"grok-build-0.1": {
|
||||
id: "grok-build-0.1",
|
||||
name: "Grok Build 0.1",
|
||||
api: "openai-completions",
|
||||
provider: "xai",
|
||||
baseUrl: "https://api.x.ai/v1",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 1,
|
||||
output: 2,
|
||||
cacheRead: 0.2,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 256000,
|
||||
maxTokens: 256000,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const XAI_MODELS = values as {
|
||||
"grok-4.3": Model<"openai-completions"> & {
|
||||
id: "grok-4.3";
|
||||
provider: "xai";
|
||||
};
|
||||
"grok-4.5": Model<"openai-responses"> & {
|
||||
id: "grok-4.5";
|
||||
provider: "xai";
|
||||
};
|
||||
"grok-build-0.1": Model<"openai-completions"> & {
|
||||
id: "grok-build-0.1";
|
||||
provider: "xai";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,61 +1,20 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/xiaomi-token-plan-ams.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const XIAOMI_TOKEN_PLAN_AMS_MODELS = {
|
||||
"mimo-v2-pro": {
|
||||
id: "mimo-v2-pro",
|
||||
name: "MiMo-V2-Pro",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi-token-plan-ams",
|
||||
baseUrl: "https://token-plan-ams.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mimo-v2.5": {
|
||||
id: "mimo-v2.5",
|
||||
name: "MiMo-V2.5",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi-token-plan-ams",
|
||||
baseUrl: "https://token-plan-ams.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mimo-v2.5-pro": {
|
||||
id: "mimo-v2.5-pro",
|
||||
name: "MiMo-V2.5-Pro",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi-token-plan-ams",
|
||||
baseUrl: "https://token-plan-ams.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const XIAOMI_TOKEN_PLAN_AMS_MODELS = values as {
|
||||
"mimo-v2-pro": Model<"openai-completions"> & {
|
||||
id: "mimo-v2-pro";
|
||||
provider: "xiaomi-token-plan-ams";
|
||||
};
|
||||
"mimo-v2.5": Model<"openai-completions"> & {
|
||||
id: "mimo-v2.5";
|
||||
provider: "xiaomi-token-plan-ams";
|
||||
};
|
||||
"mimo-v2.5-pro": Model<"openai-completions"> & {
|
||||
id: "mimo-v2.5-pro";
|
||||
provider: "xiaomi-token-plan-ams";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,61 +1,20 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/xiaomi-token-plan-cn.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const XIAOMI_TOKEN_PLAN_CN_MODELS = {
|
||||
"mimo-v2-pro": {
|
||||
id: "mimo-v2-pro",
|
||||
name: "MiMo-V2-Pro",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi-token-plan-cn",
|
||||
baseUrl: "https://token-plan-cn.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mimo-v2.5": {
|
||||
id: "mimo-v2.5",
|
||||
name: "MiMo-V2.5",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi-token-plan-cn",
|
||||
baseUrl: "https://token-plan-cn.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mimo-v2.5-pro": {
|
||||
id: "mimo-v2.5-pro",
|
||||
name: "MiMo-V2.5-Pro",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi-token-plan-cn",
|
||||
baseUrl: "https://token-plan-cn.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const XIAOMI_TOKEN_PLAN_CN_MODELS = values as {
|
||||
"mimo-v2-pro": Model<"openai-completions"> & {
|
||||
id: "mimo-v2-pro";
|
||||
provider: "xiaomi-token-plan-cn";
|
||||
};
|
||||
"mimo-v2.5": Model<"openai-completions"> & {
|
||||
id: "mimo-v2.5";
|
||||
provider: "xiaomi-token-plan-cn";
|
||||
};
|
||||
"mimo-v2.5-pro": Model<"openai-completions"> & {
|
||||
id: "mimo-v2.5-pro";
|
||||
provider: "xiaomi-token-plan-cn";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,61 +1,20 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/xiaomi-token-plan-sgp.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const XIAOMI_TOKEN_PLAN_SGP_MODELS = {
|
||||
"mimo-v2-pro": {
|
||||
id: "mimo-v2-pro",
|
||||
name: "MiMo-V2-Pro",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi-token-plan-sgp",
|
||||
baseUrl: "https://token-plan-sgp.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mimo-v2.5": {
|
||||
id: "mimo-v2.5",
|
||||
name: "MiMo-V2.5",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi-token-plan-sgp",
|
||||
baseUrl: "https://token-plan-sgp.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mimo-v2.5-pro": {
|
||||
id: "mimo-v2.5-pro",
|
||||
name: "MiMo-V2.5-Pro",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi-token-plan-sgp",
|
||||
baseUrl: "https://token-plan-sgp.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const XIAOMI_TOKEN_PLAN_SGP_MODELS = values as {
|
||||
"mimo-v2-pro": Model<"openai-completions"> & {
|
||||
id: "mimo-v2-pro";
|
||||
provider: "xiaomi-token-plan-sgp";
|
||||
};
|
||||
"mimo-v2.5": Model<"openai-completions"> & {
|
||||
id: "mimo-v2.5";
|
||||
provider: "xiaomi-token-plan-sgp";
|
||||
};
|
||||
"mimo-v2.5-pro": Model<"openai-completions"> & {
|
||||
id: "mimo-v2.5-pro";
|
||||
provider: "xiaomi-token-plan-sgp";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,115 +1,32 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/xiaomi.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const XIAOMI_MODELS = {
|
||||
"mimo-v2-flash": {
|
||||
id: "mimo-v2-flash",
|
||||
name: "MiMo-V2-Flash",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi",
|
||||
baseUrl: "https://api.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.14,
|
||||
output: 0.28,
|
||||
cacheRead: 0.0028,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 65536,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mimo-v2-omni": {
|
||||
id: "mimo-v2-omni",
|
||||
name: "MiMo-V2-Omni",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi",
|
||||
baseUrl: "https://api.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.14,
|
||||
output: 0.28,
|
||||
cacheRead: 0.0028,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 262144,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mimo-v2-pro": {
|
||||
id: "mimo-v2-pro",
|
||||
name: "MiMo-V2-Pro",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi",
|
||||
baseUrl: "https://api.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.435,
|
||||
output: 0.87,
|
||||
cacheRead: 0.0036,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mimo-v2.5": {
|
||||
id: "mimo-v2.5",
|
||||
name: "MiMo-V2.5",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi",
|
||||
baseUrl: "https://api.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0.14,
|
||||
output: 0.28,
|
||||
cacheRead: 0.0028,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mimo-v2.5-pro": {
|
||||
id: "mimo-v2.5-pro",
|
||||
name: "MiMo-V2.5-Pro",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi",
|
||||
baseUrl: "https://api.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0.435,
|
||||
output: 0.87,
|
||||
cacheRead: 0.0036,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"mimo-v2.5-pro-ultraspeed": {
|
||||
id: "mimo-v2.5-pro-ultraspeed",
|
||||
name: "MiMo-V2.5-Pro-UltraSpeed",
|
||||
api: "openai-completions",
|
||||
provider: "xiaomi",
|
||||
baseUrl: "https://api.xiaomimimo.com/v1",
|
||||
compat: {"requiresReasoningContentOnAssistantMessages":true,"thinkingFormat":"deepseek"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 1.305,
|
||||
output: 2.61,
|
||||
cacheRead: 0.0108,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1048576,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const XIAOMI_MODELS = values as {
|
||||
"mimo-v2-flash": Model<"openai-completions"> & {
|
||||
id: "mimo-v2-flash";
|
||||
provider: "xiaomi";
|
||||
};
|
||||
"mimo-v2-omni": Model<"openai-completions"> & {
|
||||
id: "mimo-v2-omni";
|
||||
provider: "xiaomi";
|
||||
};
|
||||
"mimo-v2-pro": Model<"openai-completions"> & {
|
||||
id: "mimo-v2-pro";
|
||||
provider: "xiaomi";
|
||||
};
|
||||
"mimo-v2.5": Model<"openai-completions"> & {
|
||||
id: "mimo-v2.5";
|
||||
provider: "xiaomi";
|
||||
};
|
||||
"mimo-v2.5-pro": Model<"openai-completions"> & {
|
||||
id: "mimo-v2.5-pro";
|
||||
provider: "xiaomi";
|
||||
};
|
||||
"mimo-v2.5-pro-ultraspeed": Model<"openai-completions"> & {
|
||||
id: "mimo-v2.5-pro-ultraspeed";
|
||||
provider: "xiaomi";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,116 +1,32 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/zai-coding-cn.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const ZAI_CODING_CN_MODELS = {
|
||||
"glm-4.5-air": {
|
||||
id: "glm-4.5-air",
|
||||
name: "GLM-4.5-Air",
|
||||
api: "openai-completions",
|
||||
provider: "zai-coding-cn",
|
||||
baseUrl: "https://open.bigmodel.cn/api/coding/paas/v4",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"thinkingFormat":"zai"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 98304,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"glm-4.7": {
|
||||
id: "glm-4.7",
|
||||
name: "GLM-4.7",
|
||||
api: "openai-completions",
|
||||
provider: "zai-coding-cn",
|
||||
baseUrl: "https://open.bigmodel.cn/api/coding/paas/v4",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"thinkingFormat":"zai","zaiToolStream":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 204800,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"glm-5-turbo": {
|
||||
id: "glm-5-turbo",
|
||||
name: "GLM-5-Turbo",
|
||||
api: "openai-completions",
|
||||
provider: "zai-coding-cn",
|
||||
baseUrl: "https://open.bigmodel.cn/api/coding/paas/v4",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"thinkingFormat":"zai","zaiToolStream":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"glm-5.1": {
|
||||
id: "glm-5.1",
|
||||
name: "GLM-5.1",
|
||||
api: "openai-completions",
|
||||
provider: "zai-coding-cn",
|
||||
baseUrl: "https://open.bigmodel.cn/api/coding/paas/v4",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"thinkingFormat":"zai","zaiToolStream":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"glm-5.2": {
|
||||
id: "glm-5.2",
|
||||
name: "GLM-5.2",
|
||||
api: "openai-completions",
|
||||
provider: "zai-coding-cn",
|
||||
baseUrl: "https://open.bigmodel.cn/api/coding/paas/v4",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":true,"thinkingFormat":"zai","zaiToolStream":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":"high","medium":"high","high":"high","max":"max"},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"glm-5v-turbo": {
|
||||
id: "glm-5v-turbo",
|
||||
name: "GLM-5V-Turbo",
|
||||
api: "openai-completions",
|
||||
provider: "zai-coding-cn",
|
||||
baseUrl: "https://open.bigmodel.cn/api/coding/paas/v4",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"thinkingFormat":"zai","zaiToolStream":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const ZAI_CODING_CN_MODELS = values as {
|
||||
"glm-4.5-air": Model<"openai-completions"> & {
|
||||
id: "glm-4.5-air";
|
||||
provider: "zai-coding-cn";
|
||||
};
|
||||
"glm-4.7": Model<"openai-completions"> & {
|
||||
id: "glm-4.7";
|
||||
provider: "zai-coding-cn";
|
||||
};
|
||||
"glm-5-turbo": Model<"openai-completions"> & {
|
||||
id: "glm-5-turbo";
|
||||
provider: "zai-coding-cn";
|
||||
};
|
||||
"glm-5.1": Model<"openai-completions"> & {
|
||||
id: "glm-5.1";
|
||||
provider: "zai-coding-cn";
|
||||
};
|
||||
"glm-5.2": Model<"openai-completions"> & {
|
||||
id: "glm-5.2";
|
||||
provider: "zai-coding-cn";
|
||||
};
|
||||
"glm-5v-turbo": Model<"openai-completions"> & {
|
||||
id: "glm-5v-turbo";
|
||||
provider: "zai-coding-cn";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,116 +1,32 @@
|
||||
// This file is auto-generated by scripts/generate-models.ts
|
||||
// Do not edit manually - run 'npm run generate-models' to update
|
||||
|
||||
import values from "./data/zai.json" with { type: "json" };
|
||||
import type { Model } from "../types.ts";
|
||||
|
||||
export const ZAI_MODELS = {
|
||||
"glm-4.5-air": {
|
||||
id: "glm-4.5-air",
|
||||
name: "GLM-4.5-Air",
|
||||
api: "openai-completions",
|
||||
provider: "zai",
|
||||
baseUrl: "https://api.z.ai/api/coding/paas/v4",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"thinkingFormat":"zai"},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 131072,
|
||||
maxTokens: 98304,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"glm-4.7": {
|
||||
id: "glm-4.7",
|
||||
name: "GLM-4.7",
|
||||
api: "openai-completions",
|
||||
provider: "zai",
|
||||
baseUrl: "https://api.z.ai/api/coding/paas/v4",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"thinkingFormat":"zai","zaiToolStream":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 204800,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"glm-5-turbo": {
|
||||
id: "glm-5-turbo",
|
||||
name: "GLM-5-Turbo",
|
||||
api: "openai-completions",
|
||||
provider: "zai",
|
||||
baseUrl: "https://api.z.ai/api/coding/paas/v4",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"thinkingFormat":"zai","zaiToolStream":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"glm-5.1": {
|
||||
id: "glm-5.1",
|
||||
name: "GLM-5.1",
|
||||
api: "openai-completions",
|
||||
provider: "zai",
|
||||
baseUrl: "https://api.z.ai/api/coding/paas/v4",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"thinkingFormat":"zai","zaiToolStream":true},
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"glm-5.2": {
|
||||
id: "glm-5.2",
|
||||
name: "GLM-5.2",
|
||||
api: "openai-completions",
|
||||
provider: "zai",
|
||||
baseUrl: "https://api.z.ai/api/coding/paas/v4",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":true,"thinkingFormat":"zai","zaiToolStream":true},
|
||||
reasoning: true,
|
||||
thinkingLevelMap: {"minimal":null,"low":"high","medium":"high","high":"high","max":"max"},
|
||||
input: ["text"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 1000000,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
"glm-5v-turbo": {
|
||||
id: "glm-5v-turbo",
|
||||
name: "GLM-5V-Turbo",
|
||||
api: "openai-completions",
|
||||
provider: "zai",
|
||||
baseUrl: "https://api.z.ai/api/coding/paas/v4",
|
||||
compat: {"supportsStore":false,"supportsDeveloperRole":false,"supportsReasoningEffort":false,"thinkingFormat":"zai","zaiToolStream":true},
|
||||
reasoning: true,
|
||||
input: ["text", "image"],
|
||||
cost: {
|
||||
input: 0,
|
||||
output: 0,
|
||||
cacheRead: 0,
|
||||
cacheWrite: 0,
|
||||
},
|
||||
contextWindow: 200000,
|
||||
maxTokens: 131072,
|
||||
} satisfies Model<"openai-completions">,
|
||||
} as const;
|
||||
export const ZAI_MODELS = values as {
|
||||
"glm-4.5-air": Model<"openai-completions"> & {
|
||||
id: "glm-4.5-air";
|
||||
provider: "zai";
|
||||
};
|
||||
"glm-4.7": Model<"openai-completions"> & {
|
||||
id: "glm-4.7";
|
||||
provider: "zai";
|
||||
};
|
||||
"glm-5-turbo": Model<"openai-completions"> & {
|
||||
id: "glm-5-turbo";
|
||||
provider: "zai";
|
||||
};
|
||||
"glm-5.1": Model<"openai-completions"> & {
|
||||
id: "glm-5.1";
|
||||
provider: "zai";
|
||||
};
|
||||
"glm-5.2": Model<"openai-completions"> & {
|
||||
id: "glm-5.2";
|
||||
provider: "zai";
|
||||
};
|
||||
"glm-5v-turbo": Model<"openai-completions"> & {
|
||||
id: "glm-5v-turbo";
|
||||
provider: "zai";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -2,7 +2,9 @@
|
||||
"extends": "../../tsconfig.base.json",
|
||||
"compilerOptions": {
|
||||
"outDir": "./dist",
|
||||
"rootDir": "./src"
|
||||
"rootDir": "./src",
|
||||
"module": "NodeNext",
|
||||
"moduleResolution": "NodeNext"
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["node_modules", "dist", "**/*.d.ts", "src/**/*.d.ts"]
|
||||
|
||||
@@ -1,10 +1,27 @@
|
||||
import { writeFileSync } from "node:fs";
|
||||
import { existsSync, writeFileSync } from "node:fs";
|
||||
import { tmpdir } from "node:os";
|
||||
import { join } from "node:path";
|
||||
import { dirname, join, resolve } from "node:path";
|
||||
import { build } from "esbuild";
|
||||
|
||||
const outputPath = join(tmpdir(), "pi-browser-smoke.js");
|
||||
const errorLogPath = join(tmpdir(), "pi-browser-smoke-errors.log");
|
||||
const generatedCatalogDataDir = join(process.cwd(), "packages/ai/src/providers/data");
|
||||
|
||||
// Fresh checkouts do not materialize provider JSON until npm run build.
|
||||
const generatedCatalogDataPlugin = {
|
||||
name: "generated-model-catalog",
|
||||
setup(build) {
|
||||
build.onResolve({ filter: /^\.\/data\/[^/]+\.json$/ }, (args) => {
|
||||
const path = resolve(dirname(args.importer), args.path);
|
||||
if (dirname(path) !== generatedCatalogDataDir || existsSync(path)) return;
|
||||
return { path, namespace: "empty-generated-model-catalog" };
|
||||
});
|
||||
build.onLoad({ filter: /.*/, namespace: "empty-generated-model-catalog" }, () => ({
|
||||
contents: "{}",
|
||||
loader: "json",
|
||||
}));
|
||||
},
|
||||
};
|
||||
|
||||
try {
|
||||
await build({
|
||||
@@ -14,6 +31,7 @@ try {
|
||||
format: "esm",
|
||||
logLevel: "silent",
|
||||
outfile: outputPath,
|
||||
plugins: [generatedCatalogDataPlugin],
|
||||
});
|
||||
process.exit(0);
|
||||
} catch (error) {
|
||||
|
||||
@@ -209,6 +209,10 @@ const bunInstallDirectory = join(outDir, "bun-install");
|
||||
const binaryDirectory = join(outDir, "bun");
|
||||
mkdirSync(tarballDirectory, { recursive: true });
|
||||
|
||||
if (!options.skipCheck || !options.skipTest) {
|
||||
run("npm", ["--prefix", "packages/ai", "run", "generate-models"], { cwd: repoRoot });
|
||||
}
|
||||
|
||||
if (!options.skipCheck) {
|
||||
run("npm", ["run", "check"], { cwd: repoRoot });
|
||||
}
|
||||
|
||||
@@ -2,6 +2,8 @@
|
||||
"extends": "./tsconfig.base.json",
|
||||
"compilerOptions": {
|
||||
"noEmit": true,
|
||||
"module": "NodeNext",
|
||||
"moduleResolution": "NodeNext",
|
||||
"paths": {
|
||||
"*": ["./*"],
|
||||
"@earendil-works/pi-ai": ["./packages/ai/src/index.ts"],
|
||||
|
||||
Reference in New Issue
Block a user