For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Start buildingGet support
DocumentationAPI ReferenceChangelogDiscord
  • Introduction
    • Welcome to Hume AI
    • Getting your API keys
    • Support
    • Pricing
  • Voice
    • Overview
    • Voice design
    • Voice cloning
    • Voice management
  • Text-to-Speech (TTS)
    • Overview
    • Voice
    • Acting instructions
    • Voice conversion
    • Continuation
    • Timestamps
    • FAQ
  • Speech-to-Speech (EVI)
    • Overview
      • Interruptibility
      • Pause responses
      • Dynamic variables
      • Context injection
      • Tool use
      • Resume chats
      • Chat history
      • Audio reconstruction
    • FAQ
  • Expression Measurement
    • Overview
    • About the science
    • FAQ
  • Integrations
    • MCP
    • Vercel AI SDK
    • LiveKit
    • Pipecat
    • Vapi
    • Twilio
    • Agora
  • Resources
    • Terms of use
    • Use case guidelines
    • Billing
    • Errors
    • Privacy
    • Status
Start buildingGet support
LogoLogo
LogoLogo
On this page
  • Resuming a chat
Speech-to-Speech (EVI)Features

Resuming Chats

Guide to preserving context from previous Chat sessions.
Was this page helpful?
Edit this page
Previous

Chat History

Guide to accessing chat history with the EVI.
Next
Built with

EVI supports reconnecting to an ongoing chat session, preserving all prior conversation context. This is especially useful in cases of unexpected network failures or when a user wishes to pick up the conversation at a later time, enabling continuity without losing progress.

If data retention is disabled, the ability to resume chats will not be supported.

Resuming a chat

See steps below for how to resume a chat:

  1. Establish initial connection: Make the initial handshake request to establish the WebSocket connection. Upon successful connection, you will receive a ChatMetadata message:

    Chat metadata
    1{
    2 "type": "chat_metadata",
    3 "chat_group_id": "8859a139-d98a-4e2f-af54-9dd66d8c96e1",
    4 "chat_id": "2c3a8636-2dde-47f1-8f9e-cea27791fd2e"
    5}
  2. Store the ChatGroup reference: Save the chat_group_id from the ChatMetadata message for future use.

  3. Resume chat: To resume a chat, include the stored chat_group_id in the resumed_chat_group_id query parameter of subsequent handshake requests.

    1"use client";
    2import { VoiceProvider } from "@humeai/voice-react";
    3
    4export default function ClientComponent({
    5 accessToken,
    6}: {
    7 accessToken: string;
    8}) {
    9 return (
    10 <VoiceProvider
    11 auth={{ type: "accessToken", value: accessToken }}
    12 resumedChatGroupId='<YOUR_CHAT_GROUP_ID>'
    13 >
    14 // ...etc.
    15 </VoiceProvider>
    16 );
    17}

    When resuming a chat, you can specify a different EVI configuration than the one used in the previous session. However, changing the system prompt or supplemental LLM may result in unexpected behavior from EVI.