@ai-sdk/anthropic 4.0.17 → 4.0.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/dist/index.js +8 -1
- package/dist/index.js.map +1 -1
- package/dist/internal/index.js +7 -0
- package/dist/internal/index.js.map +1 -1
- package/package.json +1 -1
- package/src/anthropic-language-model.ts +11 -0
package/package.json
CHANGED
|
@@ -301,6 +301,17 @@ export class AnthropicLanguageModel implements LanguageModelV4 {
|
|
|
301
301
|
isKnownModel,
|
|
302
302
|
} = getModelCapabilities(this.modelId);
|
|
303
303
|
|
|
304
|
+
if (!isKnownModel && maxOutputTokens == null) {
|
|
305
|
+
warnings.push({
|
|
306
|
+
type: 'compatibility',
|
|
307
|
+
feature: 'maxOutputTokens',
|
|
308
|
+
details:
|
|
309
|
+
`The model "${this.modelId}" is unknown. ` +
|
|
310
|
+
`The max output tokens have been limited to ${maxOutputTokensForModel}. ` +
|
|
311
|
+
`Set maxOutputTokens explicitly to override this limit.`,
|
|
312
|
+
});
|
|
313
|
+
}
|
|
314
|
+
|
|
304
315
|
if (rejectsSamplingParameters) {
|
|
305
316
|
if (temperature != null) {
|
|
306
317
|
warnings.push({
|