Skip to content

abridge: port the cc_convert fixture corpus to cover the Python Anthropic↔OpenAI transforms #141

Description

@Meirtz

The production Anthropic↔OpenAI conversion layer (plugins/abridge/agentix/bridge/clients/_anthropic_transforms.py + the AnthropicFromOpenAIClient / AnthropicToOpenAI clients) is covered by ~9 hand-written unit tests.

The deferred stage F tree of #122 (sidecars/cc_convert/tests/fixtures/) contains a ~180-case corpus — requests/responses/streams as JSON, parity-tested upstream against LiteLLM's AnthropicAdapter — covering exactly the edge cases the Python path currently handles thinly or not at all: streams ending without finish_reason, cached-token usage accounting, thinking/reasoning blocks, cache_control placement, tool_choice any/named/none, image blocks, stop_sequences, parallel tool calls, o-series max_completion_tokens.

Follow-up: port the fixtures only (JSON files, no Rust) into abridge's test tree as a parametrized suite over the Python transforms. Expected-failure cases become the prioritized gap list (streaming first, then thinking / tool_choice / images / stop_sequences), to be closed as real agents demand them — or by depending on the published cc-convert wheel behind the existing pure-function seam.

Related: #122 (stage F deferral rationale in the split summary comment).

🤖 Generated with Claude Code

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions