Skip to content

Upgrading anthropic 0.3 to 0.4

Safe0.3.11 → 0.4.1Fixed2Other3

SafeUpgrade verdict

Only new features and fixes in this range.

  • Nothing in this range needs changes to your code. It adds features and fixes.
Nothing to change

No breaking, platform, security or deprecated items in this range.

Nothing in this upgrade needs a code or configuration change.

Generated by DepDelta from published Python source. Not mixed with prose notes.

  • added: export AnthropicError
  • changed: async method AsyncCompletions.create(*, max_tokens_to_sample: int, model: Union[str, Literal['claude-2', 'claude-instant-1']], prompt: str, metadata: completion_create_params.CompletionRequestNonStreamingMetadata | NotGiven=…, stop_sequences: List[str] | NotGiven=…, stream: Literal[False] | NotGiven=…, temperature: float | NotGiven=…, top_k: int | NotGiven=…, top_p: float | NotGiven=…, extra_head… → async method AsyncCompletions.create(*, max_tokens_to_sample: int, model: Union[str, Literal['claude-2', 'claude-instant-1']], prompt: str, metadata: completion_create_params.Metadata | NotGiven=…, stop_sequences: List[str] | NotGiven=…, stream: Literal[False] | NotGiven=…, temperature: float | NotGiven=…, top_k: int | NotGiven=…, top_p: float | NotGiven=…, extra_headers: Headers | None=…, extra_…
  • changed: method Completions.create(*, max_tokens_to_sample: int, model: Union[str, Literal['claude-2', 'claude-instant-1']], prompt: str, metadata: completion_create_params.CompletionRequestNonStreamingMetadata | NotGiven=…, stop_sequences: List[str] | NotGiven=…, stream: Literal[False] | NotGiven=…, temperature: float | NotGiven=…, top_k: int | NotGiven=…, top_p: float | NotGiven=…, extra_headers: Header… → method Completions.create(*, max_tokens_to_sample: int, model: Union[str, Literal['claude-2', 'claude-instant-1']], prompt: str, metadata: completion_create_params.Metadata | NotGiven=…, stop_sequences: List[str] | NotGiven=…, stream: Literal[False] | NotGiven=…, temperature: float | NotGiven=…, top_k: int | NotGiven=…, top_p: float | NotGiven=…, extra_headers: Headers | None=…, extra_query: Quer…
  • removed: class CompletionRequestNonStreaming(TypedDict)
  • removed: class CompletionRequestNonStreamingMetadata(TypedDict)
  • removed: class CompletionRequestStreaming(TypedDict)
  • removed: class CompletionRequestStreamingMetadata(TypedDict)
  • removed: field CompletionRequestNonStreaming.max_tokens_to_sample: Required[int]
  • removed: field CompletionRequestNonStreaming.metadata: CompletionRequestNonStreamingMetadata
  • removed: field CompletionRequestNonStreaming.model: Required[Union[str, Literal['claude-2', 'claude-instant-1']]]
  • removed: field CompletionRequestNonStreaming.prompt: Required[str]
  • removed: field CompletionRequestNonStreaming.stop_sequences: List[str]
  • removed: field CompletionRequestNonStreaming.stream: Literal[False]
  • removed: field CompletionRequestNonStreaming.temperature: float
  • removed: field CompletionRequestNonStreaming.top_k: int
  • removed: field CompletionRequestNonStreaming.top_p: float
  • removed: field CompletionRequestNonStreamingMetadata.user_id: str
  • removed: field CompletionRequestStreaming.max_tokens_to_sample: Required[int]
  • removed: field CompletionRequestStreaming.metadata: CompletionRequestStreamingMetadata
  • removed: field CompletionRequestStreaming.model: Required[Union[str, Literal['claude-2', 'claude-instant-1']]]
  • removed: field CompletionRequestStreaming.prompt: Required[str]
  • removed: field CompletionRequestStreaming.stop_sequences: List[str]
  • removed: field CompletionRequestStreaming.stream: Required[Literal[True]]
  • removed: field CompletionRequestStreaming.temperature: float
  • removed: field CompletionRequestStreaming.top_k: int
  • removed: field CompletionRequestStreaming.top_p: float
  • removed: field CompletionRequestStreamingMetadata.user_id: str
  • removed: variable CompletionCreateParams
  • added: class CompletionCreateParamsBase(TypedDict)
  • added: class CompletionCreateParamsNonStreaming(CompletionCreateParamsBase)
  • added: class CompletionCreateParamsStreaming(CompletionCreateParamsBase)
  • added: class Metadata(TypedDict)
  • added: field CompletionCreateParamsBase.max_tokens_to_sample: Required[int]
  • added: field CompletionCreateParamsBase.metadata: Metadata
  • added: field CompletionCreateParamsBase.model: Required[Union[str, Literal['claude-2', 'claude-instant-1']]]
  • added: field CompletionCreateParamsBase.prompt: Required[str]
  • added: field CompletionCreateParamsBase.stop_sequences: List[str]
  • added: field CompletionCreateParamsBase.temperature: float
  • added: field CompletionCreateParamsBase.top_k: int
  • added: field CompletionCreateParamsBase.top_p: float
  • added: field CompletionCreateParamsNonStreaming.stream: Literal[False]
  • added: field CompletionCreateParamsStreaming.stream: Required[Literal[True]]
  • added: field Metadata.user_id: str
  • added: variable CompletionRequestNonStreaming
  • added: variable CompletionRequestNonStreamingMetadata
  • added: variable CompletionRequestStreaming
  • added: variable CompletionRequestStreamingMetadata