diff --git a/providers/y-api/logo.svg b/providers/y-api/logo.svg new file mode 100644 index 00000000000..eb20de0dd41 --- /dev/null +++ b/providers/y-api/logo.svg @@ -0,0 +1,3 @@ + + + diff --git a/providers/y-api/models/deepseek/deepseek-v4-flash-0731.toml b/providers/y-api/models/deepseek/deepseek-v4-flash-0731.toml new file mode 100644 index 00000000000..e41780e097c --- /dev/null +++ b/providers/y-api/models/deepseek/deepseek-v4-flash-0731.toml @@ -0,0 +1,14 @@ +# Toggle: thinking.type = enabled|disabled +# Effort: reasoning_effort = low|high|max +base_model = "deepseek/deepseek-v4-flash-0731" +reasoning_options = [ + { type = "toggle" }, + { type = "effort", values = ["low", "high", "max"] }, +] + +[interleaved] +field = "reasoning_content" + +[cost] +input = 0.0075 +output = 0.015 diff --git a/providers/y-api/models/deepseek/deepseek-v4-flash.toml b/providers/y-api/models/deepseek/deepseek-v4-flash.toml new file mode 100644 index 00000000000..3b8d4979c3a --- /dev/null +++ b/providers/y-api/models/deepseek/deepseek-v4-flash.toml @@ -0,0 +1,15 @@ +# Toggle: thinking.type = enabled|disabled +# Effort: reasoning_effort = low|high|max +# Cost: free tier — no credit is deducted (https://y-api.bestvirtualgoods.com/pricing). +base_model = "deepseek/deepseek-v4-flash" +reasoning_options = [ + { type = "toggle" }, + { type = "effort", values = ["low", "high", "max"] }, +] + +[interleaved] +field = "reasoning_content" + +[cost] +input = 0 +output = 0 diff --git a/providers/y-api/models/deepseek/deepseek-v4-pro.toml b/providers/y-api/models/deepseek/deepseek-v4-pro.toml new file mode 100644 index 00000000000..19225fd5962 --- /dev/null +++ b/providers/y-api/models/deepseek/deepseek-v4-pro.toml @@ -0,0 +1,22 @@ +# Toggle: thinking.type = enabled|disabled +# Effort: reasoning_effort = high|max +# +# Interleaved field: this host does NOT emit reasoning_content for this model +# (0 of 14 samples, 2026-09-16). It emits reasoning (string) plus +# reasoning_details (list of one {type: "reasoning.text"}) on all 14 samples, +# which is why the field below is reasoning_details and not the lab's +# reasoning_content. The first-party DeepSeek V4 Pro entry uses +# reasoning_content; this host's response shape differs, so the override +# describes the host. +base_model = "deepseek/deepseek-v4-pro" +reasoning_options = [ + { type = "toggle" }, + { type = "effort", values = ["high", "max"] }, +] + +[interleaved] +field = "reasoning_details" + +[cost] +input = 0.025 +output = 0.05 diff --git a/providers/y-api/models/deepseek/deepseek-v4.1-flash.toml b/providers/y-api/models/deepseek/deepseek-v4.1-flash.toml new file mode 100644 index 00000000000..f12414f15cf --- /dev/null +++ b/providers/y-api/models/deepseek/deepseek-v4.1-flash.toml @@ -0,0 +1,33 @@ +# Toggle: thinking.type = enabled|disabled +# Effort: reasoning_effort = low|high|max +# +# This host ACCEPTS medium and xhigh (no 400) but does not act on them +# distinctly, so they are not authored. Measured on this host, 2026-09-16: +# +# this model, usage.completion_tokens_details.reasoning_tokens, n=3/level +# low 84/116/78 medium 108/108/104 high 109/139/104 +# xhigh 131/87/132 max 140/134/128 +# Adjacent levels overlap: medium's whole range (104-108) sits inside +# high's (104-139), and xhigh's (87-132) is wider than the gap to either +# neighbour. Nothing here separates medium from high, or xhigh from high. +# +# control, sibling deepseek-v4-flash-0731 (same family, same host), +# reasoning_content length, n=5/level, means +# low 826 / medium 442 / high 453 / xhigh 648 / max 1801 +# which is not monotonic at all (max ranged 414-6790). +# +# An effort level a caller cannot observe is worse than not offering it, so +# this file authors the lab baseline set, matching the other Y-API DeepSeek +# Flash entries. +base_model = "deepseek/deepseek-v4.1-flash" +reasoning_options = [ + { type = "toggle" }, + { type = "effort", values = ["low", "high", "max"] }, +] + +[interleaved] +field = "reasoning_content" + +[cost] +input = 0.01 +output = 0.05 diff --git a/providers/y-api/models/moonshotai/kimi-k3.toml b/providers/y-api/models/moonshotai/kimi-k3.toml new file mode 100644 index 00000000000..8d3464dee06 --- /dev/null +++ b/providers/y-api/models/moonshotai/kimi-k3.toml @@ -0,0 +1,15 @@ +# Toggle: thinking.type = enabled|disabled +# Effort: reasoning_effort = low|high|max +# Reasoning text arrives as reasoning_details, not reasoning_content (live API, 2026-09-16). +base_model = "moonshotai/kimi-k3" +reasoning_options = [ + { type = "toggle" }, + { type = "effort", values = ["low", "high", "max"] }, +] + +[interleaved] +field = "reasoning_details" + +[cost] +input = 0.15 +output = 0.75 diff --git a/providers/y-api/models/openai/gpt-5.6-luna.toml b/providers/y-api/models/openai/gpt-5.6-luna.toml new file mode 100644 index 00000000000..c900de051a0 --- /dev/null +++ b/providers/y-api/models/openai/gpt-5.6-luna.toml @@ -0,0 +1,8 @@ +# Effort: reasoning_effort = none|low|medium|high|xhigh +# The live API rejects `max` for this model; no reasoning text is exposed. +base_model = "openai/gpt-5.6-luna" +reasoning_options = [{ type = "effort", values = ["none", "low", "medium", "high", "xhigh"] }] + +[cost] +input = 0.015 +output = 0.065 diff --git a/providers/y-api/models/openai/gpt-5.6-sol.toml b/providers/y-api/models/openai/gpt-5.6-sol.toml new file mode 100644 index 00000000000..12bf390e930 --- /dev/null +++ b/providers/y-api/models/openai/gpt-5.6-sol.toml @@ -0,0 +1,8 @@ +# Effort: reasoning_effort = none|low|medium|high|xhigh +# The live API rejects `max` for this model; no reasoning text is exposed. +base_model = "openai/gpt-5.6-sol" +reasoning_options = [{ type = "effort", values = ["none", "low", "medium", "high", "xhigh"] }] + +[cost] +input = 0.25 +output = 1.5 diff --git a/providers/y-api/models/openai/gpt-5.6-terra.toml b/providers/y-api/models/openai/gpt-5.6-terra.toml new file mode 100644 index 00000000000..d36c4bb3bf2 --- /dev/null +++ b/providers/y-api/models/openai/gpt-5.6-terra.toml @@ -0,0 +1,8 @@ +# Effort: reasoning_effort = none|low|medium|high|xhigh +# The live API rejects `max` for this model; no reasoning text is exposed. +base_model = "openai/gpt-5.6-terra" +reasoning_options = [{ type = "effort", values = ["none", "low", "medium", "high", "xhigh"] }] + +[cost] +input = 0.1 +output = 0.6 diff --git a/providers/y-api/models/openai/gpt-6-astra.toml b/providers/y-api/models/openai/gpt-6-astra.toml new file mode 100644 index 00000000000..5d07e2c7464 --- /dev/null +++ b/providers/y-api/models/openai/gpt-6-astra.toml @@ -0,0 +1,9 @@ +# Effort: reasoning_effort = low|medium|high|xhigh — no `none` and no `max`, per the +# live API error text; no reasoning text is exposed. +# This model also rejects `max_tokens` and requires `max_completion_tokens`. +base_model = "openai/gpt-6-astra" +reasoning_options = [{ type = "effort", values = ["low", "medium", "high", "xhigh"] }] + +[cost] +input = 0.5 +output = 2.5 diff --git a/providers/y-api/models/qwen/qwen3.8-flash.toml b/providers/y-api/models/qwen/qwen3.8-flash.toml new file mode 100644 index 00000000000..e38103c3ea0 --- /dev/null +++ b/providers/y-api/models/qwen/qwen3.8-flash.toml @@ -0,0 +1,26 @@ +# Effort: reasoning_effort accepts low|medium|xhigh. An unlisted value returns the +# supported set verbatim, so this is read off the wire rather than from Alibaba's docs: +# "Unexpected reasoning effort minimal. Supported types are xhigh (default), +# medium, and low." +# `none` also answered 200 on this host (5/5), but it is not in that enumeration, so +# it is not authored here. +# +# No [interleaved]: this host returns the trace as a plain `reasoning` string +# (`message` keys are content/reasoning/role/tool_calls), which is not a +# schema-valid interleaved.field. Same reason the four OpenAI models omit it. +# +# [limit] is overridden. The Alibaba Cloud entry advertises a 1M context, but this +# host caps this model well below that: +# "The input (2000052 tokens) is longer than the model's context length (262144 tokens)." +# 262144 = 256K, so inheriting the base limit would overstate the window by ~4x. +# +# Cost: USD cash price (credit / 20), per the header in provider.toml. +base_model = "alibaba/qwen3.8-flash" +reasoning_options = [{ type = "effort", values = ["low", "medium", "xhigh"] }] + +[limit] +context = 262_144 + +[cost] +input = 0.01 +output = 0.025 diff --git a/providers/y-api/models/tencent/hy3.toml b/providers/y-api/models/tencent/hy3.toml new file mode 100644 index 00000000000..3069f5ecf0a --- /dev/null +++ b/providers/y-api/models/tencent/hy3.toml @@ -0,0 +1,11 @@ +# Effort: reasoning_effort = none|low|high +# Cost: free tier — no credit is deducted (https://y-api.bestvirtualgoods.com/pricing). +base_model = "tencent/hy3" +reasoning_options = [{ type = "effort", values = ["none", "low", "high"] }] + +[interleaved] +field = "reasoning_content" + +[cost] +input = 0 +output = 0 diff --git a/providers/y-api/models/xiaomi/mimo-v2.5.toml b/providers/y-api/models/xiaomi/mimo-v2.5.toml new file mode 100644 index 00000000000..b257ff0c8eb --- /dev/null +++ b/providers/y-api/models/xiaomi/mimo-v2.5.toml @@ -0,0 +1,11 @@ +# Toggle: thinking.type = enabled|disabled +# Cost: free tier — no credit is deducted (https://y-api.bestvirtualgoods.com/pricing). +base_model = "xiaomi/mimo-v2.5" +reasoning_options = [{ type = "toggle" }] + +[interleaved] +field = "reasoning_content" + +[cost] +input = 0 +output = 0 diff --git a/providers/y-api/models/z-ai/glm-5.2.toml b/providers/y-api/models/z-ai/glm-5.2.toml new file mode 100644 index 00000000000..ba20612cd26 --- /dev/null +++ b/providers/y-api/models/z-ai/glm-5.2.toml @@ -0,0 +1,15 @@ +# Effort: reasoning_effort = high|max; thinking is always on. +# +# Interleaved field: reasoning_details, not the lab's reasoning_content. This +# host returned reasoning_content on 0 of 10 calls (2026-09-16); it returned +# reasoning_details ({type: "reasoning.text"}) on 8 of 10, the other 2 carrying +# no side channel at all. The field that exists is the one authored. +base_model = "zhipuai/glm-5.2" +reasoning_options = [{ type = "effort", values = ["high", "max"] }] + +[interleaved] +field = "reasoning_details" + +[cost] +input = 0.07 +output = 0.22 diff --git a/providers/y-api/models/z-ai/glm-5.3-flash.toml b/providers/y-api/models/z-ai/glm-5.3-flash.toml new file mode 100644 index 00000000000..8e01f3e8084 --- /dev/null +++ b/providers/y-api/models/z-ai/glm-5.3-flash.toml @@ -0,0 +1,10 @@ +# Effort: reasoning_effort = low|high|max; thinking is always on. +base_model = "zhipuai/glm-5.3-flash" +reasoning_options = [{ type = "effort", values = ["low", "high", "max"] }] + +[interleaved] +field = "reasoning_content" + +[cost] +input = 0.0075 +output = 0.025 diff --git a/providers/y-api/models/z-ai/glm-5.3.toml b/providers/y-api/models/z-ai/glm-5.3.toml new file mode 100644 index 00000000000..302785bd235 --- /dev/null +++ b/providers/y-api/models/z-ai/glm-5.3.toml @@ -0,0 +1,10 @@ +# Effort: reasoning_effort = low|high|max; thinking is always on. +base_model = "zhipuai/glm-5.3" +reasoning_options = [{ type = "effort", values = ["low", "high", "max"] }] + +[interleaved] +field = "reasoning_content" + +[cost] +input = 0.07 +output = 0.25 diff --git a/providers/y-api/provider.toml b/providers/y-api/provider.toml new file mode 100644 index 00000000000..ad6f5e223bd --- /dev/null +++ b/providers/y-api/provider.toml @@ -0,0 +1,20 @@ +# Cost basis: USD cash price. The published catalog quotes account credit, and +# credit is topped up at a promotional 20x rate, so every cost value here is +# the credit price / 20. +# +# The 20x rate is stated by the service itself, in two places, both read +# 2026-09-16: +# https://y-api.bestvirtualgoods.com/about +# "Top up $1 to receive $20 of account credit (limited-time rate; reverts +# to 1:10 afterwards)." +# https://y-api.bestvirtualgoods.com/pricing +# "limited-time top up $1 for $20 in credit (reverts to 1:10 afterwards)" +# +# Both pages also say the rate is limited-time and reverts to 1:10. When it +# does, every cost below doubles. The service is not reachable from mainland +# China and quotes no non-USD price, so no FX conversion is involved. +name = "Y-API" +env = ["Y_API_API_KEY"] +npm = "@ai-sdk/openai-compatible" +api = "https://api.y-api.bestvirtualgoods.com/v1" +doc = "https://y-api.bestvirtualgoods.com/docs"