-
Notifications
You must be signed in to change notification settings - Fork 637
Closed
Labels
bugThis issue is a bug.This issue is a bug.p2This is a standard priority issueThis is a standard priority issueservice-apiThis issue is due to a problem in a service API, not the SDK implementation.This issue is due to a problem in a service API, not the SDK implementation.
Description
Checkboxes for prior research
- I've gone through Developer Guide and API reference
- I've checked AWS Forums and StackOverflow.
- I've searched for previous similar issues and didn't find any solution.
Describe the bug
When sending a request that exceeds the allowed token count:
anthropic.claude-3-haiku-20240307-v1:0will throw aValidationExceptionwith a descriptive message:ValidationException: Input is too long for requested model.anthropic.claude-3-opus-20240229-v1:0will throw aModelStreamErrorExceptionwith a generic message:The system encountered an unexpected error during processing. Try your request again.
SDK version number
@aws-sdk/[email protected]
Which JavaScript Runtime is this issue in?
Node.js
Details of the browser/Node.js/ReactNative version
v20.11.0
Reproduction Steps
Sending a request that exceeds the allowed token count and examine the exception thrown.
Observed Behavior
anthropic.claude-3-haiku-20240307-v1:0will throw aValidationExceptionwith a descriptive message:ValidationException: Input is too long for requested model.anthropic.claude-3-opus-20240229-v1:0will throw aModelStreamErrorExceptionwith a generic message:The system encountered an unexpected error during processing. Try your request again.
Expected Behavior
The same exception type for both models, with information that allows us to respond correctly.
Possible Solution
No response
Additional Information/Context
No response
tokarev-artem
Metadata
Metadata
Assignees
Labels
bugThis issue is a bug.This issue is a bug.p2This is a standard priority issueThis is a standard priority issueservice-apiThis issue is due to a problem in a service API, not the SDK implementation.This issue is due to a problem in a service API, not the SDK implementation.