Skip to content

Commit 14830d6

Browse files
chore: sync model metadata from OpenRouter (#488)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
1 parent 633a3d9 commit 14830d6

4 files changed

Lines changed: 159 additions & 40 deletions

File tree

.changeset/sync-models.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@tanstack/ai-openrouter': patch
3+
---
4+
5+
Update model metadata from OpenRouter API

packages/typescript/ai-openrouter/src/model-meta.ts

Lines changed: 72 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1882,6 +1882,7 @@ const DEEPSEEK_DEEPSEEK_V3_2 = {
18821882
'logitBias',
18831883
'logprobs',
18841884
'maxCompletionTokens',
1885+
'parallelToolCalls',
18851886
'presencePenalty',
18861887
'reasoning',
18871888
'responseFormat',
@@ -1893,16 +1894,16 @@ const DEEPSEEK_DEEPSEEK_V3_2 = {
18931894
'topP',
18941895
],
18951896
},
1896-
context_window: 163840,
1897-
max_output_tokens: 163840,
1897+
context_window: 131072,
1898+
max_output_tokens: 32768,
18981899
pricing: {
18991900
text: {
19001901
input: {
1901-
normal: 0.259,
1902-
cached: 0.135,
1902+
normal: 0.252,
1903+
cached: 0.0252,
19031904
},
19041905
output: {
1905-
normal: 0.42,
1906+
normal: 0.378,
19061907
},
19071908
},
19081909
image: 0,
@@ -3954,11 +3955,11 @@ const MINIMAX_MINIMAX_M2_5 = {
39543955
pricing: {
39553956
text: {
39563957
input: {
3957-
normal: 0.118,
3958-
cached: 0.059,
3958+
normal: 0.15,
3959+
cached: 0.075,
39593960
},
39603961
output: {
3961-
normal: 0.99,
3962+
normal: 1.2,
39623963
},
39633964
},
39643965
image: 0,
@@ -4952,11 +4953,46 @@ const MOONSHOTAI_KIMI_K2_5 = {
49524953
pricing: {
49534954
text: {
49544955
input: {
4955-
normal: 0.3827,
4956-
cached: 0.19135,
4956+
normal: 0.44,
4957+
cached: 0.22,
4958+
},
4959+
output: {
4960+
normal: 2,
4961+
},
4962+
},
4963+
image: 0,
4964+
},
4965+
} as const
4966+
const MOONSHOTAI_KIMI_K2_6 = {
4967+
id: 'moonshotai/kimi-k2.6',
4968+
name: 'MoonshotAI: Kimi K2.6',
4969+
supports: {
4970+
input: ['text', 'image'],
4971+
output: ['text'],
4972+
supports: [
4973+
'frequencyPenalty',
4974+
'logitBias',
4975+
'maxCompletionTokens',
4976+
'presencePenalty',
4977+
'reasoning',
4978+
'responseFormat',
4979+
'seed',
4980+
'stop',
4981+
'temperature',
4982+
'toolChoice',
4983+
'topP',
4984+
],
4985+
},
4986+
context_window: 262144,
4987+
max_output_tokens: 262144,
4988+
pricing: {
4989+
text: {
4990+
input: {
4991+
normal: 0.6,
4992+
cached: 0.2,
49574993
},
49584994
output: {
4959-
normal: 1.72,
4995+
normal: 2.8,
49604996
},
49614997
},
49624998
image: 0,
@@ -10633,15 +10669,14 @@ const Z_AI_GLM_4_7 = {
1063310669
],
1063410670
},
1063510671
context_window: 202752,
10636-
max_output_tokens: 65535,
1063710672
pricing: {
1063810673
text: {
1063910674
input: {
10640-
normal: 0.39,
10641-
cached: 0.195,
10675+
normal: 0.38,
10676+
cached: 0,
1064210677
},
1064310678
output: {
10644-
normal: 1.75,
10679+
normal: 1.74,
1064510680
},
1064610681
},
1064710682
image: 0,
@@ -10776,15 +10811,15 @@ const Z_AI_GLM_5_1 = {
1077610811
],
1077710812
},
1077810813
context_window: 202752,
10779-
max_output_tokens: 65535,
10814+
max_output_tokens: 131072,
1078010815
pricing: {
1078110816
text: {
1078210817
input: {
10783-
normal: 0.95,
10784-
cached: 0.475,
10818+
normal: 0.698,
10819+
cached: 0.26,
1078510820
},
1078610821
output: {
10787-
normal: 3.15,
10822+
normal: 4.4,
1078810823
},
1078910824
},
1079010825
image: 0,
@@ -11492,6 +11527,7 @@ export type OpenRouterModelOptionsByName = {
1149211527
| 'logitBias'
1149311528
| 'logprobs'
1149411529
| 'maxCompletionTokens'
11530+
| 'parallelToolCalls'
1149511531
| 'presencePenalty'
1149611532
| 'reasoning'
1149711533
| 'responseFormat'
@@ -12643,6 +12679,21 @@ export type OpenRouterModelOptionsByName = {
1264312679
| 'topLogprobs'
1264412680
| 'topP'
1264512681
>
12682+
[MOONSHOTAI_KIMI_K2_6.id]: OpenRouterCommonOptions &
12683+
Pick<
12684+
OpenRouterBaseOptions,
12685+
| 'frequencyPenalty'
12686+
| 'logitBias'
12687+
| 'maxCompletionTokens'
12688+
| 'presencePenalty'
12689+
| 'reasoning'
12690+
| 'responseFormat'
12691+
| 'seed'
12692+
| 'stop'
12693+
| 'temperature'
12694+
| 'toolChoice'
12695+
| 'topP'
12696+
>
1264612697
[MORPH_MORPH_V3_FAST.id]: OpenRouterCommonOptions &
1264712698
Pick<OpenRouterBaseOptions, 'maxCompletionTokens' | 'stop' | 'temperature'>
1264812699
[MORPH_MORPH_V3_LARGE.id]: OpenRouterCommonOptions &
@@ -15070,6 +15121,7 @@ export type OpenRouterModelInputModalitiesByName = {
1507015121
[MOONSHOTAI_KIMI_K2_0905.id]: ReadonlyArray<'text'>
1507115122
[MOONSHOTAI_KIMI_K2_THINKING.id]: ReadonlyArray<'text'>
1507215123
[MOONSHOTAI_KIMI_K2_5.id]: ReadonlyArray<'text' | 'image'>
15124+
[MOONSHOTAI_KIMI_K2_6.id]: ReadonlyArray<'text' | 'image'>
1507315125
[MORPH_MORPH_V3_FAST.id]: ReadonlyArray<'text'>
1507415126
[MORPH_MORPH_V3_LARGE.id]: ReadonlyArray<'text'>
1507515127
[NEX_AGI_DEEPSEEK_V3_1_NEX_N1.id]: ReadonlyArray<'text'>
@@ -15421,6 +15473,7 @@ export const OPENROUTER_CHAT_MODELS = [
1542115473
MOONSHOTAI_KIMI_K2_0905.id,
1542215474
MOONSHOTAI_KIMI_K2_THINKING.id,
1542315475
MOONSHOTAI_KIMI_K2_5.id,
15476+
MOONSHOTAI_KIMI_K2_6.id,
1542415477
MORPH_MORPH_V3_FAST.id,
1542515478
MORPH_MORPH_V3_LARGE.id,
1542615479
NEX_AGI_DEEPSEEK_V3_1_NEX_N1.id,

scripts/.sync-models-last-run

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1776671203
1+
1776755944

0 commit comments

Comments
 (0)