-
Notifications
You must be signed in to change notification settings - Fork 8.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add Anthropic claude-3 models support (#2684)
- Loading branch information
Showing
12 changed files
with
423 additions
and
148 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
api/core/model_runtime/model_providers/anthropic/llm/_position.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
- claude-3-opus-20240229 | ||
- claude-3-sonnet-20240229 | ||
- claude-2.1 | ||
- claude-instant-1.2 | ||
- claude-2 | ||
- claude-instant-1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -34,3 +34,4 @@ pricing: | |
output: '24.00' | ||
unit: '0.000001' | ||
currency: USD | ||
deprecated: true |
37 changes: 37 additions & 0 deletions
37
api/core/model_runtime/model_providers/anthropic/llm/claude-3-opus-20240229.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
model: claude-3-opus-20240229 | ||
label: | ||
en_US: claude-3-opus-20240229 | ||
model_type: llm | ||
features: | ||
- agent-thought | ||
- vision | ||
model_properties: | ||
mode: chat | ||
context_size: 200000 | ||
parameter_rules: | ||
- name: temperature | ||
use_template: temperature | ||
- name: top_p | ||
use_template: top_p | ||
- name: top_k | ||
label: | ||
zh_Hans: 取样数量 | ||
en_US: Top k | ||
type: int | ||
help: | ||
zh_Hans: 仅从每个后续标记的前 K 个选项中采样。 | ||
en_US: Only sample from the top K options for each subsequent token. | ||
required: false | ||
- name: max_tokens | ||
use_template: max_tokens | ||
required: true | ||
default: 4096 | ||
min: 1 | ||
max: 4096 | ||
- name: response_format | ||
use_template: response_format | ||
pricing: | ||
input: '15.00' | ||
output: '75.00' | ||
unit: '0.000001' | ||
currency: USD |
37 changes: 37 additions & 0 deletions
37
api/core/model_runtime/model_providers/anthropic/llm/claude-3-sonnet-20240229.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
model: claude-3-sonnet-20240229 | ||
label: | ||
en_US: claude-3-sonnet-20240229 | ||
model_type: llm | ||
features: | ||
- agent-thought | ||
- vision | ||
model_properties: | ||
mode: chat | ||
context_size: 200000 | ||
parameter_rules: | ||
- name: temperature | ||
use_template: temperature | ||
- name: top_p | ||
use_template: top_p | ||
- name: top_k | ||
label: | ||
zh_Hans: 取样数量 | ||
en_US: Top k | ||
type: int | ||
help: | ||
zh_Hans: 仅从每个后续标记的前 K 个选项中采样。 | ||
en_US: Only sample from the top K options for each subsequent token. | ||
required: false | ||
- name: max_tokens | ||
use_template: max_tokens | ||
required: true | ||
default: 4096 | ||
min: 1 | ||
max: 4096 | ||
- name: response_format | ||
use_template: response_format | ||
pricing: | ||
input: '3.00' | ||
output: '15.00' | ||
unit: '0.000001' | ||
currency: USD |
35 changes: 35 additions & 0 deletions
35
api/core/model_runtime/model_providers/anthropic/llm/claude-instant-1.2.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
model: claude-instant-1.2 | ||
label: | ||
en_US: claude-instant-1.2 | ||
model_type: llm | ||
features: [ ] | ||
model_properties: | ||
mode: chat | ||
context_size: 100000 | ||
parameter_rules: | ||
- name: temperature | ||
use_template: temperature | ||
- name: top_p | ||
use_template: top_p | ||
- name: top_k | ||
label: | ||
zh_Hans: 取样数量 | ||
en_US: Top k | ||
type: int | ||
help: | ||
zh_Hans: 仅从每个后续标记的前 K 个选项中采样。 | ||
en_US: Only sample from the top K options for each subsequent token. | ||
required: false | ||
- name: max_tokens | ||
use_template: max_tokens | ||
required: true | ||
default: 4096 | ||
min: 1 | ||
max: 4096 | ||
- name: response_format | ||
use_template: response_format | ||
pricing: | ||
input: '1.63' | ||
output: '5.51' | ||
unit: '0.000001' | ||
currency: USD |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -33,3 +33,4 @@ pricing: | |
output: '5.51' | ||
unit: '0.000001' | ||
currency: USD | ||
deprecated: true |
Oops, something went wrong.