Skip to content

feat: Add history config to live connections#1118

Open
arnabnandy7 wants to merge 1 commit into
googleapis:mainfrom
arnabnandy7:fix/live-connect-history
Open

feat: Add history config to live connections#1118
arnabnandy7 wants to merge 1 commit into
googleapis:mainfrom
arnabnandy7:fix/live-connect-history

Conversation

@arnabnandy7

Copy link
Copy Markdown

Summary

Adds historyConfig support to LiveConnectConfig, enabling Java users to seed conversation history in Gemini 3.1 Live sessions.

Fixes #974.

Root cause

HistoryConfig was available on the wire-level LiveClientSetup, but it was not exposed through the public LiveConnectConfig accepted by AsyncLive.connect. Consequently, callers could not enable initial history processing.

Changes

  • Expose historyConfig through LiveConnectConfig and its builder.
  • Map the configuration to setup.historyConfig for both Gemini Developer API and Vertex AI.
  • Add regression tests for both backend conversion paths.
  • Update native-image reflection metadata.
  • Document Gemini 3.1 Live history seeding in the README.

Validation

  • mvn compile -DskipTests -Djacoco.skip=true
  • Checkstyle passes with zero violations.
  • Native-image reflection JSON files parse successfully.
  • git diff --check passes.
  • Tests compile successfully. Local execution is blocked by the existing Mockito configuration not supporting the installed JDK 26; use a repository-supported JDK such as JDK 21.

Signed-off-by: Arnab Nandy <arnab_nandy7@yahoo.com>
@hemasekhar-p hemasekhar-p self-assigned this Jul 20, 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.

LiveConnectConfig missing historyConfig for Gemini Live 3.1

2 participants