Skip to content

Update anthropic provider types#346

Open
github-actions[bot] wants to merge 1 commit into
mainfrom
update-anthropic-provider-types-49c63f3d-29244840262
Open

Update anthropic provider types#346
github-actions[bot] wants to merge 1 commit into
mainfrom
update-anthropic-provider-types-49c63f3d-29244840262

Conversation

@github-actions

Copy link
Copy Markdown
Contributor

Automated update of Lingua provider types.

Provider: anthropic

Feedback: comment /bt good or /bt bad to log review feedback to the Braintrust trace.

Validation

  • ./pipelines/generate-provider-types.sh anthropic: failure
  • Claude repair pass: failure
  • Retry ./pipelines/generate-provider-types.sh anthropic: failure
  • make generate-types: failure
  • Braintrust workflow trace: success
  • Claude integration review: failure
  • Post-review make generate-types: failure
  • cargo fmt --all: success
  • cargo build --all-features: failure
  • cargo clippy --all-targets --all-features -- -D warnings: failure
  • make typed-boundary-check: success
  • cargo test -p coverage-report --test cross_provider_test cross_provider_transformations_have_no_unexpected_failures: failure

This PR is created even when validation fails so the generated update and repair attempt are available for manual follow-up.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2dab554434

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "Codex (@codex) review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "Codex (@codex) address that feedback".

pub enum MessageContent {
InputContentBlockArray(Vec<InputContentBlock>),
String(String),
PurpleString(String),

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Keep generated variants compatible with Anthropic callers

Renaming the string arm here breaks the existing Anthropic converter, which still constructs and matches generated::MessageContent::String in multiple paths (for example crates/lingua/src/providers/anthropic/convert.rs:872, :1128, and :1491). Any build that includes the Anthropic provider will fail with missing String variants, so the generation/post-processing needs to preserve the old variant name or update all callers in the same change.

Useful? React with 👍 / 👎.

Comment on lines +1717 to 1720
#[serde(rename = "web_search_20260318")]
WebSearch20260318(WebSearchTool20260318),

#[serde(untagged)]

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Restore tool_search variants in Tool

The Tool enum now jumps from the web search variants straight to Custom, so tool_search_tool_bm25/tool_search_tool_regex requests no longer have typed variants even though ToolSearchTool and the Type enum still contain those tool types. For tool-search payloads that only include name, deserialization falls through to CustomTool, which requires input_schema, so previously supported Anthropic tool-search requests will be rejected or misclassified.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant