The openai detail parameter is supported by the open ai provider: https://ai-sdk.dev/providers/ai-sdk-providers/openai#image-detail.
Bu when adding it to the openrouter provided it's omitted from the request.
I tried it like in the openai provider just with changing from openai to openrouter:
providerOptions: {
openrouter: { imageDetail: 'low' },
},
Why not just pass the parameters as is to the provider, so there will be no need to add support for each new parameter?
Something like:
providerOptions: {
openrouter: {
openai: {
detail: 'low'
}
},
}
or even:
providerOptions: {
openrouter: {
provider_parameters: {
detail: 'low'
}
},
}
The openai detail parameter is supported by the open ai provider: https://ai-sdk.dev/providers/ai-sdk-providers/openai#image-detail.
Bu when adding it to the openrouter provided it's omitted from the request.
I tried it like in the openai provider just with changing from
openaitoopenrouter:Why not just pass the parameters as is to the provider, so there will be no need to add support for each new parameter?
Something like:
or even: