-
-
Notifications
You must be signed in to change notification settings - Fork 413
[FEATURE] Add Bedrock structured output support #620
Copy link
Copy link
Closed as duplicate of#596
Labels
enhancementNew feature or requestNew feature or request
Description
Scope check
- This is core LLM communication (not application logic)
- This benefits most users (not just my use case)
- This can't be solved in application code with current RubyLLM
- I read the Contributing Guide
Due diligence
- I searched existing issues
- I checked the documentation
What problem does this solve?
#608 adds structured output support for the direct Anthropic API. Bedrock's Converse API also supports structured output but uses a different payload format — the schema must be stringified JSON nested under outputConfig.textFormat.structure.jsonSchema. Currently with_schema is not wired up for the Bedrock provider.
Proposed solution
Wire outputConfig into Bedrock's render_payload when a schema is provided, add supports_structured_output? to Bedrock model capability detection (Claude 4.5+), and add unit and integration tests with a VCR cassette.
Why this belongs in RubyLLM
Consistent support for structured outputs across providers — Bedrock is a core provider that should have parity with the direct Anthropic API.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request