@aivi/plugin 0.0.0-stage → 0.1.0
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/README.md +29 -2
- package/dist/api.d.ts +10 -0
- package/dist/api.js +147 -0
- package/dist/channel.d.ts +184 -0
- package/dist/channel.js +13 -0
- package/dist/cli.d.ts +71 -0
- package/dist/cli.js +26 -0
- package/dist/dispatcher.d.ts +67 -0
- package/dist/dispatcher.js +13 -0
- package/dist/forge.d.ts +243 -0
- package/dist/forge.js +30 -0
- package/dist/index.d.ts +22 -0
- package/dist/index.js +22 -0
- package/dist/module.d.ts +306 -0
- package/dist/module.js +28 -0
- package/dist/plugin.d.ts +38 -0
- package/dist/plugin.js +13 -0
- package/dist/run.d.ts +144 -0
- package/dist/run.js +18 -0
- package/dist/setup-project.d.ts +128 -0
- package/dist/setup-project.js +48 -0
- package/dist/setup.d.ts +62 -0
- package/dist/setup.js +24 -0
- package/dist/tracker.d.ts +473 -0
- package/dist/tracker.js +38 -0
- package/dist/voice.d.ts +148 -0
- package/dist/voice.js +23 -0
- package/package.json +41 -4
package/dist/voice.js
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The voice contract: hearing as a capability. The voice plugin provides the
|
|
3
|
+
* one adapter (models, diarizer, person memory, wake, transcripts); modules
|
|
4
|
+
* that stand in a room — discord today, meet/teams/zoom tomorrow — open a
|
|
5
|
+
* `VoiceRoom` and feed it audio. When no adapter was provided, opening a
|
|
6
|
+
* room fails with `VoiceNotLoaded`: the plugin is optional, the failure is
|
|
7
|
+
* honest, and no ordering ceremony hides which module is missing.
|
|
8
|
+
*
|
|
9
|
+
* Who the speakers are is the room's business, not the contract's: a
|
|
10
|
+
* platform that names its speakers (Discord) says so per utterance; a room
|
|
11
|
+
* that only has mixed audio (a browser tab, a meeting bridge) pushes raw
|
|
12
|
+
* PCM and the adapter does ASR, diarization and person identification from
|
|
13
|
+
* the audio alone — when a diarizer is configured. Without one the cuts
|
|
14
|
+
* come from loudness and the lines carry no name: a guessed name would
|
|
15
|
+
* invent people (ruled 2026-10-14).
|
|
16
|
+
*/
|
|
17
|
+
/** No voice plugin, no hearing. The fix belongs in the message. */
|
|
18
|
+
export class VoiceNotLoaded extends Error {
|
|
19
|
+
constructor() {
|
|
20
|
+
super('voice is not loaded: aivi add @aivi/voice');
|
|
21
|
+
this.name = 'VoiceNotLoaded';
|
|
22
|
+
}
|
|
23
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,43 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aivi/plugin",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
}
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"type": "module",
|
|
5
|
+
"exports": {
|
|
6
|
+
".": { "development": "./src/index.ts", "default": "./dist/index.js" },
|
|
7
|
+
"./api": { "development": "./src/api.ts", "default": "./dist/api.js" },
|
|
8
|
+
"./channel": { "development": "./src/channel.ts", "default": "./dist/channel.js" },
|
|
9
|
+
"./module": { "development": "./src/module.ts", "default": "./dist/module.js" },
|
|
10
|
+
"./run": { "development": "./src/run.ts", "default": "./dist/run.js" },
|
|
11
|
+
"./tracker": { "development": "./src/tracker.ts", "default": "./dist/tracker.js" },
|
|
12
|
+
"./forge": { "development": "./src/forge.ts", "default": "./dist/forge.js" },
|
|
13
|
+
"./dispatcher": { "development": "./src/dispatcher.ts", "default": "./dist/dispatcher.js" },
|
|
14
|
+
"./voice": { "development": "./src/voice.ts", "default": "./dist/voice.js" }
|
|
15
|
+
},
|
|
16
|
+
"files": [
|
|
17
|
+
"dist"
|
|
18
|
+
],
|
|
19
|
+
"engines": {
|
|
20
|
+
"node": ">=26.1.0 <27"
|
|
21
|
+
},
|
|
22
|
+
"license": "MIT",
|
|
23
|
+
"repository": {
|
|
24
|
+
"type": "git",
|
|
25
|
+
"url": "git+https://github.com/aivi-hq/aivi.git",
|
|
26
|
+
"directory": "packages/plugin"
|
|
27
|
+
},
|
|
28
|
+
"publishConfig": {
|
|
29
|
+
"access": "public"
|
|
30
|
+
},
|
|
31
|
+
"scripts": {
|
|
32
|
+
"prepack": "tsc -b tsconfig.build.json"
|
|
33
|
+
},
|
|
34
|
+
"dependencies": {
|
|
35
|
+
"@aivi/core": "^0.7.1",
|
|
36
|
+
"@clack/prompts": "1.8.1",
|
|
37
|
+
"@opencode/client": "2.0.23",
|
|
38
|
+
"zod": "4.1.13"
|
|
39
|
+
},
|
|
40
|
+
"devDependencies": {
|
|
41
|
+
"commander": "15.0.0"
|
|
42
|
+
}
|
|
43
|
+
}
|