feat(dotAI): Dot AI LangChain4J - Anthropic#36138
Conversation
|
Claude finished @ihoffmann-dot's task in 1m 12s —— View job Rollback Safety Analysis
Result: ✅ Safe To RollbackThis PR adds Anthropic as a new AI provider by introducing a new Java class ( Category-by-category analysis:
Changes in this PR are purely additive:
Rolling back to the previous release simply removes the Anthropic provider option — no data written, no schema changed, N-1 starts and operates identically to before. Label applied: AI: Safe To Rollback |
🤖 Codex Review —
|
🤖 Bedrock Review —
|
🤖 Bedrock Review —
|
Summary
Adds Anthropic as a supported provider, talking directly to the Anthropic Messages
API with an API key — distinct from accessing Claude models through AWS Bedrock,
which requires AWS infrastructure and IAM credentials.
langchain4j-anthropicdependency (version via langchain4j BOM)AnthropicModelProviderStrategyregistered inLangChain4jModelFactory.STRATEGIESAnthropicChatModel/AnthropicStreamingChatModelUnsupportedOperationException(Anthropic has no such APIs)endpointconfig field overrides the default base URL (proxies/gateways)LangChain4jModelFactoryTestConfiguration
{ "chat": { "provider": "anthropic", "model": "claude-sonnet-4-6", "apiKey": "sk-ant-...", "maxTokens": 4096, "temperature": 0.7 } }Notes
claude-sonnet-4-6,claude-opus-4-8,claude-haiku-4-5.maxRetriesis not supported by the streaming chat model and is ignored with a warning (same behavior as the OpenAI provider).Related Issue
This PR fixes #36135
EPIC: dotAI Multi-Provider Support #33970