Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Claude 3.7 #1149

Merged
merged 2 commits into from
Feb 24, 2025
Merged

Add Claude 3.7 #1149

merged 2 commits into from
Feb 24, 2025

Conversation

cte
Copy link
Collaborator

@cte cte commented Feb 24, 2025

Description

Anyone know if caching works the same as the other Claude models?

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Checklist:

  • My code follows the patterns of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation

Additional context

Related Issues

Reviewers


Important

Add support for Claude 3.7 model with specific properties and update relevant switch cases in anthropic.ts and openrouter.ts.

  • Model Addition:
    • Add claude-3-7-sonnet-20250219 to anthropicModels in api.ts with properties: maxTokens 64,000, contextWindow 200,000, supportsImages true, supportsComputerUse true, supportsPromptCache true, inputPrice $3.0, outputPrice $15.0, cacheWritesPrice $3.75, cacheReadsPrice $0.3.
  • Switch Case Updates:
    • Add claude-3-7-sonnet-20250219 to createMessage() in anthropic.ts.
    • Add anthropic/claude-3.7-sonnet to createMessage() in openrouter.ts.

This description was created by Ellipsis for c677a45. It will automatically update as commits are pushed.

@cte cte requested a review from mrubens as a code owner February 24, 2025 19:15
Copy link

changeset-bot bot commented Feb 24, 2025

⚠️ No Changeset found

Latest commit: 92ac610

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. enhancement New feature or request labels Feb 24, 2025
@@ -95,6 +95,17 @@ export interface ModelInfo {
export type AnthropicModelId = keyof typeof anthropicModels
export const anthropicDefaultModelId: AnthropicModelId = "claude-3-5-sonnet-20241022"
export const anthropicModels = {
"claude-3-7-sonnet-20250219": {
maxTokens: 128_000,
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Up from 8K.

@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Feb 24, 2025
@cte cte merged commit 645d069 into main Feb 24, 2025
9 checks passed
@cte cte deleted the cte/claude-3.7 branch February 24, 2025 19:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request lgtm This PR has been approved by a maintainer size:S This PR changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants