@livekit/agents-plugin-elevenlabs 0.6.1 → 0.6.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2 @@
1
+ export * from './tts.js';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1,3 @@
1
+ export type TTSModels = 'eleven_monolingual_v1' | 'eleven_multilingual_v1' | 'eleven_multilingual_v2' | 'eleven_flash_v2' | 'eleven_flash_v2_5' | 'eleven_turbo_v2' | 'eleven_turbo_v2_5';
2
+ export type TTSEncoding = 'pcm_16000' | 'pcm_22050' | 'pcm_44100';
3
+ //# sourceMappingURL=models.d.ts.map
package/dist/tts.d.cts ADDED
@@ -0,0 +1,44 @@
1
+ /// <reference types="node" resolution-mode="require"/>
2
+ import { tokenize, tts } from '@livekit/agents';
3
+ import { URL } from 'node:url';
4
+ import type { TTSEncoding, TTSModels } from './models.js';
5
+ type Voice = {
6
+ id: string;
7
+ name: string;
8
+ category: string;
9
+ settings?: VoiceSettings;
10
+ };
11
+ type VoiceSettings = {
12
+ stability: number;
13
+ similarity_boost: number;
14
+ style?: number;
15
+ use_speaker_boost: boolean;
16
+ };
17
+ export interface TTSOptions {
18
+ apiKey?: string;
19
+ voice: Voice;
20
+ modelID: TTSModels | string;
21
+ languageCode?: string;
22
+ baseURL: string;
23
+ encoding: TTSEncoding;
24
+ streamingLatency: number;
25
+ wordTokenizer: tokenize.WordTokenizer;
26
+ chunkLengthSchedule: number[];
27
+ enableSsmlParsing: boolean;
28
+ }
29
+ export declare class TTS extends tts.TTS {
30
+ #private;
31
+ label: string;
32
+ constructor(opts?: Partial<TTSOptions>);
33
+ listVoices(): Promise<Voice[]>;
34
+ synthesize(): tts.ChunkedStream;
35
+ stream(): tts.SynthesizeStream;
36
+ }
37
+ export declare class SynthesizeStream extends tts.SynthesizeStream {
38
+ #private;
39
+ label: string;
40
+ readonly streamURL: URL;
41
+ constructor(tts: TTS, opts: TTSOptions);
42
+ }
43
+ export {};
44
+ //# sourceMappingURL=tts.d.ts.map
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=tts.test.d.ts.map
package/package.json CHANGED
@@ -1,15 +1,18 @@
1
1
  {
2
2
  "name": "@livekit/agents-plugin-elevenlabs",
3
- "version": "0.6.1",
3
+ "version": "0.6.3",
4
4
  "description": "ElevenLabs plugin for LiveKit Node Agents",
5
5
  "main": "dist/index.js",
6
6
  "require": "dist/index.cjs",
7
7
  "types": "dist/index.d.ts",
8
8
  "exports": {
9
- ".": {
9
+ "import": {
10
10
  "types": "./dist/index.d.ts",
11
- "import": "./dist/index.js",
12
- "require": "./dist/index.cjs"
11
+ "default": "./dist/index.js"
12
+ },
13
+ "require": {
14
+ "types": "./dist/index.d.cts",
15
+ "default": "./dist/index.cjs"
13
16
  }
14
17
  },
15
18
  "author": "LiveKit",
@@ -25,7 +28,7 @@
25
28
  "@livekit/agents": "^x",
26
29
  "@livekit/agents-plugin-openai": "^x",
27
30
  "@livekit/agents-plugins-test": "^x",
28
- "@livekit/rtc-node": "^0.13.2",
31
+ "@livekit/rtc-node": "^0.13.11",
29
32
  "@microsoft/api-extractor": "^7.35.0",
30
33
  "@types/ws": "^8.5.10",
31
34
  "tsup": "^8.3.5",
@@ -35,11 +38,12 @@
35
38
  "ws": "^8.16.0"
36
39
  },
37
40
  "peerDependencies": {
38
- "@livekit/rtc-node": "^0.13.2",
39
- "@livekit/agents": "^0.6.4x"
41
+ "@livekit/rtc-node": "^0.13.11",
42
+ "@livekit/agents": "^0.7.7x"
40
43
  },
41
44
  "scripts": {
42
- "build": "tsup --onSuccess \"tsc --declaration --emitDeclarationOnly\"",
45
+ "build": "tsup --onSuccess \"pnpm build:types\"",
46
+ "build:types": "tsc --declaration --emitDeclarationOnly && node ../../scripts/copyDeclarationOutput.js",
43
47
  "clean": "rm -rf dist",
44
48
  "clean:build": "pnpm clean && pnpm build",
45
49
  "lint": "eslint -f unix \"src/**/*.{ts,js}\"",