Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/model-parameters-schema.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ Conventions:

- `provider`, `authType`, and `model` identify exactly one model route.
- `provider` is a kebab-case slug.
- `model` is the provider-native model id without path separators. It may
contain dots or colons when the upstream model id does.
- `model` is the provider-native model id without path separators. Preserve
upstream casing; it may contain dots or colons when the upstream model id does.
- `authType` is `api_key` or `subscription`.
- `params` is the non-empty list of parameters for that exact route.
- `path` is the exact provider API request parameter path in dot notation. Use
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# yaml-language-server: $schema=https://modelparams.dev/api/v1/schema.json
provider: minimax
authType: subscription
model: minimax-m2.7
model: MiniMax-M2
params:
- path: max_tokens
type: integer
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# yaml-language-server: $schema=https://modelparams.dev/api/v1/schema.json
provider: minimax
authType: subscription
model: minimax-m2.7-highspeed
model: MiniMax-M2.1-highspeed
params:
- path: max_tokens
type: integer
Expand Down
34 changes: 34 additions & 0 deletions models/minimax/MiniMax-M2.1-subscription.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# yaml-language-server: $schema=https://modelparams.dev/api/v1/schema.json
provider: minimax
authType: subscription
model: MiniMax-M2.1
params:
- path: max_tokens
type: integer
label: Max tokens
description: Maximum number of tokens to generate in the response.
range:
min: 1
group: generation_length
- path: temperature
type: number
label: Temperature
description: >-
Controls randomness. Lower values make outputs more focused; higher values make them more
varied. Values must be greater than 0 and at most 1.
default: 1
range:
min: 0.01
max: 1
step: 0.01
group: sampling
- path: top_p
type: number
label: Top P
description: Controls nucleus sampling by limiting generation to tokens within the selected cumulative probability.
default: 0.95
range:
min: 0.01
max: 1
step: 0.01
group: sampling
34 changes: 34 additions & 0 deletions models/minimax/MiniMax-M2.5-highspeed-subscription.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# yaml-language-server: $schema=https://modelparams.dev/api/v1/schema.json
provider: minimax
authType: subscription
model: MiniMax-M2.5-highspeed
params:
- path: max_tokens
type: integer
label: Max tokens
description: Maximum number of tokens to generate in the response.
range:
min: 1
group: generation_length
- path: temperature
type: number
label: Temperature
description: >-
Controls randomness. Lower values make outputs more focused; higher values make them more
varied. Values must be greater than 0 and at most 1.
default: 1
range:
min: 0.01
max: 1
step: 0.01
group: sampling
- path: top_p
type: number
label: Top P
description: Controls nucleus sampling by limiting generation to tokens within the selected cumulative probability.
default: 0.95
range:
min: 0.01
max: 1
step: 0.01
group: sampling
34 changes: 34 additions & 0 deletions models/minimax/MiniMax-M2.5-subscription.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# yaml-language-server: $schema=https://modelparams.dev/api/v1/schema.json
provider: minimax
authType: subscription
model: MiniMax-M2.5
params:
- path: max_tokens
type: integer
label: Max tokens
description: Maximum number of tokens to generate in the response.
range:
min: 1
group: generation_length
- path: temperature
type: number
label: Temperature
description: >-
Controls randomness. Lower values make outputs more focused; higher values make them more
varied. Values must be greater than 0 and at most 1.
default: 1
range:
min: 0.01
max: 1
step: 0.01
group: sampling
- path: top_p
type: number
label: Top P
description: Controls nucleus sampling by limiting generation to tokens within the selected cumulative probability.
default: 0.95
range:
min: 0.01
max: 1
step: 0.01
group: sampling
34 changes: 34 additions & 0 deletions models/minimax/MiniMax-M2.7-highspeed-subscription.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# yaml-language-server: $schema=https://modelparams.dev/api/v1/schema.json
provider: minimax
authType: subscription
model: MiniMax-M2.7-highspeed
params:
- path: max_tokens
type: integer
label: Max tokens
description: Maximum number of tokens to generate in the response.
range:
min: 1
group: generation_length
- path: temperature
type: number
label: Temperature
description: >-
Controls randomness. Lower values make outputs more focused; higher values make them more
varied. Values must be greater than 0 and at most 1.
default: 1
range:
min: 0.01
max: 1
step: 0.01
group: sampling
- path: top_p
type: number
label: Top P
description: Controls nucleus sampling by limiting generation to tokens within the selected cumulative probability.
default: 0.95
range:
min: 0.01
max: 1
step: 0.01
group: sampling
34 changes: 34 additions & 0 deletions models/minimax/MiniMax-M2.7-subscription.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# yaml-language-server: $schema=https://modelparams.dev/api/v1/schema.json
provider: minimax
authType: subscription
model: MiniMax-M2.7
params:
- path: max_tokens
type: integer
label: Max tokens
description: Maximum number of tokens to generate in the response.
range:
min: 1
group: generation_length
- path: temperature
type: number
label: Temperature
description: >-
Controls randomness. Lower values make outputs more focused; higher values make them more
varied. Values must be greater than 0 and at most 1.
default: 1
range:
min: 0.01
max: 1
step: 0.01
group: sampling
- path: top_p
type: number
label: Top P
description: Controls nucleus sampling by limiting generation to tokens within the selected cumulative probability.
default: 0.95
range:
min: 0.01
max: 1
step: 0.01
group: sampling
41 changes: 41 additions & 0 deletions models/z-ai/glm-4.5-subscription.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# yaml-language-server: $schema=https://modelparams.dev/api/v1/schema.json
provider: z-ai
authType: subscription
model: glm-4.5
params:
- path: max_tokens
type: integer
label: Max tokens
description: Maximum number of tokens to generate in the response.
range:
min: 1
group: generation_length
- path: temperature
type: number
label: Temperature
description: Controls randomness. Lower values make outputs more focused; higher values make them more varied.
default: 1
range:
min: 0
max: 1
step: 0.1
group: sampling
- path: top_p
type: number
label: Top P
description: Controls nucleus sampling by limiting generation to tokens within the selected cumulative probability.
default: 0.95
range:
min: 0.01
max: 1
step: 0.01
group: sampling
- path: thinking.type
type: enum
label: Thinking mode
description: Toggles the model's extended reasoning before it produces the final answer.
default: enabled
values:
- enabled
- disabled
group: reasoning
41 changes: 41 additions & 0 deletions models/z-ai/glm-4.6-subscription.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# yaml-language-server: $schema=https://modelparams.dev/api/v1/schema.json
provider: z-ai
authType: subscription
model: glm-4.6
params:
- path: max_tokens
type: integer
label: Max tokens
description: Maximum number of tokens to generate in the response.
range:
min: 1
group: generation_length
- path: temperature
type: number
label: Temperature
description: Controls randomness. Lower values make outputs more focused; higher values make them more varied.
default: 1
range:
min: 0
max: 1
step: 0.1
group: sampling
- path: top_p
type: number
label: Top P
description: Controls nucleus sampling by limiting generation to tokens within the selected cumulative probability.
default: 0.95
range:
min: 0.01
max: 1
step: 0.01
group: sampling
- path: thinking.type
type: enum
label: Thinking mode
description: Toggles the model's extended reasoning before it produces the final answer.
default: enabled
values:
- enabled
- disabled
group: reasoning
41 changes: 41 additions & 0 deletions models/z-ai/glm-5-subscription.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# yaml-language-server: $schema=https://modelparams.dev/api/v1/schema.json
provider: z-ai
authType: subscription
model: glm-5
params:
- path: max_tokens
type: integer
label: Max tokens
description: Maximum number of tokens to generate in the response.
range:
min: 1
group: generation_length
- path: temperature
type: number
label: Temperature
description: Controls randomness. Lower values make outputs more focused; higher values make them more varied.
default: 1
range:
min: 0
max: 1
step: 0.1
group: sampling
- path: top_p
type: number
label: Top P
description: Controls nucleus sampling by limiting generation to tokens within the selected cumulative probability.
default: 0.95
range:
min: 0.01
max: 1
step: 0.01
group: sampling
- path: thinking.type
type: enum
label: Thinking mode
description: Toggles the model's extended reasoning before it produces the final answer.
default: enabled
values:
- enabled
- disabled
group: reasoning
2 changes: 1 addition & 1 deletion src/schema/model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export const ParameterGroup = z.enum([
export type ParameterGroup = z.infer<typeof ParameterGroup>;

const PROVIDER_SLUG = /^[a-z0-9][a-z0-9-]*$/;
const MODEL_ID = /^[a-z0-9][a-z0-9._:-]*$/;
const MODEL_ID = /^[A-Za-z0-9][A-Za-z0-9._:-]*$/;
const PARAM_PATH = /^[A-Za-z][A-Za-z0-9_]*(\.[A-Za-z][A-Za-z0-9_]*)*$/;
const BLOCKED_PARAM_PATHS = new Set(["stream"]);

Expand Down
5 changes: 5 additions & 0 deletions tests/schema.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,11 @@ describe("Model schema", () => {
expect(result.success).toBe(true);
});

it("accepts provider-native model ids with uppercase characters", () => {
const result = Model.safeParse({ ...VALID_MODEL, provider: "minimax", model: "MiniMax-M2.7" });
expect(result.success).toBe(true);
});

it("rejects path separators in model ids", () => {
const result = Model.safeParse({
...VALID_MODEL,
Expand Down
Loading