1
0

refactor: 实现 ConversionEngine 协议转换引擎,替代旧 protocol 包

引入 Canonical Model 和 ProtocolAdapter 架构,支持 OpenAI/Anthropic 协议间
无缝转换,统一 ProxyHandler 替代分散的 OpenAI/Anthropic Handler,简化
ProviderClient 为协议无关的 HTTP 发送器,Provider 新增 protocol 字段。
This commit is contained in:
2026-04-20 00:36:27 +08:00
parent 26810d9410
commit 1dac347d3b
65 changed files with 9690 additions and 2139 deletions

View File

@@ -2,7 +2,7 @@
### Requirement: 实现 Anthropic ProtocolAdapter
系统 SHALL 实现 Anthropic 协议的完整 ProtocolAdapter对照 `docs/conversion_anthropic.md`
系统 SHALL 全新实现 Anthropic 协议的完整 ProtocolAdapter对照 `docs/conversion_anthropic.md`不沿用旧 `internal/protocol/anthropic/` 代码。
- `protocolName()` SHALL 返回 `"anthropic"`
- `supportsPassthrough()` SHALL 返回 true