Skip to content

feat(regen): add think live and flux tts support - #134

Open
GregHolmes wants to merge 7 commits into
mainfrom
gh/sdk-gen-2026-10-23-2
Open

GregHolmes wants to merge 7 commits into
mainfrom
gh/sdk-gen-2026-10-23-2

Conversation

@GregHolmes

@GregHolmes GregHolmes commented Oct 23, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Regenerated the Java SDK from the Conversational Flux TTS API specs.
  • Adds Agent Think Live settings, runtime updates, conversational message behavior, dynamic agent injection, typed Think Live / frustration events, and Think Live function-filler controls.
  • Adds a runnable Think Live Agent example and MockWebServer coverage for initial settings, function fillers, outbound controls, typed events, and unknown-frame compatibility.
  • Preserves legacy onError delivery for unknown Agent frames when no raw handler is registered; callers that register onMessage(...) receive future frames without a false fatal error.
  • Reapplies all existing manual compatibility, WebSocket, hashCode, union-default, and model-catalog patches; Fern does not yet cover any of them.
  • Preserves binary compatibility for existing AgentV1ConversationText builder implementations and adds the AgentV1ThinkLiveUpdated hash-code contract patch.
  • Deletes all transient .bak files.

Release

  • feat(regen): add Agent Think Live controls ensures Release Please includes the new public API in its release notes.
  • No versions were bumped; Release Please owns the next version change.

Validation

  • ./gradlew spotlessCheck test compileExamples
  • Production Think Live smoke passed initial settings, runtime updates, and dynamic injection.

@GregHolmes GregHolmes changed the title chore: sdk regeneration 2026-10-23-2 feat(regen): add Agent Think Live controls Oct 23, 2026
@GregHolmes GregHolmes changed the title feat(regen): add Agent Think Live controls feat(regen): add think live and flux tts support Oct 26, 2026

@dg-coreylweathers dg-coreylweathers 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.

What this PR does: Regenerates the Java SDK from deepgram-docs #1283 (Think Live) and adds thinkLive settings, sendUpdateThinkLive, sendInjectDynamicAgentMessage, typed onThinkLiveUpdated and onFrustrationDetected handlers, a runnable ThinkLiveAgent example, and MockWebServer wire tests, with three new frozen patches.

Approved. Hold merge until deepgram-docs #1283 merges. The worth-fixing items are in a follow-up comment below.

What I checked:

  • Does it break existing code? No. conversationalBehavior is Optional, the new _FinalStage methods are default no-ops (RegenTypesTest asserts it), and no frozen file lost a patch.
  • Does it work against production? Yes. runExample -PmainClass=ThinkLiveAgent in Docker printed settings applied, configuration updated (ThinkLiveUpdated), and the greeting ConversationText.
  • Is Think Live live in production? Yes, under the new names only. Production rejects think_conversational; staging still accepts only the old names.
  • Gate: spotlessCheck compileJava compileExamples test BUILD SUCCESSFUL in Docker (Temurin 17).

@dg-coreylweathers

Copy link
Copy Markdown
Contributor

@GregHolmes follow-ups from the review, none blocking:

  • examples/agent/ThinkLiveAgent.java:59: add wsClient.onWarning(w -> System.out.println("Agent warning: " + w));. Today the server answers the dynamic inject with a DYNAMIC_FILLER_UNAVAILABLE warning and the example prints nothing after "requesting a dynamic response."
  • The example ends with a RejectedExecutionException from ReconnectingWebSocketListener.scheduleReconnect (:442) because disconnect() shuts the executor before OkHttp's onClosed fires. Pre-existing SDK bug, but the new example shows it to everyone. In the example, call wsClient.reconnectOptions(ReconnectingWebSocketListener.ReconnectOptions.builder().maxRetries(0).build()) before connect(); in the SDK, guard scheduleReconnect with isShutdown().
  • src/test/java/com/deepgram/AgentV1ThinkLiveWireTest.java:265-275: the latch is released in onMessage, which runs before dispatch, so a regression that fires onError late still passes. Count the latch from both handlers or assert after a second known frame arrives.
  • V1WebSocketClient.java:972: with onMessage registered, any frame that fails typed parsing is now silent, not only truly unknown types. Fine as designed, but say it in the release notes.
  • Nits: the example is not linked from README or the voice-agent skill; the PR body says "Conversational Flux TTS API specs".

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