Skip to content

[release/0.7] Accept reasoning.encrypted_content in Responses API include parameter - #3383

Open
dprince wants to merge 1 commit into
lightspeed-core:release/0.7from
dprince:0_7_encrypted_content
Open

dprince wants to merge 1 commit into
lightspeed-core:release/0.7from
dprince:0_7_encrypted_content

Conversation

@dprince

@dprince dprince commented Nov 30, 2026

Copy link
Copy Markdown
Contributor

Allow "reasoning.encrypted_content" in the Responses API IncludeParameter type so requests from OpenAI-compatible clients (such as Goose targeting reasoning-capable models) are no longer rejected with HTTP 422 during Pydantic request validation on POST /v1/responses.

OGX 1.2.5 already includes reasoning.encrypted_content in ogx_api.responses.models.ResponseItemInclude and ogx-client's CreateResponseRequest, and handles it gracefully in create_openai_response() (filtering it out instead of rejecting the request). Adding "reasoning.encrypted_content" directly to IncludeParameter brings lightspeed-stack into parity with OGX 1.2.5 while preserving the existing IncludeParameter OpenAPI schema component name on the 0.7 release branch.

Also regenerates docs/devel_doc/openapi.json, updates the Responses API documentation/model schema, and adds unit tests covering valid and invalid include values on ResponsesRequest.

(cherry picked from commit 34beaca)

Allow "reasoning.encrypted_content" in the Responses API `IncludeParameter`
type so requests from OpenAI-compatible clients (such as Goose targeting
reasoning-capable models) are no longer rejected with HTTP 422 during
Pydantic request validation on POST /v1/responses.

OGX 1.2.5 already includes `reasoning.encrypted_content` in
`ogx_api.responses.models.ResponseItemInclude` and `ogx-client`'s
`CreateResponseRequest`, and handles it gracefully in
`create_openai_response()` (filtering it out instead of rejecting the
request). Adding `"reasoning.encrypted_content"` directly to
`IncludeParameter` brings `lightspeed-stack` into parity with OGX 1.2.5
while preserving the existing `IncludeParameter` OpenAPI schema component
name on the 0.7 release branch.

Also regenerates `docs/devel_doc/openapi.json`, updates the Responses API
documentation/model schema, and adds unit tests covering valid and invalid
`include` values on `ResponsesRequest`.

Signed-off-by: Dan Prince <dprince@redhat.com>
(cherry picked from commit 34beaca)
@coderabbitai

coderabbitai Bot commented Nov 30, 2026 •

Copy link
Copy Markdown
Contributor
Pre-merge checks: Passed 2

Check name Status Explanation
Performance And Algorithmic Complexity Passed PR #3383 (author dprince) changes five files: one line in src/models/common/responses/types.py adds "reasoning.encrypted_content" to the IncludeParameter Literal type. The other changes are an…
Security And Secret Handling Passed PASSED. The PR adds one literal value, "reasoning.encrypted_content", to the IncludeParameter Literal type in src/models/common/responses/types.py (line 66). The other changes are doc updates (docs/…
Full details: Performance And Algorithmic Complexity

Explanation

PR #3383 (author dprince) changes five files: one line in src/models/common/responses/types.py adds "reasoning.encrypted_content" to the IncludeParameter Literal type. The other changes are an OpenAPI/docs regeneration, a docs update, and a parametrized unit test. None of these adds a loop, an API or DB call, a regex compilation, a cache or buffer, or a list operation. The check's five criteria (O(n^2) work, N+1 queries, expensive work in loops, unbounded growth, missing pagination) do not apply to this change. Result: no performance regression is introduced.

Full details: Security And Secret Handling

Explanation

PASSED. The PR adds one literal value, "reasoning.encrypted_content", to the IncludeParameter Literal type in src/models/common/responses/types.py (line 66). The other changes are doc updates (docs/devel_doc/openapi.json, docs/models/requests.json, docs/devel_doc/responses.md) and unit tests (tests/unit/models/requests/test_responses_request.py). I checked the commit diff (HEAD~1..HEAD) against each criterion: 1. Secrets or tokens: none added or logged. The test values are fixed include-option strings, not credentials. 2. Auth/authz: no endpoint, route, or auth dependency changed. POST /v1/responses only gains an accepted enum value. 3. Injection: no SQL, shell, or path handling changed. 4. Sensitive data in responses, WebSocket messages, or logs: no logging or response-construction code changed. 5. K8s/RH secrets and OwnerReferences: no Kubernetes or secret manifests changed. The change widens input validation and does not reduce security controls.

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@dprince dprince changed the title Accept reasoning.encrypted_content in Responses API include parameter [release/0.7]Accept reasoning.encrypted_content in Responses API include parameter Nov 30, 2026
@dprince dprince changed the title [release/0.7]Accept reasoning.encrypted_content in Responses API include parameter [release/0.7] Accept reasoning.encrypted_content in Responses API include parameter Nov 30, 2026

@asimurka asimurka left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@asimurka
asimurka requested a review from tisnik December 1, 2026 12:54

This branch has not been deployed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants