Skip to content

feat(api): support Live sideband Decision commands - #1193

Merged
jbeckwith-oai merged 1 commit into
mainfrom
castiron/promotions/pr-275
Oct 17, 2026
Merged

jbeckwith-oai merged 1 commit into
mainfrom
castiron/promotions/pr-275

Conversation

@yoni-oai

@yoni-oai yoni-oai commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

Live Decision models are already present in the Java baseline, but LiveSidebandConnection has no typed send overloads for the three Decision commands. Add overloads for decision.create, decision.item.create, and decision.item.delete, and regenerate the API-reference input to include three client and three server Decision events in the Live reference groups.

The residual change preserves the generated Java APIs and existing service customizations from openai/openai-java#1213. The generated-file inventory and generated SDK source are unchanged. Regression tests cover sideband transport, omitted list handling, and delegation visitor defaults.

Validation on the promotion source: 15 focused tests passed; the trusted baseline custom-code check passed at 2,021 / 3,000 lines against the verified generated snapshot. See the checks on this PR for hosted results.

@github-actions

github-actions Bot commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

Castiron custom code

Evaluated main: 71916f9f8a456f3055b56b6b12d4334479fdc280.

Trusted main policy: 71916f9f8a456f3055b56b6b12d4334479fdc280.

✅ No new custom-code files detected.

98 mixed files remain; 0 existing customizations changed.

Compared 71916f9f8a45 → 2e5b9b2ae12d. Generated baselines verified.

98 existing customizations unchanged
  • openai-java-core/src/main/kotlin/com/openai/client/OpenAIClientAsyncImpl.kt
  • openai-java-core/src/main/kotlin/com/openai/client/OpenAIClientImpl.kt
  • openai-java-core/src/main/kotlin/com/openai/models/admin/organization/projects/apikeys/ApiKeyUpdateParams.kt
  • openai-java-core/src/main/kotlin/com/openai/models/audio/AudioResponseFormat.kt
  • openai-java-core/src/main/kotlin/com/openai/models/beta/agents/environments/EnvironmentCreateParams.kt
  • openai-java-core/src/main/kotlin/com/openai/models/beta/agents/vaults/credentials/CredentialAuth.kt
  • openai-java-core/src/main/kotlin/com/openai/models/beta/agents/vaults/credentials/CredentialAuthCreateParam.kt
  • openai-java-core/src/main/kotlin/com/openai/models/beta/agents/vaults/credentials/CredentialAuthRotateParam.kt
  • openai-java-core/src/main/kotlin/com/openai/models/beta/responses/BetaResponse.kt
  • openai-java-core/src/main/kotlin/com/openai/models/beta/responses/BetaResponseError.kt
  • openai-java-core/src/main/kotlin/com/openai/models/beta/responses/BetaResponseInjectEvent.kt
  • openai-java-core/src/main/kotlin/com/openai/models/beta/responses/BetaResponseInjectFailedEvent.kt
  • openai-java-core/src/main/kotlin/com/openai/models/beta/responses/BetaResponseStreamEvent.kt
  • openai-java-core/src/main/kotlin/com/openai/models/beta/responses/BetaResponseToolSearchOutputItemParam.kt
  • openai-java-core/src/main/kotlin/com/openai/models/beta/responses/BetaResponsesServerEvent.kt
  • openai-java-core/src/main/kotlin/com/openai/models/chat/completions/ChatCompletionCreateParams.kt
  • openai-java-core/src/main/kotlin/com/openai/models/chat/completions/ChatCompletionMessageFunctionToolCall.kt
  • openai-java-core/src/main/kotlin/com/openai/models/chat/completions/ChatCompletionToolMessageParam.kt
  • openai-java-core/src/main/kotlin/com/openai/models/conversations/ConversationCreateParams.kt
  • openai-java-core/src/main/kotlin/com/openai/models/conversations/items/ItemCreateParams.kt
  • openai-java-core/src/main/kotlin/com/openai/models/embeddings/Embedding.kt
  • openai-java-core/src/main/kotlin/com/openai/models/embeddings/EmbeddingCreateParams.kt
  • openai-java-core/src/main/kotlin/com/openai/models/live/ResponseItemCreateEvent.kt
  • openai-java-core/src/main/kotlin/com/openai/models/realtime/RealtimeResponseStatus.kt
  • openai-java-core/src/main/kotlin/com/openai/models/responses/Response.kt
  • openai-java-core/src/main/kotlin/com/openai/models/responses/ResponseCreateParams.kt
  • openai-java-core/src/main/kotlin/com/openai/models/responses/ResponseError.kt
  • openai-java-core/src/main/kotlin/com/openai/models/responses/ResponseFunctionToolCall.kt
  • openai-java-core/src/main/kotlin/com/openai/models/responses/ResponseFunctionWebSearch.kt
  • openai-java-core/src/main/kotlin/com/openai/models/responses/ResponseInputItem.kt
  • openai-java-core/src/main/kotlin/com/openai/models/responses/ResponseStreamEvent.kt
  • openai-java-core/src/main/kotlin/com/openai/models/responses/ResponseTextConfig.kt
  • openai-java-core/src/main/kotlin/com/openai/models/responses/ResponseToolSearchOutputItemParam.kt
  • openai-java-core/src/main/kotlin/com/openai/models/responses/ResponsesServerEvent.kt
  • openai-java-core/src/main/kotlin/com/openai/models/videos/Video.kt
  • openai-java-core/src/main/kotlin/com/openai/models/videos/VideoCreateError.kt
  • openai-java-core/src/main/kotlin/com/openai/models/webhooks/UnwrapWebhookEvent.kt
  • openai-java-core/src/main/kotlin/com/openai/models/webhooks/WebhookEndpointWithSecret.kt
  • openai-java-core/src/main/kotlin/com/openai/services/async/BetaServiceAsync.kt
  • openai-java-core/src/main/kotlin/com/openai/services/async/BetaServiceAsyncImpl.kt

58 more in the full report.

A changed generated baseline means this report cannot reliably identify which handwritten lines changed.

Inspect the custom-code diff

Download the exact patch produced by this run (requires repository access):

gh run download 39023795984 --repo openai/openai-java \
  --name castiron-custom-code-39023795984-1 --dir /tmp/castiron-custom-code-39023795984-1
git apply --stat /tmp/castiron-custom-code-39023795984-1/custom-code.patch
cat /tmp/castiron-custom-code-39023795984-1/custom-code.patch

Or reproduce it from an SDK checkout containing the vendored reporter:

git fetch --no-tags origin 71916f9f8a456f3055b56b6b12d4334479fdc280 2e5b9b2ae12d4e89513fd6c99b9c7031dde01f4c
python3 scripts/castiron/custom_code_report.py report \
  --base 71916f9f8a456f3055b56b6b12d4334479fdc280 \
  --head 2e5b9b2ae12d4e89513fd6c99b9c7031dde01f4c --fetch --require-head-hash --public \
  --out /tmp/castiron-custom-code-2e5b9b2ae12d
cat /tmp/castiron-custom-code-2e5b9b2ae12d/custom-code.patch

This is the current full custom patch for mixed files, not an attribution of only the handwritten lines changed by this PR.

Full report and patch

@yoni-oai
yoni-oai marked this pull request as ready for review October 16, 2026 06:17
@yoni-oai
yoni-oai requested a review from a team as a code owner October 16, 2026 06:17
@openai-sdks

openai-sdks Bot commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

OkTest Summary

✅ 236/236 SDK tests passed in 14.529s for Java SDK PR #1193.

Test results — 42 files
Test Result Time
tests/chat-completions-complex-body.test.ts ✅ Passed 171ms
tests/chat-completions-create.test.ts ✅ Passed 626ms
tests/chat-completions-stream.test.ts ✅ Passed 839ms
tests/files-content-binary.test.ts ✅ Passed 256ms
tests/files-create-multipart.test.ts ✅ Passed 312ms
tests/files-list-pagination.test.ts ✅ Passed 212ms
tests/initialize-config.test.ts ✅ Passed 156ms
tests/instance-isolation.test.ts ✅ Passed 190ms
tests/models-list.test.ts ✅ Passed 289ms
tests/responses-background-lifecycle.test.ts ✅ Passed 718ms
tests/responses-body-method-errors.test.ts ✅ Passed 482ms
tests/responses-cancel-timeout.test.ts ✅ Passed 265ms
tests/responses-cancel.test.ts ✅ Passed 292ms
tests/responses-compact-retries.test.ts ✅ Passed 388ms
tests/responses-compact.test.ts ✅ Passed 312ms
tests/responses-create-advanced-stream.test.ts ✅ Passed 324ms
tests/responses-create-advanced.test.ts ✅ Passed 1.194s
tests/responses-create-disconnect.test.ts ✅ Passed 1.138s
tests/responses-create-errors.test.ts ✅ Passed 306ms
tests/responses-create-malformed-api-responses.test.ts ✅ Passed 252ms
tests/responses-create-retries.test.ts ✅ Passed 286ms
tests/responses-create-stream-failures.test.ts ✅ Passed 249ms
tests/responses-create-stream-timeout.test.ts ✅ Passed 235ms
tests/responses-create-stream-wire.test.ts ✅ Passed 4.857s
tests/responses-create-stream.test.ts ✅ Passed 382ms
tests/responses-create-terminal-states.test.ts ✅ Passed 310ms
tests/responses-create-timeout.test.ts ✅ Passed 267ms
tests/responses-create.test.ts ✅ Passed 235ms
tests/responses-delete.test.ts ✅ Passed 298ms
tests/responses-input-items-errors.test.ts ✅ Passed 290ms
tests/responses-input-items-list.test.ts ✅ Passed 379ms
tests/responses-input-items-options.test.ts ✅ Passed 317ms
tests/responses-input-tokens-count-timeout.test.ts ✅ Passed 248ms
tests/responses-input-tokens-count.test.ts ✅ Passed 527ms
tests/responses-malformed-inputs.test.ts ✅ Passed 3.618s
tests/responses-not-found-errors.test.ts ✅ Passed 349ms
tests/responses-parse.test.ts ✅ Passed 673ms
tests/responses-retrieve-retries.test.ts ✅ Passed 381ms
tests/responses-retrieve.test.ts ✅ Passed 353ms
tests/responses-stored-method-errors.test.ts ✅ Passed 964ms
tests/retry-behavior.test.ts ✅ Passed 3.588s
tests/sdk-error-shape.test.ts ✅ Passed 452ms

View OkTest run #39023733627

SDK merge (746618611f10) · head (2e5b9b2ae12d) · base (71916f9f8a45) · OkTest (97bd22b95c45)

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-17T10:09:54.840531Z 2e5b9b2 New commits
🔒 Security Review ✅ Completed 2026-10-17T10:11:04.032590Z 2e5b9b2 New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@dpiet-oai dpiet-oai 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.

The generated public visitor surface has one blocking compatibility regression; see the inline finding.

Comment thread openai-java-core/src/main/kotlin/com/openai/models/live/SessionConfig.kt Outdated

@jbeckwith-oai jbeckwith-oai 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.

Reviewed 9f3b319febfd3b283b8b0da9fe9668428a8a7c76 against 812a4fb74885f69b130c82d024f44541f73b8f5e.

One compatibility issue needs fixing: the new Decisions branch adds an abstract method to five existing public Delegation.Visitor interfaces. Existing client/responses visitors consequently stop compiling on an SDK upgrade, even when the application does not use Decisions. I independently confirmed the same regression that Dan posted during this review: #1193 (comment). Please use the existing finding to track the fix; I am not adding a duplicate inline comment.

I checked the schema/model mapping, nullable correlation IDs, native Decision payload, trigger omission versus empty-list handling, normal/fork event dispatch, typed sideband overloads, generated metadata, and test changes. The manual transport change delegates to the existing send path. No other actionable issue found.

Static review only; no candidate code, tests, builds, or generation were executed locally. git diff --check passed. Hosted build, lint, Jackson/API/runtime compatibility, and Castiron checks are successful at this head; the main test job and OkTest are still running.

@markstuart-oai markstuart-oai 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.

Reviewed all 53 changed files at 9f3b319febfd3b283b8b0da9fe9668428a8a7c76 against 812a4fb74885f69b130c82d024f44541f73b8f5e. I found two compatibility defects that need fixes: existing delegation visitors gain an abstract method, and copied configs with omitted trigger or question lists throw on the first append. Dan has already reported the visitor issue in #1193 (comment); I independently confirmed it and am using that thread to track the fix. The distinct copied-list issue and its regression cases are inline.

The event unions and sideband overloads otherwise preserve the existing transport and unknown-event behavior. The new tests cover populated models and wire roundtrips, but miss the two cases above. I accepted the larger model/test files because their nested schema types and per-variant tests remain clearly separated; an extra runtime abstraction is not warranted.

Validation: immutable source and blob-identity review, including an independent full-diff pass. I did not execute the candidate. Hosted build, lint, Jackson, API compatibility, Java 8/25 runtime compatibility, and Castiron checks passed at the final check; the main tests and OkTest were still running. Those passing checks do not cover the two demonstrated source paths.

@yoni-oai
yoni-oai force-pushed the castiron/promotions/pr-275 branch 2 times, most recently from 8f16f07 to 098e21d Compare October 16, 2026 20:40

@markstuart-oai markstuart-oai 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.

Reviewed 098e21d9c50f9fe77b450b946e3342955bffec60. The five delegation visitor defaults and six copied-list corrections fix the earlier findings. One compatibility issue remains: SidebandClientEvent.Visitor adds three abstract Decision methods, which breaks existing visitor implementations. I left one inline finding for that interface.

I reconciled the 59-file scope against the earlier review, checked the changed source and regression tests, and verified the generated checkpoint and disclosed customizations. Seventeen hosted checks passed and two skipped; the separate OkTest status still reports running. I did not execute candidate code or independently run the author's compiled-consumer probe.

@jbeckwith-oai jbeckwith-oai 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.

Re-reviewed 098e21d9c50f9fe77b450b946e3342955bffec60. The five delegation visitor defaults fix my earlier finding, and the six copied-list corrections correctly distinguish omission from explicit null/malformed values.

One P2 compatibility issue remains: SidebandClientEvent.Visitor gains three abstract Decision methods. Existing visitors implementing the prior ten variants stop compiling after an upgrade; previously compiled visitors can hit AbstractMethodError when a new variant is dispatched. I independently verified Mark's existing finding at #1193 (comment) and am using that thread rather than adding a duplicate. Please give those three methods the established unknown(JsonValue.from(...)) defaults and extend the old-visitor regression to this interface.

Coverage: reconciled all 59 changed paths with the prior review, reused 43 identical blobs, and inspected the 16 changed/new paths and relevant current-base context. The sideband send overloads preserve the existing transport. The six documented list customizations are the only current changed generated sources differing from their manifest hashes. git diff --check passed; GitHub's current-head checks and Castiron statuses are green. Static review only: I did not run candidate code, tests, builds, generation, or the author's compiled-consumer probe.

@yoni-oai
yoni-oai force-pushed the castiron/promotions/pr-275 branch from 098e21d to daaf0c2 Compare October 17, 2026 04:18

@markstuart-oai markstuart-oai 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.

Re-reviewed daaf0c293e893b298492a49a87e99d3d85db0fbd. The earlier compatibility findings are fixed: all six affected visitor interfaces retain their existing signatures and route unhandled typed variants through unknown, including the three new sideband Decision methods. The JVM-default setting is unchanged, and the new sideband regression checks the legacy visitor shape and default methods. The documented loss of compile-time exhaustiveness is the tradeoff for that fallback behavior.

I reconciled all 180 changed paths. The broader generated-list change preserves existing guards and changes only missing-list handling; explicit null and malformed values still fail on append. The sideband overloads keep the existing transport path. The generated manifest, remaining customizations, schema changes, and regression tests are consistent. No actionable findings.

All 17 current-head repository checks passed; two queue signals were skipped. This includes SDK tests, API/Jackson/runtime compatibility, and Castiron baseline and budget checks. The separate OkTest run is still running. I reviewed immutable source and hosted results without executing candidate code or independently running the author's precompiled-consumer probe.

@yoni-oai
yoni-oai force-pushed the castiron/promotions/pr-275 branch from daaf0c2 to 78f9326 Compare October 17, 2026 04:51
@yoni-oai
yoni-oai force-pushed the castiron/promotions/pr-275 branch from 78f9326 to 0747a5c Compare October 17, 2026 06:40

@jbeckwith-oai jbeckwith-oai 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.

Re-reviewed the compatibility findings on 0747a5c17268fa366487526a34ab807e8bac1de7; the previously requested changes are addressed.

The five delegation visitors and all three new SidebandClientEvent visitor callbacks now default to unknown(JsonValue.from(...)). The regression tests retain the old visitor implementation shape and assert JVM default methods. The copied-list append path initializes omitted values while preserving omission on an untouched copy; explicit null and malformed values still fail, with focused regression coverage.

I compared this head with Mark's approved daaf0c2: the Live models, helper and regression tests are byte-for-byte unchanged. The intervening baseline/model notices are retained. This is a static follow-up review; I did not rerun the tests locally. Hosted CI on the fresh head is still running and remains a merge gate. No remaining findings from my earlier reviews.

Castiron-Internal-PR: openai/openai-java-internal#275
Castiron-Source-SHA: 081bde9862a8522787beec632c71662ff19bce03
Castiron-Public-Base-SHA: 71916f9
@yoni-oai
yoni-oai force-pushed the castiron/promotions/pr-275 branch from 0747a5c to 2e5b9b2 Compare October 17, 2026 10:07
@yoni-oai yoni-oai changed the title feat(api): support Decisions in Live sessions feat(api): support Live sideband Decision commands Oct 17, 2026
@jbeckwith-oai
jbeckwith-oai added this pull request to the merge queue Oct 17, 2026

@jbeckwith-oai jbeckwith-oai 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.

Reviewed the narrowed six-file change at 2e5b9b2ae12d4e89513fd6c99b9c7031dde01f4c against current main 71916f9. The remaining production change is three typed sideband send overloads delegating through the existing sendCommand path; the transport test verifies all three wire messages and a nullable-correlated Decision result. The other changes are the six API-navigation entries, generation metadata, and visitor/copied-list regression tests. No remaining findings. Current-head hosted CI is green and all review threads are resolved. Static review; I did not rerun the tests locally.

Merged via the queue into main with commit 690835d Oct 17, 2026
19 checks passed
@openai-sdks openai-sdks Bot mentioned this pull request Oct 17, 2026
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.

4 participants