Skip to main content
The hang event is triggered when the assistant fails to respond for 5+ seconds during a conversation. This indicates potential issues with LLM processing, connectivity, or system overload.
Hang events signal critical performance problems that can lead to poor user experience and call abandonment. Immediate investigation is recommended.

When It’s Triggered

This event is sent when:
  • The assistant takes longer than 5 seconds to generate a response
  • LLM API calls experience high latency or timeouts
  • System processing queues become backlogged
  • Network connectivity issues affect response generation

Event Structure

Key Fields

Call Object

The call object contains comprehensive information about the call session.

Assistant Object

The assistant object contains the configuration and settings of the assistant handling the call.
In some webhook events, the assistant object may be truncated for brevity. The full assistant configuration is typically included in status-update events.

Key Subobjects

  • assistantAnalysis: Contains settings for summary generation, success evaluation, and structured data extraction
  • assistantServer: The webhook configuration that triggered this event
  • config.speech: STT/TTS vendor settings, voice configuration, and language options

Messages Object

The messages array contains the conversation history between the user and assistant.
Each conversation-update event includes all messages from the start of the call up to that point, not just the latest message. This ensures that if any individual event is missed, you still have the complete conversation context.

Message Structure

Message Metrics

Each message includes detailed performance metrics:

Timeline Metrics

  • totalElapsedTimeMs: Total time since call start
  • offsetFromPreviousTurnMs: Time gap from previous message

Audio Metrics

  • totalAudioReceivedMs: Total audio duration received
  • audioDelayPerTurnMs: Audio processing delay for this turn
  • delayedPacketsPerTurnCount: Count of delayed network packets

Speech-to-Text (STT) Metrics

  • timestampMs: When transcription was completed
  • startOffsetMs/endOffsetMs: Audio segment boundaries
  • confidence: Transcription confidence score (0.0 to 1.0)
  • vadMs: Voice activity detection duration

Text-to-Speech (TTS) Metrics

  • audioDurationMs: Duration of generated audio
  • generationTimeMs: Time to generate audio
  • queueLatencyMs: Processing queue delay
  • isCachePlaying: Whether audio was served from cache

LLM Metrics

  • responseLatencyMs: Time for LLM to generate response
  • queueLatencyMs: Processing queue delay

Message Types

  • Welcome Messages: Have messageId starting with “welcome-”
  • User Messages: Have messageId starting with “user-”
  • Assistant Messages: Have complex messageId with user reference and timestamp

Hang Detection Logic

Example Payload

Common Causes

LLM Provider Issues

  • API rate limiting or throttling
  • Provider service outages or degraded performance
  • Model capacity limitations during peak hours
  • Authentication or billing issues

System Resource Constraints

  • High CPU or memory usage on Interactly servers
  • Processing queue backlog
  • Database connection limitations
  • Network bandwidth constraints

Complex Queries

  • User requests requiring extensive reasoning
  • Long conversation context requiring more processing time
  • Queries that trigger multiple LLM function calls
  • Malformed or problematic user input

Response Strategies

Immediate Alerting

Performance Monitoring

Automated Remediation

Pattern Analysis

User Experience Impact

Hang events directly affect user experience:

User Behavior During Hangs

  • Users may repeat their question
  • Users might hang up if wait is too long
  • Users experience frustration and reduced trust
  • Call abandonment rate increases significantly

Mitigation Strategies

Prevention Best Practices

Assistant Configuration

Monitoring Thresholds

Load Balancing

Recovery Actions

When hang events occur:
  1. Monitor: Track if response eventually comes through
  2. Alert: Notify engineering team for investigation
  3. Document: Record context for post-incident analysis
  4. Optimize: Adjust assistant settings to prevent recurrence
  5. Communicate: Update users about potential temporary delays

Related Events

Hang events often precede error events if the underlying issue persists

Hang Event Example

This is a complete example of a hang webhook event payload.

Context

This hang event occurred after a user made a complex request that required significant LLM processing time. The assistant failed to respond within the 5-second threshold, triggering the hang event. The system continued processing the request and may eventually deliver a response or trigger an error event if processing ultimately fails.