Tech Wiki

Gemini 3.8 Live quickstart: build voice agents that keep talking while tools run

Official Gemini 3.8 Live image illustrating real-time voice responses and background tool calls

Google released Gemini 3.8 Live and Gemini 3.8 Live Extended Thinking on September 15, 2026. Both handle real-time voice conversations, but they solve different problems. The standard model targets quick turn-taking and fast tools. Extended Thinking is built for requests that need several reasoning steps or tools that take seconds to finish.

A voice agent no longer has to sit silent while a slow function runs. Extended Thinking can send an intermediate spoken update such as “Checking flight options now” while it reasons and calls asynchronous tools in the background. That makes it useful for travel search, technical support, and tutoring flows where one request triggers several operations.

Key facts

  • gemini-3.8-live is the simpler choice for direct commands, short conversations, and fast tools.
  • gemini-3.8-live-extended-thinking handles multi-step reasoning and long-running tools in the background.
  • Both use the stateful WebSocket-based Live API. Audio input is 16kHz PCM and audio output is 24kHz PCM.
  • Google’s estimated audio price is $0.005 per minute of input and $0.018 per minute of output. Actual billing depends on token usage.
  • Browser clients should use ephemeral tokens rather than expose a standard API key.

Standard Live and Extended Thinking are not drop-in equivalents

A standard gemini-3.8-live turn has a familiar shape: the user speaks, the model responds, and turnComplete: true tells the client that the session can return to its listening state. This is a good fit for voice search, sensor reads, or device controls where an external function returns in milliseconds.

Extended Thinking can speak more than once during the same request. An intermediate update may arrive with turnComplete: true even though reasoning and tool execution are still underway. The client must also read interactionStatus. Keep the UI in a processing state while it is IN_PROGRESS, and accept the next user turn only after it becomes IDLE.

Tool declarations change too. Standard Live accepts both BLOCKING and NON_BLOCKING tools. Extended Thinking requires every function declaration to use NON_BLOCKING; a synchronous blocking declaration produces an error. Its reasoning depth can be set to low, medium, or high. MINIMAL is not supported.

How to choose the model

Start with standard Live when response latency matters most and each function returns quickly. It keeps the client state machine small and avoids adding background reasoning to a direct interaction.

Extended Thinking fits log-based technical support, travel agents that query flights and hotels, and tutors that need to verify a formula or debug code before answering. It can cover tool latency with spoken progress updates, but your client has to manage asynchronous responses and lifecycle state correctly.

Decision point Gemini 3.8 Live Extended Thinking
Best for Short dialogue, direct commands, fast tools Multi-step work, several tools, slower functions
Completion signal turnComplete interactionStatus: IDLE
Tool behavior BLOCKING or NON_BLOCKING NON_BLOCKING only
Reasoning control No thinking_level low, medium, or high

Quickstart

You need a Gemini API key and the Google GenAI JavaScript SDK.

npm install @google/genai

Pass the API key through an environment variable. Do not commit it to the repository.

export GEMINI_API_KEY="your-api-key"

The following example configures an Extended Thinking session with one asynchronous function and low reasoning depth. A production application still needs microphone capture, 24kHz PCM playback, the function implementation, and connection cleanup.

import { GoogleGenAI, Modality } from '@google/genai';

const ai = new GoogleGenAI({ apiKey: process.env.GEMINI_API_KEY });
const model = 'gemini-3.8-live-extended-thinking';

const searchFlights = {
  name: 'search_flights',
  description: 'Searches for available flights to a destination.',
  behavior: 'NON_BLOCKING',
  parameters: {
    type: 'OBJECT',
    properties: {
      destination: { type: 'STRING' },
    },
    required: ['destination'],
  },
};

const config = {
  responseModalities: [Modality.AUDIO],
  thinkingConfig: {
    thinkingLevel: 'low',
  },
  tools: [{ functionDeclarations: [searchFlights] }],
};

const session = await ai.live.connect({
  model,
  config,
  callbacks: {
    onopen: () => console.log('Session connected'),
    onmessage: (message) => {
      if (message.interactionStatus === 'IN_PROGRESS') {
        console.log('Reasoning or executing tools');
      }

      if (message.interactionStatus === 'IDLE') {
        console.log('Ready for the next input');
      }
    },
  },
});

process.on('SIGINT', () => session.close());

This configuration follows Google’s official SDK example and passes the Node.js syntax check. It was not connected to a live Gemini session because API credentials were not available in the test environment.

Session limits and reconnection

A Live API connection and a logical session do not have the same lifetime. Without context window compression, an audio-only session is limited to 15 minutes and an audio-video session to 2 minutes. The WebSocket connection itself can end after roughly 10 minutes.

Long conversations need two separate mechanisms. A sliding contextWindowCompression configuration compresses earlier context as the window fills. sessionResumption lets the application store the handle sent by the server and pass it to a new connection. Resumption tokens remain valid for 2 hours after the last session ends. Applications should also handle the server’s GoAway message before the connection closes.

Price, requirements, and compatibility

Google estimates audio input at $0.005 per minute and audio output at $0.018 per minute. The footnote to that estimate uses rates of $3 per million input tokens and $12 per million output tokens, so real cost varies with the conversation and generated audio.

The Live API supports server-to-server WebSocket connections and direct browser connections. Going directly from a browser can reduce latency by removing a proxy hop, but production clients should authenticate with ephemeral tokens. Google also documents integration paths for LiveKit, Pipecat, Fishjam, Vision Agents, Voximplant, Agora, and the Firebase AI SDK. The model announcement lists visual input and coverage for more than 97 languages.

Limitations

Lifecycle handling is the first trap. Treating every Extended Thinking turnComplete as the end of the whole request can return the interface to its listening state while tools are still running. The state machine should use interactionStatus as its final completion signal.

Google’s documentation labels the Live API as Preview. Recheck model names, message fields, limits, and connection behavior before a production launch. End-to-end latency and speech quality also depend on the network, audio buffering, and tool response time. The feature list alone does not predict production performance.

Where it fits

Extended Thinking is worth testing if a voice interface already suffers from awkward silence during tool calls. Standard Live remains the better default for short queries and direct commands because it is easier to integrate and operate. If the product only needs speech-to-text, a dedicated transcription model such as Gemini 3.5 Transcribe is a more direct fit than a conversational Live model.

A sensible rollout starts with one fast function on standard Live. Add Extended Thinking only where the workflow genuinely needs multi-step reasoning or slow tools. The useful decision point is measured tool latency and client complexity, not the fact that one model is newer.

Sources

Verified: September 17, 2026


답글 남기기

이메일 주소는 공개되지 않습니다. 필수 필드는 *로 표시됩니다

Tech Wiki

Built with WordPress · Learn in public.