feat(ai): type Anthropic request options (#39502)
This commit is contained in:
parent
224feff7c4
commit
f5cdf0f056
2 changed files with 17 additions and 1 deletions
|
|
@ -52,7 +52,10 @@ export const configure = (input: Config = {}) => {
|
|||
}
|
||||
|
||||
export const provider = configure()
|
||||
export const model: ProviderPackage.Definition<Settings>["model"] = (modelID, settings) => {
|
||||
export const model: ProviderPackage.Definition<Settings, AnthropicMessages.ProviderOptionsInput>["model"] = (
|
||||
modelID,
|
||||
settings,
|
||||
) => {
|
||||
if (settings.apiKey !== undefined && settings.authToken !== undefined)
|
||||
throw new Error("Anthropic apiKey cannot be combined with authToken")
|
||||
return configure({
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue