Feat/v0.11.0 anthropic api#12
Merged
Merged
Conversation
…tion Add POST /v1/messages endpoint for Anthropic SDK clients. The `type` field in backends config becomes a protocol selector (openai|anthropic|ollama). Cross-protocol translation works for all 4 combinations: requests and responses (including streaming) are automatically converted between OpenAI Chat Completions and Anthropic Messages formats. Key changes: - New Anthropic backend client (backends/anthropic.go) with x-api-key auth - Translation layer (internal/api/translate/) for request, response, and streaming SSE format conversion between OpenAI and Anthropic - Dual auth: both Authorization: Bearer and x-api-key accepted on all endpoints - /v1/completions and /v1/embeddings return error for Anthropic-only backends - Extended thinking stripped in cross-protocol mode, passthrough in same-protocol Version: v0.11.0 Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Reflect v0.11.0 multi-protocol capabilities: dual auth, /v1/messages endpoint, cross-protocol translation, Anthropic backend config example, updated architecture diagrams. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Same deliberate pattern as proxyHandler — uses context.Background() to survive client disconnects during DB writes. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Anthropic Messages API, cross-protocol translation, dual auth, per-backend protocol selector, translation layer, updated docs. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Step 3 now mandates updating CHANGELOG.md (Added/Changed/Fixed/Removed sections + compare links) before creating the PR — prevents the omission that happened in v0.11.0. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Type
feat— new user-visible functionalityfix— bug fixdocs— documentation onlyrefactor— internal change without behaviour changetest— tests onlychore— build, CI, dependenciesRelated issue
Closes #
Checklist
go build ./...succeeds.go test -race ./...passes.gofmt -l .returns no files.go vet ./...is clean.golangci-lint runreturns no new issues.CHANGELOG.mdupdated under[Unreleased]if user-visible.docs/updated if architecture, API, or SRS requirements change.Notes for reviewers