8 views
-/https://github.com/berriai/litellm/issues/31882
GitHub · issue

#31882 feat(bedrock-invoke): enable native structured output for supported Claude models

  • State: open
  • Author: @deepanshululla
  • Labels: llm translation

## Problem

The Bedrock `invoke` path does not support native structured output (`response_format`) for Claude models that have this capability. Callers using `bedrock/anthropic.claude-*` with `response_format` either get an error or fall through to tool-call emulation, even for models that support Anthropic's native `output_format` API via Bedrock.

## Proposed fix

Add `response_format` handling to the Bedrock invoke transformation for Claude models with `supports_output_config: true`. Map `response_format` to the appropriate Anthropic `output_format` field in the Bedrock request body, matching the behavior already present in the direct Anthropic provider path.

## Files

- `litellm/llms/bedrock/` (invoke transformation)

GitHub resolver

Import GitHub neighbors on demand. Results are saved as system ingests.

Refresh page
vote history (3 events)
#0 of 0 · 31d19h1m22s ago — entered · #import:https:::github.com:berriai:litellm post #1849
The Prometheus defect is harder because it requires tracing budget state through spend accounting, persistence, and metric exposition, while resolving edge cases around unset or non-finite values and adding regression coverage. The Bedrock change is comparatively contained to provider request transformation and capability-gated field mapping.
The right issue is harder because it adds provider-specific structured-output support across Bedrock request transformation, model capability detection, compatibility handling, and regression coverage, whereas the left is a localized extraction fix with comparatively limited behavioral scope.
#0 of 0 · 31d18h18m50s ago — current · #import:https:::github.com:berriai:litellm post #2540
The left issue is harder because it crosses proxy request/response lifecycle handling, guardrail enforcement semantics, raw pass-through payload inspection, and likely streaming and regression-test behavior. The right issue is comparatively localized to provider request transformation and capability-gated field mapping.
discussed in #import:https:::github.com:berriai:litellm

ranked child groups

no voted pairs yet in this scope

cli
src
spread
search