configureModuleSpeech (configurations/module-speech.ts)

airi · packages/testing-audio/cases/shared/configurations/module-speech.ts · typescript · MIT
voice

Configures speech module runtime by resolving provider, voice, and storage settings for a given context.

// Source: https://github.com/moeru-ai/airi | License: MIT | Copyright 2024-PRESENT Neko Ayaka
// Provided via justclaw.it.com; keep this notice with the code.
import type { AudioInputPreflightCallback, AudioInputPreflightContext } from '../../../src/types'
import type { ProviderConfiguration } from './provider'

import { configureActiveCardModules } from './active-card'
import { configureProvider } from './provider'
import { configureStorage } from './storage'

export interface SpeechModuleConfiguration {
  /** @default false */
  muted?: boolean
  provider: ProviderConfiguration
  voice: string
}

type SpeechModuleResolver = (context: AudioInputPreflightContext) => SpeechModuleConfiguration | undefined | Promise<SpeechModuleConfiguration | undefined>

/** Configures the speech module wit

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search for more like it.

Get a free API key