diff --git a/package.json b/package.json index 4a7b90393f7..6ce70c88b55 100644 --- a/package.json +++ b/package.json @@ -18,6 +18,7 @@ "test": "bun test", "validate": "bun ./packages/core/script/validate.ts", "compare:migrations": "bun ./packages/core/script/compare-model-migrations.ts", + "aimlapi:sync": "bun ./packages/core/script/sync-models.ts aimlapi", "anthropic:sync": "bun ./packages/core/script/sync-models.ts anthropic", "baseten:sync": "bun ./packages/core/script/sync-models.ts baseten", "deepinfra:sync": "bun ./packages/core/script/sync-models.ts deepinfra", diff --git a/packages/core/src/sync/index.ts b/packages/core/src/sync/index.ts index f08532afa14..71f1c4a74ec 100644 --- a/packages/core/src/sync/index.ts +++ b/packages/core/src/sync/index.ts @@ -5,6 +5,7 @@ import { z } from "zod"; import { AuthoredModel, AuthoredModelShape, ModelMetadata } from "../schema.js"; import { openMissingModelIssues } from "./missing-issues.js"; +import { aimlapi } from "./providers/aimlapi.js"; import { ambient } from "./providers/ambient.js"; import { anthropic } from "./providers/anthropic.js"; import { baseten } from "./providers/baseten.js"; @@ -128,6 +129,7 @@ export interface SyncResult { } export const providers: { + aimlapi: SyncProvider; ambient: SyncProvider; anthropic: SyncProvider; baseten: SyncProvider; @@ -162,6 +164,7 @@ export const providers: { wandb: SyncProvider; xai: SyncProvider; } = { + aimlapi, ambient, anthropic, baseten, @@ -199,6 +202,7 @@ export const providers: { export const groups = { aggregators: [ + "aimlapi", "crossmodel", "edenai", "empiriolabs", diff --git a/packages/core/src/sync/providers/aimlapi.ts b/packages/core/src/sync/providers/aimlapi.ts new file mode 100755 index 00000000000..d8c7b25c185 --- /dev/null +++ b/packages/core/src/sync/providers/aimlapi.ts @@ -0,0 +1,330 @@ +import { z } from "zod"; + +import type { SyncProvider } from "../index.js"; +import { factorBaseModel, modelMetadata, resolveModelMetadataBaseModel } from "./openrouter.js"; + +// The public catalog needs no key, and `include` is what turns on the pricing +// and modality blocks this sync depends on. +const API_ENDPOINT = "https://api.aimlapi.com/v1/models?include=pricing,modalities"; + +// Per-model request schema. It is the only place the API states which reasoning +// controls a model actually accepts, so reasoning_options is read from here +// rather than assumed. +const DOCS_ENDPOINT = "https://api.aimlapi.com/docs-json"; + +// AI/ML API serves one id under several endpoint types — a model can be both a +// chat model and, say, an image model. Only the chat surface belongs here. +const CHAT_COMPLETIONS_TYPE = "openai/chat-completions"; + +// Values this schema accepts for an "effort" reasoning control. Anything the +// API documents outside this set is dropped rather than coerced. +const EFFORT_VALUES = new Set(["none", "minimal", "low", "medium", "high", "xhigh", "max", "default"]); + +const DOCS_CONCURRENCY = 8; + +const PricingUnit = z + .object({ + name: z.string().nullish(), + content: z.string().nullish(), + origin: z.string().nullish(), + price: z.number().nullish(), + per: z.number().nullish(), + }) + .passthrough(); + +const Info = z + .object({ + contextLength: z.number().int().nonnegative().nullish(), + outputMax: z.number().int().nonnegative().nullish(), + }) + .passthrough(); + +export const AimlapiModel = z + .object({ + id: z.string().min(1), + type: z.string().nullish(), + info: Info.nullish(), + modalities: z + .object({ + input: z.array(z.string()).nullish(), + output: z.array(z.string()).nullish(), + }) + .passthrough() + .nullish(), + pricing: z + .object({ + units: z.array(PricingUnit).nullish(), + }) + .passthrough() + .nullish(), + /** Attached by fetchModels; not part of the upstream payload. */ + reasoningEffort: z.array(z.string()).nullish(), + }) + .passthrough(); + +export const AimlapiResponse = z + .object({ + data: z.array(AimlapiModel).min(1), + }) + .passthrough(); + +export type AimlapiModel = z.infer; + +type Modality = "text" | "audio" | "image" | "video" | "pdf"; + +const MODALITIES = new Set(["text", "audio", "image", "video", "pdf"]); + +function normalizeModalities(values: readonly string[] | null | undefined): Modality[] { + const seen = new Set(); + for (const value of values ?? []) { + const normalized = value.toLowerCase(); + if (MODALITIES.has(normalized)) seen.add(normalized as Modality); + } + if (seen.size === 0) seen.add("text"); + return [...seen]; +} + +/** + * Ids this host also serves on a non-text surface. + * + * The catalog lists an id once per endpoint type, and the chat-surface record of + * an image model claims text output. Measured 2026-09-04: + * `google/gemini-2.5-flash-image` appears both as `openai/image-generations` + * with `output: ["image"]` and as `openai/chat-completions` with + * `output: ["text"]`; the same holds for the `gemini-3-pro-image` and + * `gemini-3.1-flash-image` families. Judging a record only by its own modalities + * therefore admits image generators into a chat catalog. + * + * An id this host serves as a media model is not a text-only chat model, whatever + * its chat record claims. Populated from the whole response before any record is + * judged, because the answer is not in the record itself. + */ +const mediaOutputIDs = new Set(); + +function indexMediaOutputs(models: readonly AimlapiModel[]): void { + mediaOutputIDs.clear(); + for (const model of models) { + const declared = model.modalities?.output ?? []; + // `normalizeModalities` treats an empty list as text, so an undeclared + // record must not be read as evidence of anything. + if (declared.length === 0) continue; + if (normalizeModalities(declared).some((modality) => modality !== "text")) { + mediaOutputIDs.add(model.id); + } + } +} + +function isChatTextModel(model: AimlapiModel): boolean { + if (model.type !== CHAT_COMPLETIONS_TYPE) return false; + // Cross-surface check first: the chat record of a media model does not admit + // to being one. + if (mediaOutputIDs.has(model.id)) return false; + const output = normalizeModalities(model.modalities?.output); + // A chat model whose output is not purely text is a media model riding the + // chat protocol, and does not belong in a chat catalog. + return output.length === 1 && output[0] === "text"; +} + +/** + * Lab entry this id is a host for. AI/ML API is an aggregator and authors none + * of these models, so every entry has to point at the lab file rather than + * restate it. + */ +function baseModelFor(id: string): string | undefined { + return resolveModelMetadataBaseModel(id); +} + +function baseReasoning(baseModelID: string): boolean { + try { + return modelMetadata(baseModelID).reasoning === true; + } catch { + return false; + } +} + +/** + * Prices are quoted as `price` per `per` tokens; models.dev stores dollars per + * million. The unit discriminator is `origin`, not `measure`: provided is + * input, generated is output, cached is a cache read. Only text token charges + * are taken — a model's image or audio units are a different surface. + */ +function perMillion(units: readonly z.infer[], origin: string): number | undefined { + const unit = units.find( + (candidate) => candidate.name === "token" && candidate.content === "text" && candidate.origin === origin, + ); + if (!unit || unit.price == null || !unit.per) return undefined; + return (unit.price / unit.per) * 1_000_000; +} + +function positive(value: number | null | undefined): number | undefined { + return value != null && value > 0 ? value : undefined; +} + +/** + * Reads the documented `reasoning_effort` enum for one model. Returns undefined + * when the docs do not describe the control, which is treated as "cannot state + * it" rather than "the model has none". + */ +async function fetchReasoningEffort(id: string): Promise { + const url = `${DOCS_ENDPOINT}?model=${encodeURIComponent(id)}&endpoint=${encodeURIComponent(CHAT_COMPLETIONS_TYPE)}`; + let payload: unknown; + try { + const response = await fetch(url); + if (!response.ok) return undefined; + payload = await response.json(); + } catch { + return undefined; + } + + const found = findReasoningEffortEnum(payload); + if (found === undefined) return undefined; + + const values = found.filter((value) => EFFORT_VALUES.has(value)); + return values.length > 0 ? values : undefined; +} + +function findReasoningEffortEnum(node: unknown): string[] | undefined { + if (Array.isArray(node)) { + for (const item of node) { + const found = findReasoningEffortEnum(item); + if (found !== undefined) return found; + } + return undefined; + } + if (node === null || typeof node !== "object") return undefined; + + const record = node as Record; + const effort = record["reasoning_effort"]; + if (effort !== null && typeof effort === "object") { + const values = (effort as Record)["enum"]; + if (Array.isArray(values) && values.every((value) => typeof value === "string")) { + return values as string[]; + } + } + + for (const value of Object.values(record)) { + const found = findReasoningEffortEnum(value); + if (found !== undefined) return found; + } + return undefined; +} + +async function attachReasoningEffort(models: AimlapiModel[]): Promise { + // Only models whose lab entry says they reason need the control documented, + // and only those are worth a request. + const pending = models.filter((model) => { + if (!isChatTextModel(model)) return false; + const base = baseModelFor(model.id); + return base !== undefined && baseReasoning(base); + }); + + let cursor = 0; + const workers = Array.from({ length: Math.min(DOCS_CONCURRENCY, pending.length) }, async () => { + while (cursor < pending.length) { + const model = pending[cursor++]; + if (model === undefined) return; + model.reasoningEffort = await fetchReasoningEffort(model.id); + } + }); + await Promise.all(workers); +} + +export const aimlapi = { + id: "aimlapi", + name: "AI/ML API", + modelsDir: "providers/aimlapi/models", + // The catalog turns over quickly and lists far more than the chat surface, so + // a local model missing from one response is not proof that it is gone. + deleteMissing: false, + sourceID(model) { + return isChatTextModel(model) ? model.id : undefined; + }, + skippedNotice(ids) { + if (ids.length === 0) return []; + return [ + `${ids.length} AI/ML API chat models were skipped because this repository has no lab entry to point \`base_model\` at, or because the API does not document the reasoning control a reasoning model requires.`, + `Skipped remote IDs: ${ids.map((id) => `\`${id}\``).join(", ")}`, + ]; + }, + missingNotice(paths) { + if (paths.length === 0) return []; + return [ + `${paths.length} local AI/ML API models were absent from the catalog and were retained for manual lifecycle review.`, + `Retained local paths: ${paths.map((item) => `\`${item}\``).join(", ")}`, + ]; + }, + async fetchModels() { + const response = await fetch(API_ENDPOINT); + if (!response.ok) { + throw new Error(`AI/ML API request failed: ${response.status} ${response.statusText}`); + } + const raw = await response.json(); + const parsed = AimlapiResponse.parse(raw); + indexMediaOutputs(parsed.data); + await attachReasoningEffort(parsed.data); + return parsed; + }, + parseModels(raw) { + const models = AimlapiResponse.parse(raw).data; + // Replays parse a cached payload without going through fetchModels. + indexMediaOutputs(models); + return models; + }, + translateModel(model, context) { + if (!isChatTextModel(model)) return undefined; + + const existing = context.existing(model.id); + + // AI/ML API hosts other people's models, so the entry must reference the + // lab file instead of duplicating it. Without a lab entry to point at there + // is nothing correct to write: inlining the metadata is what this schema + // forbids, and authoring the lab file would mean sourcing capability data + // the catalog does not publish. + const base = existing?.base_model ?? baseModelFor(model.id); + if (base === undefined) return undefined; + + // Required whenever the base model reasons. Only the API's own request + // schema can say which values it takes, so a model whose docs stay silent + // is skipped rather than given an invented control. + let reasoningOptions: Array<{ type: "effort"; values: string[] }> | undefined; + if (baseReasoning(base)) { + const values = model.reasoningEffort ?? undefined; + if (values === undefined || values.length === 0) return undefined; + reasoningOptions = [{ type: "effort", values }]; + } + + const units = model.pricing?.units ?? []; + const info = model.info ?? {}; + const contextLimit = positive(info.contextLength); + const outputLimit = positive(info.outputMax); + // Only what the catalog actually publishes. It reports a context window and + // an output cap but no input cap, and equating the input cap with the whole + // context would overwrite the lab's correct split (e.g. 272k in + 128k out + // within a 400k window) with a wrong number. + const limit = + contextLimit === undefined && outputLimit === undefined + ? undefined + : { context: contextLimit, output: outputLimit }; + + // Everything else — the capability flags, description, dates, modalities — + // is the lab's to state and is inherited. factorBaseModel drops whatever + // matches the base, so the file carries only what is genuinely ours. + return { + id: model.id, + model: factorBaseModel( + base, + { + cost: { + input: perMillion(units, "provided") ?? existing?.cost?.input, + output: perMillion(units, "generated") ?? existing?.cost?.output, + cache_read: perMillion(units, "cached") ?? existing?.cost?.cache_read, + }, + reasoning_options: reasoningOptions, + limit, + }, + limit, + existing?.base_model === base ? existing?.base_model_omit : undefined, + ), + }; + }, +} satisfies SyncProvider; diff --git a/providers/aimlapi/logo.svg b/providers/aimlapi/logo.svg new file mode 100755 index 00000000000..5bd69eb5625 --- /dev/null +++ b/providers/aimlapi/logo.svg @@ -0,0 +1,3 @@ + + + diff --git a/providers/aimlapi/models/alibaba/qwen-max.toml b/providers/aimlapi/models/alibaba/qwen-max.toml new file mode 100644 index 00000000000..b67b2dfda47 --- /dev/null +++ b/providers/aimlapi/models/alibaba/qwen-max.toml @@ -0,0 +1,9 @@ +base_model = "alibaba/qwen-max" + +[cost] +input = 2.08 +output = 8.32 +cache_read = 0.416 + +[limit] +context = 32_000 diff --git a/providers/aimlapi/models/alibaba/qwen3-coder-480b-a35b-instruct.toml b/providers/aimlapi/models/alibaba/qwen3-coder-480b-a35b-instruct.toml new file mode 100644 index 00000000000..c294f7401f9 --- /dev/null +++ b/providers/aimlapi/models/alibaba/qwen3-coder-480b-a35b-instruct.toml @@ -0,0 +1,8 @@ +base_model = "alibaba/qwen3-coder-480b-a35b-instruct" + +[cost] +input = 1.95 +output = 9.75 + +[limit] +context = 262_000 diff --git a/providers/aimlapi/models/alibaba/qwen3-max.toml b/providers/aimlapi/models/alibaba/qwen3-max.toml new file mode 100644 index 00000000000..2cc25e4c73e --- /dev/null +++ b/providers/aimlapi/models/alibaba/qwen3-max.toml @@ -0,0 +1,6 @@ +base_model = "alibaba/qwen3-max" + +[cost] +input = 1.56 +output = 7.8 +cache_read = 0.312 diff --git a/providers/aimlapi/models/alibaba/qwen3-next-80b-a3b-instruct.toml b/providers/aimlapi/models/alibaba/qwen3-next-80b-a3b-instruct.toml new file mode 100644 index 00000000000..b90216744f6 --- /dev/null +++ b/providers/aimlapi/models/alibaba/qwen3-next-80b-a3b-instruct.toml @@ -0,0 +1,9 @@ +base_model = "alibaba/qwen3-next-80b-a3b-instruct" + +[cost] +input = 0.195 +output = 1.56 + +[limit] +context = 129_024 +output = 16_384 diff --git a/providers/aimlapi/models/alibaba/qwen3.5-flash.toml b/providers/aimlapi/models/alibaba/qwen3.5-flash.toml new file mode 100644 index 00000000000..ce03c2805d0 --- /dev/null +++ b/providers/aimlapi/models/alibaba/qwen3.5-flash.toml @@ -0,0 +1,9 @@ +base_model = "alibaba/qwen3.5-flash" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.13 +output = 0.52 diff --git a/providers/aimlapi/models/alibaba/qwen3.6-27b.toml b/providers/aimlapi/models/alibaba/qwen3.6-27b.toml new file mode 100644 index 00000000000..99848065e45 --- /dev/null +++ b/providers/aimlapi/models/alibaba/qwen3.6-27b.toml @@ -0,0 +1,13 @@ +base_model = "alibaba/qwen3.6-27b" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.78 +output = 4.68 + +[limit] +context = 256_000 +output = 252_000 diff --git a/providers/aimlapi/models/alibaba/qwen3.6-35b-a3b.toml b/providers/aimlapi/models/alibaba/qwen3.6-35b-a3b.toml new file mode 100644 index 00000000000..71fb076430e --- /dev/null +++ b/providers/aimlapi/models/alibaba/qwen3.6-35b-a3b.toml @@ -0,0 +1,13 @@ +base_model = "alibaba/qwen3.6-35b-a3b" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.4875 +output = 2.925 + +[limit] +context = 256_000 +output = 252_000 diff --git a/providers/aimlapi/models/alibaba/qwen3.6-max-preview.toml b/providers/aimlapi/models/alibaba/qwen3.6-max-preview.toml new file mode 100644 index 00000000000..e0067ed011f --- /dev/null +++ b/providers/aimlapi/models/alibaba/qwen3.6-max-preview.toml @@ -0,0 +1,9 @@ +base_model = "alibaba/qwen3.6-max-preview" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.65 +output = 3.9 diff --git a/providers/aimlapi/models/alibaba/qwen3.7-max.toml b/providers/aimlapi/models/alibaba/qwen3.7-max.toml new file mode 100644 index 00000000000..ad69c73c11c --- /dev/null +++ b/providers/aimlapi/models/alibaba/qwen3.7-max.toml @@ -0,0 +1,10 @@ +base_model = "alibaba/qwen3.7-max" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 2.6 +output = 7.8 +cache_read = 2.6 diff --git a/providers/aimlapi/models/alibaba/qwen3.8-2.4t-a95b.toml b/providers/aimlapi/models/alibaba/qwen3.8-2.4t-a95b.toml new file mode 100644 index 00000000000..b7c4dffe97a --- /dev/null +++ b/providers/aimlapi/models/alibaba/qwen3.8-2.4t-a95b.toml @@ -0,0 +1,13 @@ +base_model = "alibaba/qwen3.8-2.4t-a95b" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 3.4385 +output = 8.59625 +cache_read = 0.6877 + +[limit] +output = 52_429 diff --git a/providers/aimlapi/models/alibaba/qwen3.8-27b.toml b/providers/aimlapi/models/alibaba/qwen3.8-27b.toml new file mode 100644 index 00000000000..77fdf0eda88 --- /dev/null +++ b/providers/aimlapi/models/alibaba/qwen3.8-27b.toml @@ -0,0 +1,12 @@ +base_model = "alibaba/qwen3.8-27b" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.61893 +output = 4.40128 + +[limit] +output = 131_072 diff --git a/providers/aimlapi/models/alibaba/qwen3.8-flash.toml b/providers/aimlapi/models/alibaba/qwen3.8-flash.toml new file mode 100644 index 00000000000..811f1426cff --- /dev/null +++ b/providers/aimlapi/models/alibaba/qwen3.8-flash.toml @@ -0,0 +1,10 @@ +base_model = "alibaba/qwen3.8-flash" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.208 +output = 0.611 +cache_read = 0.0208 diff --git a/providers/aimlapi/models/alibaba/qwen3.8-max.toml b/providers/aimlapi/models/alibaba/qwen3.8-max.toml new file mode 100644 index 00000000000..654d7093d5e --- /dev/null +++ b/providers/aimlapi/models/alibaba/qwen3.8-max.toml @@ -0,0 +1,10 @@ +base_model = "alibaba/qwen3.8-max" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 2.6 +output = 7.8 +cache_read = 0.325 diff --git a/providers/aimlapi/models/anthropic/claude-haiku-4.5.toml b/providers/aimlapi/models/anthropic/claude-haiku-4.5.toml new file mode 100644 index 00000000000..626bc3d762f --- /dev/null +++ b/providers/aimlapi/models/anthropic/claude-haiku-4.5.toml @@ -0,0 +1,10 @@ +base_model = "anthropic/claude-haiku-4-5" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 1.3754 +output = 6.877 +cache_read = 0.13754 diff --git a/providers/aimlapi/models/anthropic/claude-opus-4.1.toml b/providers/aimlapi/models/anthropic/claude-opus-4.1.toml new file mode 100644 index 00000000000..c86491a03be --- /dev/null +++ b/providers/aimlapi/models/anthropic/claude-opus-4.1.toml @@ -0,0 +1,10 @@ +base_model = "anthropic/claude-opus-4-1" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 20.631 +output = 103.155 +cache_read = 2.0631 diff --git a/providers/aimlapi/models/anthropic/claude-opus-4.5.toml b/providers/aimlapi/models/anthropic/claude-opus-4.5.toml new file mode 100644 index 00000000000..1d5bfafae16 --- /dev/null +++ b/providers/aimlapi/models/anthropic/claude-opus-4.5.toml @@ -0,0 +1,10 @@ +base_model = "anthropic/claude-opus-4-5" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 6.877 +output = 34.385 +cache_read = 0.6877 diff --git a/providers/aimlapi/models/anthropic/claude-opus-4.7-fast.toml b/providers/aimlapi/models/anthropic/claude-opus-4.7-fast.toml new file mode 100644 index 00000000000..ebcaa448558 --- /dev/null +++ b/providers/aimlapi/models/anthropic/claude-opus-4.7-fast.toml @@ -0,0 +1,10 @@ +base_model = "anthropic/claude-opus-4-7" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 41.262 +output = 206.31 +cache_read = 4.1262 diff --git a/providers/aimlapi/models/anthropic/claude-opus-4.7.toml b/providers/aimlapi/models/anthropic/claude-opus-4.7.toml new file mode 100644 index 00000000000..74ee9952772 --- /dev/null +++ b/providers/aimlapi/models/anthropic/claude-opus-4.7.toml @@ -0,0 +1,10 @@ +base_model = "anthropic/claude-opus-4-7" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 6.877 +output = 34.385 +cache_read = 0.6877 diff --git a/providers/aimlapi/models/anthropic/claude-opus-4.8-fast.toml b/providers/aimlapi/models/anthropic/claude-opus-4.8-fast.toml new file mode 100644 index 00000000000..eca8426cea0 --- /dev/null +++ b/providers/aimlapi/models/anthropic/claude-opus-4.8-fast.toml @@ -0,0 +1,10 @@ +base_model = "anthropic/claude-opus-4-8" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 13.754 +output = 68.77 +cache_read = 1.3754 diff --git a/providers/aimlapi/models/anthropic/claude-opus-4.8.toml b/providers/aimlapi/models/anthropic/claude-opus-4.8.toml new file mode 100644 index 00000000000..f57da60fd4f --- /dev/null +++ b/providers/aimlapi/models/anthropic/claude-opus-4.8.toml @@ -0,0 +1,10 @@ +base_model = "anthropic/claude-opus-4-8" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 6.877 +output = 34.385 +cache_read = 0.6877 diff --git a/providers/aimlapi/models/anthropic/claude-sonnet-4.5.toml b/providers/aimlapi/models/anthropic/claude-sonnet-4.5.toml new file mode 100644 index 00000000000..abdf9b07883 --- /dev/null +++ b/providers/aimlapi/models/anthropic/claude-sonnet-4.5.toml @@ -0,0 +1,10 @@ +base_model = "anthropic/claude-sonnet-4-5" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 4.1262 +output = 20.631 +cache_read = 0.41262 diff --git a/providers/aimlapi/models/anthropic/claude-sonnet-4.6.toml b/providers/aimlapi/models/anthropic/claude-sonnet-4.6.toml new file mode 100644 index 00000000000..a46dbba1d12 --- /dev/null +++ b/providers/aimlapi/models/anthropic/claude-sonnet-4.6.toml @@ -0,0 +1,13 @@ +base_model = "anthropic/claude-sonnet-4-6" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 4.1262 +output = 20.631 +cache_read = 0.41262 + +[limit] +context = 200_000 diff --git a/providers/aimlapi/models/arcee-ai/trinity-large-thinking.toml b/providers/aimlapi/models/arcee-ai/trinity-large-thinking.toml new file mode 100644 index 00000000000..33031f2fb01 --- /dev/null +++ b/providers/aimlapi/models/arcee-ai/trinity-large-thinking.toml @@ -0,0 +1,14 @@ +base_model = "arcee-ai/trinity-large-thinking" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 0.302588 +output = 1.16909 +cache_read = 0.082524 + +[limit] +context = 262_144 +output = 80_000 diff --git a/providers/aimlapi/models/bytedance-seed/seed-2.0-code.toml b/providers/aimlapi/models/bytedance-seed/seed-2.0-code.toml new file mode 100644 index 00000000000..b22d70d2be7 --- /dev/null +++ b/providers/aimlapi/models/bytedance-seed/seed-2.0-code.toml @@ -0,0 +1,9 @@ +base_model = "bytedance-seed/seed-2.0-code" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.6877 +output = 4.1262 diff --git a/providers/aimlapi/models/bytedance-seed/seed-2.0-lite.toml b/providers/aimlapi/models/bytedance-seed/seed-2.0-lite.toml new file mode 100644 index 00000000000..06c0e91575d --- /dev/null +++ b/providers/aimlapi/models/bytedance-seed/seed-2.0-lite.toml @@ -0,0 +1,13 @@ +base_model = "bytedance-seed/seed-2.0-lite" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.34385 +output = 2.7508 + +[limit] +context = 262_144 +output = 131_072 diff --git a/providers/aimlapi/models/bytedance-seed/seed-2.0-mini.toml b/providers/aimlapi/models/bytedance-seed/seed-2.0-mini.toml new file mode 100644 index 00000000000..d2cf473b3d6 --- /dev/null +++ b/providers/aimlapi/models/bytedance-seed/seed-2.0-mini.toml @@ -0,0 +1,13 @@ +base_model = "bytedance-seed/seed-2.0-mini" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.13754 +output = 0.55016 + +[limit] +context = 262_144 +output = 131_072 diff --git a/providers/aimlapi/models/cohere/command-r-08-2024.toml b/providers/aimlapi/models/cohere/command-r-08-2024.toml new file mode 100644 index 00000000000..93418a9007b --- /dev/null +++ b/providers/aimlapi/models/cohere/command-r-08-2024.toml @@ -0,0 +1,5 @@ +base_model = "cohere/command-r-08-2024" + +[cost] +input = 0.20631 +output = 0.82524 diff --git a/providers/aimlapi/models/cohere/command-r-plus-08-2024.toml b/providers/aimlapi/models/cohere/command-r-plus-08-2024.toml new file mode 100644 index 00000000000..a7ed695ea2c --- /dev/null +++ b/providers/aimlapi/models/cohere/command-r-plus-08-2024.toml @@ -0,0 +1,5 @@ +base_model = "cohere/command-r-plus-08-2024" + +[cost] +input = 3.4385 +output = 13.754 diff --git a/providers/aimlapi/models/cohere/command-r7b-12-2024.toml b/providers/aimlapi/models/cohere/command-r7b-12-2024.toml new file mode 100644 index 00000000000..6a0ae5ffe27 --- /dev/null +++ b/providers/aimlapi/models/cohere/command-r7b-12-2024.toml @@ -0,0 +1,5 @@ +base_model = "cohere/command-r7b-12-2024" + +[cost] +input = 0.0515775 +output = 0.20631 diff --git a/providers/aimlapi/models/deepseek/deepseek-chat.toml b/providers/aimlapi/models/deepseek/deepseek-chat.toml new file mode 100644 index 00000000000..f47b52b0ab1 --- /dev/null +++ b/providers/aimlapi/models/deepseek/deepseek-chat.toml @@ -0,0 +1,10 @@ +base_model = "deepseek/deepseek-chat" + +[cost] +input = 0.364 +output = 0.546 +cache_read = 0.0364 + +[limit] +context = 128_000 +output = 124_000 diff --git a/providers/aimlapi/models/deepseek/deepseek-v4-flash-vision-exp.toml b/providers/aimlapi/models/deepseek/deepseek-v4-flash-vision-exp.toml new file mode 100644 index 00000000000..14c8b06da73 --- /dev/null +++ b/providers/aimlapi/models/deepseek/deepseek-v4-flash-vision-exp.toml @@ -0,0 +1,13 @@ +base_model = "deepseek/deepseek-v4-flash-vision-exp" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.572 +output = 1.716 +cache_read = 0.0182 + +[limit] +context = 1_048_576 diff --git a/providers/aimlapi/models/deepseek/deepseek-v4-flash.toml b/providers/aimlapi/models/deepseek/deepseek-v4-flash.toml new file mode 100644 index 00000000000..56437429724 --- /dev/null +++ b/providers/aimlapi/models/deepseek/deepseek-v4-flash.toml @@ -0,0 +1,10 @@ +base_model = "deepseek/deepseek-v4-flash" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.182 +output = 0.364 +cache_read = 0.00364 diff --git a/providers/aimlapi/models/deepseek/deepseek-v4-pro-0813.toml b/providers/aimlapi/models/deepseek/deepseek-v4-pro-0813.toml new file mode 100644 index 00000000000..c8947cb45c0 --- /dev/null +++ b/providers/aimlapi/models/deepseek/deepseek-v4-pro-0813.toml @@ -0,0 +1,13 @@ +base_model = "deepseek/deepseek-v4-pro-0813" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 2.393196 +output = 4.786392 +cache_read = 0.199433 + +[limit] +context = 1_048_576 diff --git a/providers/aimlapi/models/deepseek/deepseek-v4-pro.toml b/providers/aimlapi/models/deepseek/deepseek-v4-pro.toml new file mode 100644 index 00000000000..e733d802ed8 --- /dev/null +++ b/providers/aimlapi/models/deepseek/deepseek-v4-pro.toml @@ -0,0 +1,10 @@ +base_model = "deepseek/deepseek-v4-pro" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.5655 +output = 1.131 +cache_read = 0.0047125 diff --git a/providers/aimlapi/models/google/gemini-2.5-flash-lite.toml b/providers/aimlapi/models/google/gemini-2.5-flash-lite.toml new file mode 100644 index 00000000000..6675f8837ce --- /dev/null +++ b/providers/aimlapi/models/google/gemini-2.5-flash-lite.toml @@ -0,0 +1,13 @@ +base_model = "google/gemini-2.5-flash-lite" + +[[reasoning_options]] +type = "effort" +values = ["minimal", "low", "medium", "high", "max"] + +[cost] +input = 0.0975 +output = 0.39 +cache_read = 0.0975 + +[limit] +context = 1_000_000 diff --git a/providers/aimlapi/models/google/gemini-3.1-flash-lite-preview.toml b/providers/aimlapi/models/google/gemini-3.1-flash-lite-preview.toml new file mode 100644 index 00000000000..e4507cc7a27 --- /dev/null +++ b/providers/aimlapi/models/google/gemini-3.1-flash-lite-preview.toml @@ -0,0 +1,13 @@ +base_model = "google/gemini-3.1-flash-lite-preview" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.34385 +output = 2.0631 +cache_read = 0.034385 + +[limit] +context = 1_000_000 diff --git a/providers/aimlapi/models/google/gemini-3.1-pro-preview-customtools.toml b/providers/aimlapi/models/google/gemini-3.1-pro-preview-customtools.toml new file mode 100644 index 00000000000..090f8c1040b --- /dev/null +++ b/providers/aimlapi/models/google/gemini-3.1-pro-preview-customtools.toml @@ -0,0 +1,13 @@ +base_model = "google/gemini-3.1-pro-preview-customtools" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 2.7508 +output = 16.5048 +cache_read = 0.27508 + +[limit] +context = 1_048_756 diff --git a/providers/aimlapi/models/google/gemini-3.6-flash.toml b/providers/aimlapi/models/google/gemini-3.6-flash.toml new file mode 100644 index 00000000000..25ed6371a38 --- /dev/null +++ b/providers/aimlapi/models/google/gemini-3.6-flash.toml @@ -0,0 +1,10 @@ +base_model = "google/gemini-3.6-flash" + +[[reasoning_options]] +type = "effort" +values = ["minimal", "low", "medium", "high", "max"] + +[cost] +input = 1.95 +output = 9.75 +cache_read = 0.195 diff --git a/providers/aimlapi/models/google/gemini-3.7-flash.toml b/providers/aimlapi/models/google/gemini-3.7-flash.toml new file mode 100644 index 00000000000..282c1f3d4bc --- /dev/null +++ b/providers/aimlapi/models/google/gemini-3.7-flash.toml @@ -0,0 +1,10 @@ +base_model = "google/gemini-3.7-flash" + +[[reasoning_options]] +type = "effort" +values = ["minimal", "low", "medium", "high", "max"] + +[cost] +input = 0.975 +output = 4.875 +cache_read = 0.0975 diff --git a/providers/aimlapi/models/google/gemini-flash-latest.toml b/providers/aimlapi/models/google/gemini-flash-latest.toml new file mode 100644 index 00000000000..65342ef400e --- /dev/null +++ b/providers/aimlapi/models/google/gemini-flash-latest.toml @@ -0,0 +1,10 @@ +base_model = "google/gemini-flash-latest" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 2.0631 +output = 12.3786 +cache_read = 0.20631 diff --git a/providers/aimlapi/models/google/gemma-4-26b-a4b-it.toml b/providers/aimlapi/models/google/gemma-4-26b-a4b-it.toml new file mode 100644 index 00000000000..86370326cb4 --- /dev/null +++ b/providers/aimlapi/models/google/gemma-4-26b-a4b-it.toml @@ -0,0 +1,13 @@ +base_model = "google/gemma-4-26b-a4b-it" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.20631 +output = 0.82524 +cache_read = 0.20631 + +[limit] +output = 128_000 diff --git a/providers/aimlapi/models/google/gemma-4-31b-it.toml b/providers/aimlapi/models/google/gemma-4-31b-it.toml new file mode 100644 index 00000000000..ed5edce7b43 --- /dev/null +++ b/providers/aimlapi/models/google/gemma-4-31b-it.toml @@ -0,0 +1,14 @@ +base_model = "google/gemma-4-31b-it" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 1.361646 +output = 2.049346 +cache_read = 1.361646 + +[limit] +context = 256_000 +output = 16_384 diff --git a/providers/aimlapi/models/meta/muse-glimmer-30b.toml b/providers/aimlapi/models/meta/muse-glimmer-30b.toml new file mode 100644 index 00000000000..adfbd696b94 --- /dev/null +++ b/providers/aimlapi/models/meta/muse-glimmer-30b.toml @@ -0,0 +1,10 @@ +base_model = "meta/muse-glimmer-30b" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.48139 +output = 2.0631 +cache_read = 0.055016 diff --git a/providers/aimlapi/models/meta/muse-spark-1.1.toml b/providers/aimlapi/models/meta/muse-spark-1.1.toml new file mode 100644 index 00000000000..1cf23afdac9 --- /dev/null +++ b/providers/aimlapi/models/meta/muse-spark-1.1.toml @@ -0,0 +1,13 @@ +base_model = "meta/muse-spark-1.1" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 1.71925 +output = 5.84545 +cache_read = 0.20631 + +[limit] +context = 1_048_576 diff --git a/providers/aimlapi/models/meta/muse-spark-1.2.toml b/providers/aimlapi/models/meta/muse-spark-1.2.toml new file mode 100644 index 00000000000..089d86b4862 --- /dev/null +++ b/providers/aimlapi/models/meta/muse-spark-1.2.toml @@ -0,0 +1,10 @@ +base_model = "meta/muse-spark-1.2" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 1.71925 +output = 5.84545 +cache_read = 0.20631 diff --git a/providers/aimlapi/models/mistralai/devstral-2512.toml b/providers/aimlapi/models/mistralai/devstral-2512.toml new file mode 100644 index 00000000000..1d2bca286c3 --- /dev/null +++ b/providers/aimlapi/models/mistralai/devstral-2512.toml @@ -0,0 +1,6 @@ +base_model = "mistral/devstral-2512" + +[cost] +input = 0.605176 +output = 3.02588 +cache_read = 0.06051759999999999 diff --git a/providers/aimlapi/models/mistralai/mistral-large-2512.toml b/providers/aimlapi/models/mistralai/mistral-large-2512.toml new file mode 100644 index 00000000000..df98e427764 --- /dev/null +++ b/providers/aimlapi/models/mistralai/mistral-large-2512.toml @@ -0,0 +1,6 @@ +base_model = "mistral/mistral-large-2512" + +[cost] +input = 0.6877 +output = 2.0631 +cache_read = 0.06877 diff --git a/providers/aimlapi/models/mistralai/mistral-nemo.toml b/providers/aimlapi/models/mistralai/mistral-nemo.toml new file mode 100644 index 00000000000..e635d20050c --- /dev/null +++ b/providers/aimlapi/models/mistralai/mistral-nemo.toml @@ -0,0 +1,9 @@ +base_model = "mistral/mistral-nemo" + +[cost] +input = 0.20631 +output = 0.233818 +cache_read = 0.20631 + +[limit] +output = 16_384 diff --git a/providers/aimlapi/models/mistralai/mistral-small-2603.toml b/providers/aimlapi/models/mistralai/mistral-small-2603.toml new file mode 100644 index 00000000000..fdba8062af4 --- /dev/null +++ b/providers/aimlapi/models/mistralai/mistral-small-2603.toml @@ -0,0 +1,13 @@ +base_model = "mistral/mistral-small-2603" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.2578875 +output = 1.03155 +cache_read = 0.020631 + +[limit] +context = 262_144 diff --git a/providers/aimlapi/models/moonshotai/kimi-k2-thinking.toml b/providers/aimlapi/models/moonshotai/kimi-k2-thinking.toml new file mode 100644 index 00000000000..30683df0f19 --- /dev/null +++ b/providers/aimlapi/models/moonshotai/kimi-k2-thinking.toml @@ -0,0 +1,13 @@ +base_model = "moonshotai/kimi-k2-thinking" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 0.82524 +output = 3.4385 +cache_read = 0.20631 + +[limit] +output = 98_304 diff --git a/providers/aimlapi/models/openai/gpt-3.5-turbo.toml b/providers/aimlapi/models/openai/gpt-3.5-turbo.toml new file mode 100644 index 00000000000..aceb5cf5383 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-3.5-turbo.toml @@ -0,0 +1,8 @@ +base_model = "openai/gpt-3.5-turbo" + +[cost] +input = 0.65 +output = 1.95 + +[limit] +context = 16_000 diff --git a/providers/aimlapi/models/openai/gpt-4-turbo.toml b/providers/aimlapi/models/openai/gpt-4-turbo.toml new file mode 100644 index 00000000000..d90a9e47eb8 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-4-turbo.toml @@ -0,0 +1,5 @@ +base_model = "openai/gpt-4-turbo" + +[cost] +input = 13 +output = 39 diff --git a/providers/aimlapi/models/openai/gpt-4.1-mini.toml b/providers/aimlapi/models/openai/gpt-4.1-mini.toml new file mode 100644 index 00000000000..aabb6d5ed5b --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-4.1-mini.toml @@ -0,0 +1,9 @@ +base_model = "openai/gpt-4.1-mini" + +[cost] +input = 0.52 +output = 2.08 +cache_read = 0.13 + +[limit] +context = 1_000_000 diff --git a/providers/aimlapi/models/openai/gpt-4.1-nano.toml b/providers/aimlapi/models/openai/gpt-4.1-nano.toml new file mode 100644 index 00000000000..dbc624c33b7 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-4.1-nano.toml @@ -0,0 +1,9 @@ +base_model = "openai/gpt-4.1-nano" + +[cost] +input = 0.13 +output = 0.52 +cache_read = 0.0325 + +[limit] +context = 1_000_000 diff --git a/providers/aimlapi/models/openai/gpt-4.1.toml b/providers/aimlapi/models/openai/gpt-4.1.toml new file mode 100644 index 00000000000..e522294beb7 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-4.1.toml @@ -0,0 +1,6 @@ +base_model = "openai/gpt-4.1" + +[cost] +input = 2.6 +output = 10.4 +cache_read = 0.65 diff --git a/providers/aimlapi/models/openai/gpt-4.toml b/providers/aimlapi/models/openai/gpt-4.toml new file mode 100644 index 00000000000..2977fbeb28b --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-4.toml @@ -0,0 +1,9 @@ +base_model = "openai/gpt-4" + +[cost] +input = 39 +output = 78 +cache_read = 39 + +[limit] +context = 8_000 diff --git a/providers/aimlapi/models/openai/gpt-4o-2024-05-13.toml b/providers/aimlapi/models/openai/gpt-4o-2024-05-13.toml new file mode 100644 index 00000000000..fbfb5174ab3 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-4o-2024-05-13.toml @@ -0,0 +1,8 @@ +base_model = "openai/gpt-4o-2024-05-13" + +[cost] +input = 6.5 +output = 19.5 + +[limit] +output = 16_384 diff --git a/providers/aimlapi/models/openai/gpt-4o-2024-08-06.toml b/providers/aimlapi/models/openai/gpt-4o-2024-08-06.toml new file mode 100644 index 00000000000..37cdb080980 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-4o-2024-08-06.toml @@ -0,0 +1,6 @@ +base_model = "openai/gpt-4o-2024-08-06" + +[cost] +input = 3.25 +output = 13 +cache_read = 1.625 diff --git a/providers/aimlapi/models/openai/gpt-4o-2024-11-20.toml b/providers/aimlapi/models/openai/gpt-4o-2024-11-20.toml new file mode 100644 index 00000000000..909b9284067 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-4o-2024-11-20.toml @@ -0,0 +1,6 @@ +base_model = "openai/gpt-4o-2024-11-20" + +[cost] +input = 3.25 +output = 13 +cache_read = 1.625 diff --git a/providers/aimlapi/models/openai/gpt-4o-mini.toml b/providers/aimlapi/models/openai/gpt-4o-mini.toml new file mode 100644 index 00000000000..b987fdaeb95 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-4o-mini.toml @@ -0,0 +1,6 @@ +base_model = "openai/gpt-4o-mini" + +[cost] +input = 0.195 +output = 0.78 +cache_read = 0.0975 diff --git a/providers/aimlapi/models/openai/gpt-4o.toml b/providers/aimlapi/models/openai/gpt-4o.toml new file mode 100644 index 00000000000..88760223978 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-4o.toml @@ -0,0 +1,6 @@ +base_model = "openai/gpt-4o" + +[cost] +input = 3.25 +output = 13 +cache_read = 1.625 diff --git a/providers/aimlapi/models/openai/gpt-5-mini.toml b/providers/aimlapi/models/openai/gpt-5-mini.toml new file mode 100644 index 00000000000..112c96dff2a --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5-mini.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5-mini" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 0.378235 +output = 3.02588 +cache_read = 0.34385 diff --git a/providers/aimlapi/models/openai/gpt-5-nano.toml b/providers/aimlapi/models/openai/gpt-5-nano.toml new file mode 100644 index 00000000000..8a081097106 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5-nano.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5-nano" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 0.075647 +output = 0.605176 +cache_read = 0.06877 diff --git a/providers/aimlapi/models/openai/gpt-5-pro.toml b/providers/aimlapi/models/openai/gpt-5-pro.toml new file mode 100644 index 00000000000..dcf302b6018 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5-pro.toml @@ -0,0 +1,9 @@ +base_model = "openai/gpt-5-pro" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 20.631 +output = 165.048 diff --git a/providers/aimlapi/models/openai/gpt-5.1-codex-max.toml b/providers/aimlapi/models/openai/gpt-5.1-codex-max.toml new file mode 100644 index 00000000000..d6258f1209a --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.1-codex-max.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5.1-codex-max" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 3.4385 +output = 27.508 +cache_read = 0.34385 diff --git a/providers/aimlapi/models/openai/gpt-5.1-codex-mini.toml b/providers/aimlapi/models/openai/gpt-5.1-codex-mini.toml new file mode 100644 index 00000000000..fa3cd2062d2 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.1-codex-mini.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5.1-codex-mini" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.34385 +output = 2.7508 +cache_read = 0.041262 diff --git a/providers/aimlapi/models/openai/gpt-5.1-codex.toml b/providers/aimlapi/models/openai/gpt-5.1-codex.toml new file mode 100644 index 00000000000..6c5c7db6021 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.1-codex.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5.1-codex" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 3.4385 +output = 27.508 +cache_read = 0.34385 diff --git a/providers/aimlapi/models/openai/gpt-5.2-codex.toml b/providers/aimlapi/models/openai/gpt-5.2-codex.toml new file mode 100644 index 00000000000..c84a5f445e5 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.2-codex.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5.2-codex" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 4.8139 +output = 38.5112 +cache_read = 0.48139 diff --git a/providers/aimlapi/models/openai/gpt-5.2-pro.toml b/providers/aimlapi/models/openai/gpt-5.2-pro.toml new file mode 100644 index 00000000000..d3e1d34fc0f --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.2-pro.toml @@ -0,0 +1,9 @@ +base_model = "openai/gpt-5.2-pro" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 28.8834 +output = 231.0672 diff --git a/providers/aimlapi/models/openai/gpt-5.3-codex.toml b/providers/aimlapi/models/openai/gpt-5.3-codex.toml new file mode 100644 index 00000000000..f69e9a098bf --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.3-codex.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5.3-codex" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 4.8139 +output = 38.5112 +cache_read = 0.48139 diff --git a/providers/aimlapi/models/openai/gpt-5.4-mini.toml b/providers/aimlapi/models/openai/gpt-5.4-mini.toml new file mode 100644 index 00000000000..4bc5a1e2e7f --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.4-mini.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5.4-mini" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 2.0631 +output = 12.3786 +cache_read = 0.20631 diff --git a/providers/aimlapi/models/openai/gpt-5.4-nano.toml b/providers/aimlapi/models/openai/gpt-5.4-nano.toml new file mode 100644 index 00000000000..f746e7bfc86 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.4-nano.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5.4-nano" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.27508 +output = 1.71925 +cache_read = 0.027508 diff --git a/providers/aimlapi/models/openai/gpt-5.4-pro.toml b/providers/aimlapi/models/openai/gpt-5.4-pro.toml new file mode 100644 index 00000000000..07fcde9d4f9 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.4-pro.toml @@ -0,0 +1,9 @@ +base_model = "openai/gpt-5.4-pro" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 41.262 +output = 247.572 diff --git a/providers/aimlapi/models/openai/gpt-5.5-pro.toml b/providers/aimlapi/models/openai/gpt-5.5-pro.toml new file mode 100644 index 00000000000..2002aaca7ae --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.5-pro.toml @@ -0,0 +1,9 @@ +base_model = "openai/gpt-5.5-pro" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 41.262 +output = 247.572 diff --git a/providers/aimlapi/models/openai/gpt-5.6-luna-pro.toml b/providers/aimlapi/models/openai/gpt-5.6-luna-pro.toml new file mode 100644 index 00000000000..3e68a281b4f --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.6-luna-pro.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5.6-luna" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.27508 +output = 1.65048 +cache_read = 0.027508 diff --git a/providers/aimlapi/models/openai/gpt-5.6-luna.toml b/providers/aimlapi/models/openai/gpt-5.6-luna.toml new file mode 100644 index 00000000000..8334dc563ca --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.6-luna.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5.6-luna" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.26 +output = 1.56 +cache_read = 0.026 diff --git a/providers/aimlapi/models/openai/gpt-5.6-sol-pro.toml b/providers/aimlapi/models/openai/gpt-5.6-sol-pro.toml new file mode 100644 index 00000000000..42778ea6f24 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.6-sol-pro.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5.6-sol" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 5.5016 +output = 27.508 +cache_read = 0.55016 diff --git a/providers/aimlapi/models/openai/gpt-5.6-sol.toml b/providers/aimlapi/models/openai/gpt-5.6-sol.toml new file mode 100644 index 00000000000..ebe354795f9 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.6-sol.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5.6-sol" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 5.2 +output = 26 +cache_read = 0.52 diff --git a/providers/aimlapi/models/openai/gpt-5.6-terra-pro.toml b/providers/aimlapi/models/openai/gpt-5.6-terra-pro.toml new file mode 100644 index 00000000000..e5c75dbe409 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.6-terra-pro.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5.6-terra" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 2.7508 +output = 16.5048 +cache_read = 0.27508 diff --git a/providers/aimlapi/models/openai/gpt-5.6-terra.toml b/providers/aimlapi/models/openai/gpt-5.6-terra.toml new file mode 100644 index 00000000000..f12c3f71693 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.6-terra.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5.6-terra" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 2.6 +output = 15.6 +cache_read = 0.26 diff --git a/providers/aimlapi/models/openai/gpt-5.toml b/providers/aimlapi/models/openai/gpt-5.toml new file mode 100644 index 00000000000..d202dbb58fc --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-5.toml @@ -0,0 +1,10 @@ +base_model = "openai/gpt-5" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 1.891175 +output = 15.1294 +cache_read = 1.71925 diff --git a/providers/aimlapi/models/openai/gpt-oss-120b.toml b/providers/aimlapi/models/openai/gpt-oss-120b.toml new file mode 100644 index 00000000000..312f08e3d34 --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-oss-120b.toml @@ -0,0 +1,14 @@ +base_model = "openai/gpt-oss-120b" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 0.48139 +output = 1.30663 +cache_read = 0.48139 + +[limit] +context = 131_000 +output = 117_964 diff --git a/providers/aimlapi/models/openai/gpt-oss-20b.toml b/providers/aimlapi/models/openai/gpt-oss-20b.toml new file mode 100644 index 00000000000..c1755a91dbd --- /dev/null +++ b/providers/aimlapi/models/openai/gpt-oss-20b.toml @@ -0,0 +1,14 @@ +base_model = "openai/gpt-oss-20b" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 0.103155 +output = 0.41262 +cache_read = 0.0515775 + +[limit] +context = 131_000 +output = 117_964 diff --git a/providers/aimlapi/models/openai/o1-pro.toml b/providers/aimlapi/models/openai/o1-pro.toml new file mode 100644 index 00000000000..11ce7cea6a2 --- /dev/null +++ b/providers/aimlapi/models/openai/o1-pro.toml @@ -0,0 +1,9 @@ +base_model = "openai/o1-pro" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 206.31 +output = 825.24 diff --git a/providers/aimlapi/models/openai/o1.toml b/providers/aimlapi/models/openai/o1.toml new file mode 100644 index 00000000000..95071e55c77 --- /dev/null +++ b/providers/aimlapi/models/openai/o1.toml @@ -0,0 +1,13 @@ +base_model = "openai/o1" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high", "xhigh"] + +[cost] +input = 19.5 +output = 78 +cache_read = 9.75 + +[limit] +context = 128_000 diff --git a/providers/aimlapi/models/openai/o3-mini.toml b/providers/aimlapi/models/openai/o3-mini.toml new file mode 100644 index 00000000000..469be08998e --- /dev/null +++ b/providers/aimlapi/models/openai/o3-mini.toml @@ -0,0 +1,10 @@ +base_model = "openai/o3-mini" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high", "xhigh"] + +[cost] +input = 1.43 +output = 5.72 +cache_read = 0.715 diff --git a/providers/aimlapi/models/openai/o3-pro.toml b/providers/aimlapi/models/openai/o3-pro.toml new file mode 100644 index 00000000000..7a5a8a0bd15 --- /dev/null +++ b/providers/aimlapi/models/openai/o3-pro.toml @@ -0,0 +1,9 @@ +base_model = "openai/o3-pro" + +[[reasoning_options]] +type = "effort" +values = ["low", "medium", "high"] + +[cost] +input = 27.508 +output = 110.032 diff --git a/providers/aimlapi/models/perplexity/sonar-pro.toml b/providers/aimlapi/models/perplexity/sonar-pro.toml new file mode 100644 index 00000000000..d353019ac3a --- /dev/null +++ b/providers/aimlapi/models/perplexity/sonar-pro.toml @@ -0,0 +1,8 @@ +base_model = "perplexity/sonar-pro" + +[cost] +input = 3.9 +output = 19.5 + +[limit] +output = 100_000 diff --git a/providers/aimlapi/models/perplexity/sonar.toml b/providers/aimlapi/models/perplexity/sonar.toml new file mode 100644 index 00000000000..8b062038318 --- /dev/null +++ b/providers/aimlapi/models/perplexity/sonar.toml @@ -0,0 +1,8 @@ +base_model = "perplexity/sonar" + +[cost] +input = 1.3 +output = 1.3 + +[limit] +output = 100_000 diff --git a/providers/aimlapi/models/poolside/laguna-s-2.1.toml b/providers/aimlapi/models/poolside/laguna-s-2.1.toml new file mode 100644 index 00000000000..7bbd01df825 --- /dev/null +++ b/providers/aimlapi/models/poolside/laguna-s-2.1.toml @@ -0,0 +1,13 @@ +base_model = "poolside/laguna-s-2.1" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.123786 +output = 0.247572 +cache_read = 0.0082524 + +[limit] +output = 131_072 diff --git a/providers/aimlapi/models/poolside/laguna-xs-2.1.toml b/providers/aimlapi/models/poolside/laguna-xs-2.1.toml new file mode 100644 index 00000000000..011a014a3c3 --- /dev/null +++ b/providers/aimlapi/models/poolside/laguna-xs-2.1.toml @@ -0,0 +1,10 @@ +base_model = "poolside/laguna-xs-2.1" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.082524 +output = 0.165048 +cache_read = 0.041262 diff --git a/providers/aimlapi/models/sakana/fugu-ultra.toml b/providers/aimlapi/models/sakana/fugu-ultra.toml new file mode 100644 index 00000000000..f14cb9af343 --- /dev/null +++ b/providers/aimlapi/models/sakana/fugu-ultra.toml @@ -0,0 +1,13 @@ +base_model = "sakana/fugu-ultra" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 6.877 +output = 41.262 +cache_read = 0.6877 + +[limit] +output = 128_000 diff --git a/providers/aimlapi/models/sakana/sakana-namazu.toml b/providers/aimlapi/models/sakana/sakana-namazu.toml new file mode 100644 index 00000000000..0910a71e8c8 --- /dev/null +++ b/providers/aimlapi/models/sakana/sakana-namazu.toml @@ -0,0 +1,10 @@ +base_model = "sakana/sakana-namazu" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 1.30663 +output = 5.5016 +cache_read = 0.20631 diff --git a/providers/aimlapi/models/tencent/hy3.toml b/providers/aimlapi/models/tencent/hy3.toml new file mode 100644 index 00000000000..a8d79e8ba93 --- /dev/null +++ b/providers/aimlapi/models/tencent/hy3.toml @@ -0,0 +1,14 @@ +base_model = "tencent/hy3" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.27508 +output = 1.10032 +cache_read = 0.06877 + +[limit] +context = 262_144 +output = 131_072 diff --git a/providers/aimlapi/models/tencent/hy4-preview.toml b/providers/aimlapi/models/tencent/hy4-preview.toml new file mode 100644 index 00000000000..cc65e8c53b8 --- /dev/null +++ b/providers/aimlapi/models/tencent/hy4-preview.toml @@ -0,0 +1,13 @@ +base_model = "tencent/hy4-preview" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 1.1470836 +output = 3.4398754 +cache_read = 0.0577668 + +[limit] +context = 1_048_576 diff --git a/providers/aimlapi/models/thinkingmachines/inkling-small.toml b/providers/aimlapi/models/thinkingmachines/inkling-small.toml new file mode 100644 index 00000000000..8ee54fbd811 --- /dev/null +++ b/providers/aimlapi/models/thinkingmachines/inkling-small.toml @@ -0,0 +1,14 @@ +base_model = "thinkingmachines/inkling-small" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.797732 +output = 1.980576 +cache_read = 0.1595464 + +[limit] +context = 524_288 +output = 262_144 diff --git a/providers/aimlapi/models/thinkingmachines/inkling.toml b/providers/aimlapi/models/thinkingmachines/inkling.toml new file mode 100644 index 00000000000..b7eb76e80e5 --- /dev/null +++ b/providers/aimlapi/models/thinkingmachines/inkling.toml @@ -0,0 +1,10 @@ +base_model = "thinkingmachines/inkling" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 1.3754 +output = 5.57037 +cache_read = 0.233818 diff --git a/providers/aimlapi/models/upstage/solar-pro4.toml b/providers/aimlapi/models/upstage/solar-pro4.toml new file mode 100644 index 00000000000..ac67690de8d --- /dev/null +++ b/providers/aimlapi/models/upstage/solar-pro4.toml @@ -0,0 +1,10 @@ +base_model = "upstage/solar-pro4" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.041262 +output = 0.165048 +cache_read = 0.0082524 diff --git a/providers/aimlapi/models/xiaomi/mimo-v2.5-pro.toml b/providers/aimlapi/models/xiaomi/mimo-v2.5-pro.toml new file mode 100644 index 00000000000..649a50bdb63 --- /dev/null +++ b/providers/aimlapi/models/xiaomi/mimo-v2.5-pro.toml @@ -0,0 +1,14 @@ +base_model = "xiaomi/mimo-v2.5-pro" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.598299 +output = 1.196598 +cache_read = 0.00495144 + +[limit] +context = 1_000_000 +output = 128_000 diff --git a/providers/aimlapi/models/xiaomi/mimo-v2.5.toml b/providers/aimlapi/models/xiaomi/mimo-v2.5.toml new file mode 100644 index 00000000000..8ea2de6fccc --- /dev/null +++ b/providers/aimlapi/models/xiaomi/mimo-v2.5.toml @@ -0,0 +1,14 @@ +base_model = "xiaomi/mimo-v2.5" + +[[reasoning_options]] +type = "effort" +values = ["none", "low", "medium", "high"] + +[cost] +input = 0.192556 +output = 0.385112 +cache_read = 0.0038511200000000004 + +[limit] +context = 1_000_000 +output = 128_000 diff --git a/providers/aimlapi/models/z-ai/glm-4.5v.toml b/providers/aimlapi/models/z-ai/glm-4.5v.toml new file mode 100644 index 00000000000..65d6f914112 --- /dev/null +++ b/providers/aimlapi/models/z-ai/glm-4.5v.toml @@ -0,0 +1,13 @@ +base_model = "zhipuai/glm-4.5v" + +[[reasoning_options]] +type = "effort" +values = ["none", "minimal", "low", "medium", "high"] + +[cost] +input = 0.82524 +output = 2.47572 +cache_read = 0.151294 + +[limit] +context = 65_536 diff --git a/providers/aimlapi/models/z-ai/glm-4.6v.toml b/providers/aimlapi/models/z-ai/glm-4.6v.toml new file mode 100644 index 00000000000..953152d5a67 --- /dev/null +++ b/providers/aimlapi/models/z-ai/glm-4.6v.toml @@ -0,0 +1,13 @@ +base_model = "zhipuai/glm-4.6v" + +[[reasoning_options]] +type = "effort" +values = ["none", "minimal", "low", "medium", "high"] + +[cost] +input = 0.41262 +output = 1.23786 +cache_read = 0.075647 + +[limit] +context = 131_072 diff --git a/providers/aimlapi/models/z-ai/glm-4.7-flash.toml b/providers/aimlapi/models/z-ai/glm-4.7-flash.toml new file mode 100644 index 00000000000..82aaef79286 --- /dev/null +++ b/providers/aimlapi/models/z-ai/glm-4.7-flash.toml @@ -0,0 +1,14 @@ +base_model = "zhipuai/glm-4.7-flash" + +[[reasoning_options]] +type = "effort" +values = ["none", "minimal", "low", "medium", "high"] + +[cost] +input = 0.171925 +output = 0.6877 +cache_read = 0.013754 + +[limit] +context = 202_752 +output = 16_384 diff --git a/providers/aimlapi/models/z-ai/glm-5.3-flash.toml b/providers/aimlapi/models/z-ai/glm-5.3-flash.toml new file mode 100644 index 00000000000..35f84724a33 --- /dev/null +++ b/providers/aimlapi/models/z-ai/glm-5.3-flash.toml @@ -0,0 +1,13 @@ +base_model = "zhipuai/glm-5.3-flash" + +[[reasoning_options]] +type = "effort" +values = ["low", "high", "max"] + +[cost] +input = 0.0975 +output = 0.325 +cache_read = 0.0195 + +[limit] +context = 1_048_576 diff --git a/providers/aimlapi/provider.toml b/providers/aimlapi/provider.toml new file mode 100755 index 00000000000..6b7a3f559b9 --- /dev/null +++ b/providers/aimlapi/provider.toml @@ -0,0 +1,5 @@ +name = "AI/ML API" +env = ["AIMLAPI_API_KEY"] +npm = "@ai-sdk/openai-compatible" +api = "https://api.aimlapi.com/v1" +doc = "https://docs.aimlapi.com"