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 model #2432

Merged
merged 4 commits into from
Mar 5, 2024
Merged

Add Claude 3 model #2432

merged 4 commits into from
Mar 5, 2024

Conversation

yifanmai
Copy link
Collaborator

@yifanmai yifanmai commented Mar 5, 2024

No description provided.

tokenizer_name: anthropic/claude
max_sequence_length: 200000
client_spec:
class_name: "helm.clients.anthropic_client.AnthropicMessagesClient"
Copy link
Contributor

Choose a reason for hiding this comment

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

What about haiku?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

No Haiku because "Haiku will be available soon." (source)

@@ -229,6 +229,22 @@ models:
release_date: 2023-11-21
tags: [ANTHROPIC_CLAUDE_2_MODEL_TAG, TEXT_MODEL_TAG, LIMITED_FUNCTIONALITY_TEXT_MODEL_TAG, ABLATION_MODEL_TAG, INSTRUCTION_FOLLOWING_MODEL_TAG]

- name: anthropic/claude-3-sonnet-20240229
display_name: Claude 3 Sonnet (20240229)
description: TBD
Copy link
Contributor

Choose a reason for hiding this comment

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

Do we have an issue to get these filled? We need them before we actually deploy...

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Filed #2435

if request.messages:
messages = cast(List[MessageParam], request.messages)
if messages[0]["role"] == "system":
system_message = messages.pop(0)
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we clone to avoid mutating request?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Good catch... changed to messages = messages[1:] instead which does not mutate.

Copy link
Contributor

@JosselinSomervilleRoberts JosselinSomervilleRoberts left a comment

Choose a reason for hiding this comment

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

How can we add images in the prompt, is this documented by Anthropic?

@yifanmai yifanmai merged commit 5b1cfdc into main Mar 5, 2024
6 checks passed
@yifanmai yifanmai deleted the yifanmai/fix-add-claude-3 branch March 5, 2024 23:03
@yifanmai
Copy link
Collaborator Author

yifanmai commented Mar 6, 2024

Image support will be added in #2440.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants