@absolutejs/voice 0.0.16 → 0.0.18

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.
package/dist/types.d.ts CHANGED
@@ -315,6 +315,7 @@ export type VoiceHTMXTargets = {
315
315
  turns: string;
316
316
  };
317
317
  export type VoiceHTMXOptions<TSession extends VoiceSessionRecord = VoiceSessionRecord, TResult = unknown> = VoiceHTMXRenderConfig<TSession, TResult> & {
318
+ bootstrapRoute?: string;
318
319
  route?: string;
319
320
  targets?: Partial<VoiceHTMXTargets>;
320
321
  };
@@ -0,0 +1,32 @@
1
+ [
2
+ {
3
+ "id": "quietly-alone-clean",
4
+ "title": "Short clean utterance",
5
+ "audioPath": "quietly-alone-clean.pcm",
6
+ "expectedText": "GO QUIETLY ALONE NO HARM WILL BEFALL YOU",
7
+ "expectedTerms": ["quietly alone", "no harm"],
8
+ "chunkDurationMs": 100,
9
+ "difficulty": "clean",
10
+ "tags": ["clean", "short", "librispeech"]
11
+ },
12
+ {
13
+ "id": "traveled-back-route-clean",
14
+ "title": "Long clean utterance",
15
+ "audioPath": "traveled-back-route-clean.pcm",
16
+ "expectedText": "WE PASSED AROUND ATLANTA CROSSED THE CHATTAHOOCHEE AND TRAVELED BACK OVER THE SAME ROUTE ON WHICH WE HAD MADE THE ARDUOUS CAMPAIGN UNDER JOE JOHNSTON",
17
+ "expectedTerms": ["atlanta", "chattahoochee", "joe johnston"],
18
+ "chunkDurationMs": 100,
19
+ "difficulty": "clean",
20
+ "tags": ["clean", "long", "librispeech"]
21
+ },
22
+ {
23
+ "id": "rainstorms-noisy",
24
+ "title": "Noisy utterance with synthetic pink noise",
25
+ "audioPath": "rainstorms-noisy.pcm",
26
+ "expectedText": "SLIGHT RAINSTORMS ARE LIKELY TO BE ENCOUNTERED IN A TRIP ROUND THE MOUNTAIN BUT ONE MAY EASILY FIND SHELTER BENEATH WELL THATCHED TREES THAT SHED THE RAIN LIKE A ROOF",
27
+ "expectedTerms": ["rainstorms", "thatched trees"],
28
+ "chunkDurationMs": 100,
29
+ "difficulty": "noisy",
30
+ "tags": ["noisy", "long", "synthetic-noise", "librispeech"]
31
+ }
32
+ ]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@absolutejs/voice",
3
- "version": "0.0.16",
3
+ "version": "0.0.18",
4
4
  "description": "Voice primitives and Elysia plugin for AbsoluteJS",
5
5
  "repository": {
6
6
  "type": "git",
@@ -8,6 +8,7 @@
8
8
  },
9
9
  "files": [
10
10
  "dist",
11
+ "fixtures",
11
12
  "README.md"
12
13
  ],
13
14
  "main": "./dist/index.js",
@@ -15,11 +16,19 @@
15
16
  "license": "CC BY-NC 4.0",
16
17
  "author": "Alex Kahn",
17
18
  "scripts": {
18
- "build": "rm -rf dist && bun build ./src/index.ts ./src/client/index.ts ./src/react/index.ts ./src/vue/index.ts ./src/svelte/index.ts ./src/angular/index.ts --outdir dist --target bun --external elysia --external react --external vue --external @angular/core --external @absolutejs/absolute && tsc --emitDeclarationOnly --project tsconfig.json",
19
+ "bench:assemblyai": "bun run ./scripts/benchmark-stt.ts assemblyai",
20
+ "bench:deepgram": "bun run ./scripts/benchmark-stt.ts deepgram",
21
+ "bench:stt": "bun run ./scripts/benchmark-stt.ts all",
22
+ "build": "rm -rf dist && bun build ./src/index.ts ./src/client/index.ts ./src/react/index.ts ./src/vue/index.ts ./src/svelte/index.ts ./src/angular/index.ts ./src/testing/index.ts --outdir dist --target bun --external elysia --external react --external vue --external @angular/core --external @absolutejs/absolute && bun build ./src/client/htmxBootstrap.ts --outdir dist/client --target browser --format esm && tsc --emitDeclarationOnly --project tsconfig.json",
19
23
  "format": "prettier --write \"./**/*.{js,jsx,ts,tsx,json,md}\"",
20
24
  "lint": "eslint ./src",
21
25
  "release": "bun run format && bun run build && bun publish",
22
- "test": "echo \"Error: no test specified\" && exit 1",
26
+ "test": "bun test ./test/*.test.ts",
27
+ "test:adapters": "bun test ./test/live/*.test.ts",
28
+ "test:assemblyai": "bun test ./test/live/assemblyai.live.test.ts",
29
+ "test:deepgram": "bun test ./test/live/deepgram.live.test.ts",
30
+ "test:elevenlabs": "bun test ./test/live/elevenlabs.live.test.ts",
31
+ "test:openai": "bun test ./test/live/openai.live.test.ts",
23
32
  "typecheck": "bun run tsc --noEmit"
24
33
  },
25
34
  "exports": {
@@ -49,10 +58,17 @@
49
58
  "./angular": {
50
59
  "import": "./dist/angular/index.js",
51
60
  "types": "./dist/angular/index.d.ts"
61
+ },
62
+ "./testing": {
63
+ "import": "./dist/testing/index.js",
64
+ "types": "./dist/testing/index.d.ts"
52
65
  }
53
66
  },
54
67
  "typesVersions": {
55
68
  "*": {
69
+ "testing": [
70
+ "dist/testing/index.d.ts"
71
+ ],
56
72
  "client": [
57
73
  "dist/client/index.d.ts"
58
74
  ],