mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-27 11:43:54 +00:00
Merge pull request #2855 from Caixiaopig/fix_update_default_claude3_maxtokens
Updating the default Anthropic Officlal Claude 3 max_tokens to 4096
This commit is contained in:
commit
9912a80190
1 changed files with 3 additions and 3 deletions
|
@ -31,12 +31,12 @@ class AnthropicError(Exception):
|
|||
|
||||
class AnthropicConfig:
|
||||
"""
|
||||
Reference: https://docs.anthropic.com/claude/reference/complete_post
|
||||
Reference: https://docs.anthropic.com/claude/reference/messages_post
|
||||
|
||||
to pass metadata to anthropic, it's {"user_id": "any-relevant-information"}
|
||||
"""
|
||||
|
||||
max_tokens: Optional[int] = litellm.max_tokens # anthropic requires a default
|
||||
max_tokens: Optional[int] = 4096 # anthropic requires a default value (Opus, Sonnet, and Haiku have the same default)
|
||||
stop_sequences: Optional[list] = None
|
||||
temperature: Optional[int] = None
|
||||
top_p: Optional[int] = None
|
||||
|
@ -46,7 +46,7 @@ class AnthropicConfig:
|
|||
|
||||
def __init__(
|
||||
self,
|
||||
max_tokens: Optional[int] = 256, # anthropic requires a default
|
||||
max_tokens: Optional[int] = 4096, # You can pass in a value yourself or use the default value 4096
|
||||
stop_sequences: Optional[list] = None,
|
||||
temperature: Optional[int] = None,
|
||||
top_p: Optional[int] = None,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue