Skip to content

fix(interruption): keep the overlap armed when agent speech restarts mid-interrupt #5724

fix(interruption): keep the overlap armed when agent speech restarts mid-interrupt

fix(interruption): keep the overlap armed when agent speech restarts mid-interrupt #5724

Workflow file for this run

# SPDX-FileCopyrightText: 2024 LiveKit, Inc.
#
# SPDX-License-Identifier: Apache-2.0
# Tests run for relevant PRs, including community contributions from forks.
# Credentialed inference tests skip when repository secrets are unavailable.
name: Test
on:
push:
branches: [next, main, 0.x]
pull_request:
branches: [next, main, 0.x]
paths:
- '.github/workflows/test.yml'
- 'agents/**'
- 'package.json'
- 'plugins/test/**'
- 'pnpm-lock.yaml'
- 'pnpm-workspace.yaml'
- 'turbo.json'
jobs:
build:
name: Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
with:
lfs: true
- uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4.3.0
- name: Setup node
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
with:
node-version: 24
cache: pnpm
- name: Install dependencies
run: pnpm install --frozen-lockfile --ignore-scripts
- name: Cache turbo
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
with:
path: .turbo
key: turbo-${{ runner.os }}-node24-${{ hashFiles('pnpm-lock.yaml') }}-${{ github.run_id }}
restore-keys: |
turbo-${{ runner.os }}-node24-${{ hashFiles('pnpm-lock.yaml') }}-
turbo-${{ runner.os }}-node24-
- name: Build
run: pnpm build
- name: Test agents
run: pnpm test agents --silent
- name: Test LiveKit inference
env:
LIVEKIT_INFERENCE_TESTS: '1'
LIVEKIT_URL: ${{ secrets.LIVEKIT_URL }}
LIVEKIT_API_KEY: ${{ secrets.LIVEKIT_API_KEY }}
LIVEKIT_API_SECRET: ${{ secrets.LIVEKIT_API_SECRET }}
run: >-
pnpm test
agents/src/inference/llm.test.ts
agents/src/inference/stt.test.ts
agents/src/inference/tts.test.ts
--silent
# - name: Test examples
# if: (steps.filter.outputs.examples == 'true' || github.event_name == 'push')
# env:
# OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
# run: pnpm test:examples
# TODO (AJS-83) Re-enable once plugins are refactored with abort controllers
# - name: Test all plugins
# if: steps.filter.outputs.agents-or-tests == 'true' || github.event_name != 'pull_request'
# env:
# OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
# ELEVEN_API_KEY: ${{ secrets.ELEVEN_API_KEY }}
# DEEPGRAM_API_KEY: ${{ secrets.DEEPGRAM_API_KEY }}
# CARTESIA_API_KEY: ${{ secrets.CARTESIA_API_KEY }}
# NEUPHONIC_API_KEY: ${{ secrets.NEUPHONIC_API_KEY }}
# RESEMBLE_API_KEY: ${{ secrets.RESEMBLE_API_KEY }}
# run: pnpm test plugins
# - name: Test specific plugins
# if: steps.filter.outputs.agents-or-tests == 'false' && steps.filter.outputs.plugins == 'true' && github.event_name == 'pull_request'
# env:
# OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
# ELEVEN_API_KEY: ${{ secrets.ELEVEN_API_KEY }}
# DEEPGRAM_API_KEY: ${{ secrets.DEEPGRAM_API_KEY }}
# CARTESIA_API_KEY: ${{ secrets.CARTESIA_API_KEY }}
# NEUPHONIC_API_KEY: ${{ secrets.NEUPHONIC_API_KEY }}
# RESEMBLE_API_KEY: ${{ secrets.RESEMBLE_API_KEY }}
# run: |
# plugins=$(git diff-tree --name-only --no-commit-id -r ${{ github.sha }} | grep '^plugins.*\.ts$' | cut -d/ -f2 | sort -u | tr '\n' ' ')
# read -ra plugins <<< "$plugins"
# for plugin in "${plugins[@]}"; do
# pnpm test $plugin
# done