Skip to content
1 min read · 134 words

@nhtio/adk/batteries/llm/anthropic_messages/error_translation

SDK error → ADK classification for the Anthropic Messages battery.

Remarks

Extracted so the dispatch path (adapter.ts) and the token-count path (count_tokens.ts) share ONE classifier. They previously carried byte-identical private copies, which meant a fix to one silently left the other wrong — exactly what happened with the statusless-APIError bug this module's AnthropicMessagesErrorStatusResolver seam addresses.

Type Aliases

Type AliasDescription
AnthropicErrorClassificationThe outcome of classifying an SDK error.

Variables

VariableDescription
CONTEXT_OVERFLOW_PHRASEBody-text marker identifying an Anthropic context-overflow rejection.

Functions

FunctionDescription
translateAnthropicErrorClassify an error thrown by the Anthropic SDK into an ADK disposition.