@vibesdotdev/agent-execution 0.0.0-stage → 1.0.0-rc.1

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.
Files changed (191) hide show
  1. package/LICENSE +18 -0
  2. package/README.md +53 -2
  3. package/dist/code-session/agent-code-session.consumer.descriptor.d.ts +68 -0
  4. package/dist/code-session/agent-code-session.consumer.descriptor.d.ts.map +1 -0
  5. package/dist/code-session/agent-code-session.consumer.descriptor.js +31 -0
  6. package/dist/code-session/agent-code-session.consumer.descriptor.js.map +1 -0
  7. package/dist/code-session/agent-code-session.consumer.plugin.d.ts +18 -0
  8. package/dist/code-session/agent-code-session.consumer.plugin.d.ts.map +1 -0
  9. package/dist/code-session/agent-code-session.consumer.plugin.js +47 -0
  10. package/dist/code-session/agent-code-session.consumer.plugin.js.map +1 -0
  11. package/dist/code-session/agent-code-session.descriptor.d.ts +163 -0
  12. package/dist/code-session/agent-code-session.descriptor.d.ts.map +1 -0
  13. package/dist/code-session/agent-code-session.descriptor.js +129 -0
  14. package/dist/code-session/agent-code-session.descriptor.js.map +1 -0
  15. package/dist/code-session/agent-code-session.impl.consumer.d.ts +224 -0
  16. package/dist/code-session/agent-code-session.impl.consumer.d.ts.map +1 -0
  17. package/dist/code-session/agent-code-session.impl.consumer.js +2131 -0
  18. package/dist/code-session/agent-code-session.impl.consumer.js.map +1 -0
  19. package/dist/code-session/agent-code-session.kind.d.ts +15 -0
  20. package/dist/code-session/agent-code-session.kind.d.ts.map +1 -0
  21. package/dist/code-session/agent-code-session.kind.js +17 -0
  22. package/dist/code-session/agent-code-session.kind.js.map +1 -0
  23. package/dist/code-session/agent-code-session.plugin.d.ts +17 -0
  24. package/dist/code-session/agent-code-session.plugin.d.ts.map +1 -0
  25. package/dist/code-session/agent-code-session.plugin.js +28 -0
  26. package/dist/code-session/agent-code-session.plugin.js.map +1 -0
  27. package/dist/code-session/billing/gates.d.ts +52 -0
  28. package/dist/code-session/billing/gates.d.ts.map +1 -0
  29. package/dist/code-session/billing/gates.js +75 -0
  30. package/dist/code-session/billing/gates.js.map +1 -0
  31. package/dist/code-session/client/index.d.ts +2 -0
  32. package/dist/code-session/client/index.d.ts.map +1 -0
  33. package/dist/code-session/client/index.js +2 -0
  34. package/dist/code-session/client/index.js.map +1 -0
  35. package/dist/code-session/client/resolve.d.ts +20 -0
  36. package/dist/code-session/client/resolve.d.ts.map +1 -0
  37. package/dist/code-session/client/resolve.js +145 -0
  38. package/dist/code-session/client/resolve.js.map +1 -0
  39. package/dist/code-session/docs/agent-code-session.docs.descriptor.d.ts +4 -0
  40. package/dist/code-session/docs/agent-code-session.docs.descriptor.d.ts.map +1 -0
  41. package/dist/code-session/docs/agent-code-session.docs.descriptor.js +109 -0
  42. package/dist/code-session/docs/agent-code-session.docs.descriptor.js.map +1 -0
  43. package/dist/code-session/git-credential.d.ts +87 -0
  44. package/dist/code-session/git-credential.d.ts.map +1 -0
  45. package/dist/code-session/git-credential.js +107 -0
  46. package/dist/code-session/git-credential.js.map +1 -0
  47. package/dist/code-session/host-target.d.ts +76 -0
  48. package/dist/code-session/host-target.d.ts.map +1 -0
  49. package/dist/code-session/host-target.js +81 -0
  50. package/dist/code-session/host-target.js.map +1 -0
  51. package/dist/code-session/index.d.ts +20 -0
  52. package/dist/code-session/index.d.ts.map +1 -0
  53. package/dist/code-session/index.js +20 -0
  54. package/dist/code-session/index.js.map +1 -0
  55. package/dist/code-session/interfaces/code-session.d.ts +448 -0
  56. package/dist/code-session/interfaces/code-session.d.ts.map +1 -0
  57. package/dist/code-session/interfaces/code-session.js +373 -0
  58. package/dist/code-session/interfaces/code-session.js.map +1 -0
  59. package/dist/code-session/operation-lease.d.ts +48 -0
  60. package/dist/code-session/operation-lease.d.ts.map +1 -0
  61. package/dist/code-session/operation-lease.js +73 -0
  62. package/dist/code-session/operation-lease.js.map +1 -0
  63. package/dist/code-session/remote-setup-custody.d.ts +59 -0
  64. package/dist/code-session/remote-setup-custody.d.ts.map +1 -0
  65. package/dist/code-session/remote-setup-custody.js +78 -0
  66. package/dist/code-session/remote-setup-custody.js.map +1 -0
  67. package/dist/code-session/remote-workspace-fs.d.ts +119 -0
  68. package/dist/code-session/remote-workspace-fs.d.ts.map +1 -0
  69. package/dist/code-session/remote-workspace-fs.js +257 -0
  70. package/dist/code-session/remote-workspace-fs.js.map +1 -0
  71. package/dist/code-session/session-metadata.d.ts +40 -0
  72. package/dist/code-session/session-metadata.d.ts.map +1 -0
  73. package/dist/code-session/session-metadata.js +69 -0
  74. package/dist/code-session/session-metadata.js.map +1 -0
  75. package/dist/code-session-relay/agent-code-session-relay.descriptor.d.ts +78 -0
  76. package/dist/code-session-relay/agent-code-session-relay.descriptor.d.ts.map +1 -0
  77. package/dist/code-session-relay/agent-code-session-relay.descriptor.js +38 -0
  78. package/dist/code-session-relay/agent-code-session-relay.descriptor.js.map +1 -0
  79. package/dist/code-session-relay/agent-code-session-relay.impl.d.ts +120 -0
  80. package/dist/code-session-relay/agent-code-session-relay.impl.d.ts.map +1 -0
  81. package/dist/code-session-relay/agent-code-session-relay.impl.js +1392 -0
  82. package/dist/code-session-relay/agent-code-session-relay.impl.js.map +1 -0
  83. package/dist/code-session-relay/agent-code-session-relay.plugin.d.ts +14 -0
  84. package/dist/code-session-relay/agent-code-session-relay.plugin.d.ts.map +1 -0
  85. package/dist/code-session-relay/agent-code-session-relay.plugin.js +25 -0
  86. package/dist/code-session-relay/agent-code-session-relay.plugin.js.map +1 -0
  87. package/dist/code-session-relay/index.d.ts +13 -0
  88. package/dist/code-session-relay/index.d.ts.map +1 -0
  89. package/dist/code-session-relay/index.js +13 -0
  90. package/dist/code-session-relay/index.js.map +1 -0
  91. package/dist/code-session-relay/relay-dial.d.ts +72 -0
  92. package/dist/code-session-relay/relay-dial.d.ts.map +1 -0
  93. package/dist/code-session-relay/relay-dial.js +177 -0
  94. package/dist/code-session-relay/relay-dial.js.map +1 -0
  95. package/dist/index.d.ts +10 -0
  96. package/dist/index.d.ts.map +1 -0
  97. package/dist/index.js +10 -0
  98. package/dist/index.js.map +1 -0
  99. package/dist/sandbox/agent-sandbox.consumer.descriptor.d.ts +35 -0
  100. package/dist/sandbox/agent-sandbox.consumer.descriptor.d.ts.map +1 -0
  101. package/dist/sandbox/agent-sandbox.consumer.descriptor.js +19 -0
  102. package/dist/sandbox/agent-sandbox.consumer.descriptor.js.map +1 -0
  103. package/dist/sandbox/agent-sandbox.consumer.plugin.d.ts +9 -0
  104. package/dist/sandbox/agent-sandbox.consumer.plugin.d.ts.map +1 -0
  105. package/dist/sandbox/agent-sandbox.consumer.plugin.js +33 -0
  106. package/dist/sandbox/agent-sandbox.consumer.plugin.js.map +1 -0
  107. package/dist/sandbox/agent-sandbox.descriptor.d.ts +76 -0
  108. package/dist/sandbox/agent-sandbox.descriptor.d.ts.map +1 -0
  109. package/dist/sandbox/agent-sandbox.descriptor.js +57 -0
  110. package/dist/sandbox/agent-sandbox.descriptor.js.map +1 -0
  111. package/dist/sandbox/agent-sandbox.impl.consumer.d.ts +15 -0
  112. package/dist/sandbox/agent-sandbox.impl.consumer.d.ts.map +1 -0
  113. package/dist/sandbox/agent-sandbox.impl.consumer.js +23 -0
  114. package/dist/sandbox/agent-sandbox.impl.consumer.js.map +1 -0
  115. package/dist/sandbox/agent-sandbox.kind.d.ts +14 -0
  116. package/dist/sandbox/agent-sandbox.kind.d.ts.map +1 -0
  117. package/dist/sandbox/agent-sandbox.kind.js +16 -0
  118. package/dist/sandbox/agent-sandbox.kind.js.map +1 -0
  119. package/dist/sandbox/agent-sandbox.plugin.d.ts +15 -0
  120. package/dist/sandbox/agent-sandbox.plugin.d.ts.map +1 -0
  121. package/dist/sandbox/agent-sandbox.plugin.js +25 -0
  122. package/dist/sandbox/agent-sandbox.plugin.js.map +1 -0
  123. package/dist/sandbox/client/resolve.d.ts +21 -0
  124. package/dist/sandbox/client/resolve.d.ts.map +1 -0
  125. package/dist/sandbox/client/resolve.js +103 -0
  126. package/dist/sandbox/client/resolve.js.map +1 -0
  127. package/dist/sandbox/docs/agent-sandbox.docs.descriptor.d.ts +4 -0
  128. package/dist/sandbox/docs/agent-sandbox.docs.descriptor.d.ts.map +1 -0
  129. package/dist/sandbox/docs/agent-sandbox.docs.descriptor.js +75 -0
  130. package/dist/sandbox/docs/agent-sandbox.docs.descriptor.js.map +1 -0
  131. package/dist/sandbox/index.d.ts +15 -0
  132. package/dist/sandbox/index.d.ts.map +1 -0
  133. package/dist/sandbox/index.js +14 -0
  134. package/dist/sandbox/index.js.map +1 -0
  135. package/dist/sandbox/interfaces/sandbox.d.ts +61 -0
  136. package/dist/sandbox/interfaces/sandbox.d.ts.map +1 -0
  137. package/dist/sandbox/interfaces/sandbox.js +54 -0
  138. package/dist/sandbox/interfaces/sandbox.js.map +1 -0
  139. package/dist/schemas/code-session-resolution.d.ts +20 -0
  140. package/dist/schemas/code-session-resolution.d.ts.map +1 -0
  141. package/dist/schemas/code-session-resolution.js +11 -0
  142. package/dist/schemas/code-session-resolution.js.map +1 -0
  143. package/dist/schemas/session-operation.d.ts +73 -0
  144. package/dist/schemas/session-operation.d.ts.map +1 -0
  145. package/dist/schemas/session-operation.js +47 -0
  146. package/dist/schemas/session-operation.js.map +1 -0
  147. package/dist/schemas/voice.d.ts +87 -0
  148. package/dist/schemas/voice.d.ts.map +1 -0
  149. package/dist/schemas/voice.js +70 -0
  150. package/dist/schemas/voice.js.map +1 -0
  151. package/dist/voice/agent-voice.consumer.descriptor.d.ts +43 -0
  152. package/dist/voice/agent-voice.consumer.descriptor.d.ts.map +1 -0
  153. package/dist/voice/agent-voice.consumer.descriptor.js +20 -0
  154. package/dist/voice/agent-voice.consumer.descriptor.js.map +1 -0
  155. package/dist/voice/agent-voice.consumer.plugin.d.ts +4 -0
  156. package/dist/voice/agent-voice.consumer.plugin.d.ts.map +1 -0
  157. package/dist/voice/agent-voice.consumer.plugin.js +13 -0
  158. package/dist/voice/agent-voice.consumer.plugin.js.map +1 -0
  159. package/dist/voice/agent-voice.descriptor.d.ts +82 -0
  160. package/dist/voice/agent-voice.descriptor.d.ts.map +1 -0
  161. package/dist/voice/agent-voice.descriptor.js +79 -0
  162. package/dist/voice/agent-voice.descriptor.js.map +1 -0
  163. package/dist/voice/agent-voice.impl.consumer.d.ts +35 -0
  164. package/dist/voice/agent-voice.impl.consumer.d.ts.map +1 -0
  165. package/dist/voice/agent-voice.impl.consumer.js +50 -0
  166. package/dist/voice/agent-voice.impl.consumer.js.map +1 -0
  167. package/dist/voice/agent-voice.kind.d.ts +67 -0
  168. package/dist/voice/agent-voice.kind.d.ts.map +1 -0
  169. package/dist/voice/agent-voice.kind.js +26 -0
  170. package/dist/voice/agent-voice.kind.js.map +1 -0
  171. package/dist/voice/agent-voice.plugin.d.ts +4 -0
  172. package/dist/voice/agent-voice.plugin.d.ts.map +1 -0
  173. package/dist/voice/agent-voice.plugin.js +18 -0
  174. package/dist/voice/agent-voice.plugin.js.map +1 -0
  175. package/dist/voice/client.d.ts +38 -0
  176. package/dist/voice/client.d.ts.map +1 -0
  177. package/dist/voice/client.js +29 -0
  178. package/dist/voice/client.js.map +1 -0
  179. package/dist/voice/index.d.ts +14 -0
  180. package/dist/voice/index.d.ts.map +1 -0
  181. package/dist/voice/index.js +14 -0
  182. package/dist/voice/index.js.map +1 -0
  183. package/dist/voice/pipeline.d.ts +66 -0
  184. package/dist/voice/pipeline.d.ts.map +1 -0
  185. package/dist/voice/pipeline.js +330 -0
  186. package/dist/voice/pipeline.js.map +1 -0
  187. package/dist/voice/session.d.ts +29 -0
  188. package/dist/voice/session.d.ts.map +1 -0
  189. package/dist/voice/session.js +78 -0
  190. package/dist/voice/session.js.map +1 -0
  191. package/package.json +279 -4
@@ -0,0 +1,61 @@
1
+ /**
2
+ * Sandbox execution interface — the contract every `agent/sandbox` impl
3
+ * (consumer availability refusal, provider-owned isolated execution) satisfies.
4
+ *
5
+ * Playwright-free / Node-free at the type level so cloud adapters can import
6
+ * it without importing consumer host primitives.
7
+ */
8
+ import * as z from 'zod/v4';
9
+ import type { AgentSandboxDescriptor } from '../agent-sandbox.descriptor.ts';
10
+ /** Language/runtime the snippet targets. MVP: JS/TS via the Bun runtime. */
11
+ export declare const SandboxLanguageSchema: z.ZodEnum<{
12
+ typescript: "typescript";
13
+ javascript: "javascript";
14
+ python: "python";
15
+ bash: "bash";
16
+ }>;
17
+ export type SandboxLanguage = z.infer<typeof SandboxLanguageSchema>;
18
+ /** Requested egress origins the selected provider must enforce. */
19
+ export declare const SandboxEgressInputSchema: z.ZodObject<{
20
+ gitHostOrigin: z.ZodOptional<z.ZodString>;
21
+ packageRegistryOrigin: z.ZodOptional<z.ZodString>;
22
+ extraOrigins: z.ZodOptional<z.ZodArray<z.ZodString>>;
23
+ }, z.core.$strict>;
24
+ export type SandboxEgressInput = z.infer<typeof SandboxEgressInputSchema>;
25
+ export declare const SandboxExecuteInputSchema: z.ZodObject<{
26
+ code: z.ZodString;
27
+ language: z.ZodOptional<z.ZodEnum<{
28
+ typescript: "typescript";
29
+ javascript: "javascript";
30
+ python: "python";
31
+ bash: "bash";
32
+ }>>;
33
+ fileSystem: z.ZodOptional<z.ZodBoolean>;
34
+ env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
35
+ timeoutMs: z.ZodOptional<z.ZodNumber>;
36
+ egress: z.ZodOptional<z.ZodObject<{
37
+ gitHostOrigin: z.ZodOptional<z.ZodString>;
38
+ packageRegistryOrigin: z.ZodOptional<z.ZodString>;
39
+ extraOrigins: z.ZodOptional<z.ZodArray<z.ZodString>>;
40
+ }, z.core.$strict>>;
41
+ }, z.core.$strict>;
42
+ export type SandboxExecuteInput = z.infer<typeof SandboxExecuteInputSchema>;
43
+ export declare const SandboxExecuteResultSchema: z.ZodObject<{
44
+ exitCode: z.ZodNullable<z.ZodNumber>;
45
+ stdout: z.ZodString;
46
+ stderr: z.ZodString;
47
+ timedOut: z.ZodBoolean;
48
+ durationMs: z.ZodNumber;
49
+ workspacePath: z.ZodString;
50
+ }, z.core.$strict>;
51
+ export type SandboxExecuteResult = z.infer<typeof SandboxExecuteResultSchema>;
52
+ /** Total public request guard: raw getters and proxies become the canonical refusal. */
53
+ export declare function parseSandboxExecuteInput<TInput>(value: TInput): SandboxExecuteInput;
54
+ export interface AgentSandboxInterface {
55
+ readonly descriptor: AgentSandboxDescriptor;
56
+ /** Run isolated code or reject when the provider cannot enforce that boundary.
57
+ * The consumer registration rejects with UNAVAILABLE / agent-sandbox-isolation-unavailable.
58
+ */
59
+ execute(input: SandboxExecuteInput): Promise<SandboxExecuteResult>;
60
+ }
61
+ //# sourceMappingURL=sandbox.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sandbox.d.ts","sourceRoot":"","sources":["../../../src/sandbox/interfaces/sandbox.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAM5B,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,gCAAgC,CAAC;AAE7E,4EAA4E;AAC5E,eAAO,MAAM,qBAAqB;;;;;EAAyD,CAAC;AAC5F,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAEpE,mEAAmE;AACnE,eAAO,MAAM,wBAAwB;;;;kBAM3B,CAAC;AACX,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAE1E,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;kBAS5B,CAAC;AACX,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAC;AAE5E,eAAO,MAAM,0BAA0B;;;;;;;kBAS7B,CAAC;AACX,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC;AAE9E,wFAAwF;AACxF,wBAAgB,wBAAwB,CAAC,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,mBAAmB,CAWnF;AAED,MAAM,WAAW,qBAAqB;IACrC,QAAQ,CAAC,UAAU,EAAE,sBAAsB,CAAC;IAC5C;;OAEG;IACH,OAAO,CAAC,KAAK,EAAE,mBAAmB,GAAG,OAAO,CAAC,oBAAoB,CAAC,CAAC;CACnE"}
@@ -0,0 +1,54 @@
1
+ /**
2
+ * Sandbox execution interface — the contract every `agent/sandbox` impl
3
+ * (consumer availability refusal, provider-owned isolated execution) satisfies.
4
+ *
5
+ * Playwright-free / Node-free at the type level so cloud adapters can import
6
+ * it without importing consumer host primitives.
7
+ */
8
+ import * as z from 'zod/v4';
9
+ import { CapabilityError, CaughtFailureSchema, valueFreeFailure } from '@vibesdotdev/kernel';
10
+ /** Language/runtime the snippet targets. MVP: JS/TS via the Bun runtime. */
11
+ export const SandboxLanguageSchema = z.enum(['javascript', 'typescript', 'python', 'bash']);
12
+ /** Requested egress origins the selected provider must enforce. */
13
+ export const SandboxEgressInputSchema = z
14
+ .object({
15
+ gitHostOrigin: z.string().url().max(8_192).optional(),
16
+ packageRegistryOrigin: z.string().url().max(8_192).optional(),
17
+ extraOrigins: z.array(z.string().url().max(8_192)).max(1_024).optional()
18
+ })
19
+ .strict();
20
+ export const SandboxExecuteInputSchema = z
21
+ .object({
22
+ code: z.string().max(16 * 1024 * 1024),
23
+ language: SandboxLanguageSchema.optional(),
24
+ fileSystem: z.boolean().optional(),
25
+ env: z.record(z.string().trim().min(1).max(256), z.string().max(64 * 1024)).optional(),
26
+ timeoutMs: z.number().int().positive().finite().optional(),
27
+ egress: SandboxEgressInputSchema.optional()
28
+ })
29
+ .strict();
30
+ export const SandboxExecuteResultSchema = z
31
+ .object({
32
+ exitCode: z.number().int().nullable(),
33
+ stdout: z.string(),
34
+ stderr: z.string(),
35
+ timedOut: z.boolean(),
36
+ durationMs: z.number().finite().nonnegative(),
37
+ workspacePath: z.string().min(1).max(8_192)
38
+ })
39
+ .strict();
40
+ /** Total public request guard: raw getters and proxies become the canonical refusal. */
41
+ export function parseSandboxExecuteInput(value) {
42
+ try {
43
+ return SandboxExecuteInputSchema.parse(value);
44
+ }
45
+ catch (caught) {
46
+ throw new CapabilityError('The sandbox execution request is invalid.', 'INVALID_INPUT', {
47
+ reason: 'agent-sandbox-request-invalid',
48
+ retryable: false,
49
+ details: { field: 'input' },
50
+ cause: valueFreeFailure(CaughtFailureSchema.parse(caught))
51
+ });
52
+ }
53
+ }
54
+ //# sourceMappingURL=sandbox.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sandbox.js","sourceRoot":"","sources":["../../../src/sandbox/interfaces/sandbox.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAC5B,OAAO,EACN,eAAe,EACf,mBAAmB,EACnB,gBAAgB,EAChB,MAAM,qBAAqB,CAAC;AAG7B,4EAA4E;AAC5E,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC,YAAY,EAAE,YAAY,EAAE,QAAQ,EAAE,MAAM,CAAC,CAAC,CAAC;AAG5F,mEAAmE;AACnE,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC;KACvC,MAAM,CAAC;IACP,aAAa,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,QAAQ,EAAE;IACrD,qBAAqB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,QAAQ,EAAE;IAC7D,YAAY,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,QAAQ,EAAE;CACxE,CAAC;KACD,MAAM,EAAE,CAAC;AAGX,MAAM,CAAC,MAAM,yBAAyB,GAAG,CAA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OAAO,yBAAyB,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IAC/C,CAAC;IAAC,OAAO,MAAM,EAAE,CAAC;QACjB,MAAM,IAAI,eAAe,CAAC,2CAA2C,EAAE,eAAe,EAAE;YACvF,MAAM,EAAE,+BAA+B;YACvC,SAAS,EAAE,KAAK;YAChB,OAAO,EAAE,EAAE,KAAK,EAAE,OAAO,EAAE;YAC3B,KAAK,EAAE,gBAAgB,CAAC,mBAAmB,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;SAC1D,CAAC,CAAC;IACJ,CAAC;AACF,CAAC"}
@@ -0,0 +1,20 @@
1
+ import * as z from 'zod/v4';
2
+ export declare const ResolveCodeSessionOptionsSchema: z.ZodObject<{
3
+ explicitId: z.ZodOptional<z.ZodString>;
4
+ requiredOs: z.ZodOptional<z.ZodEnum<{
5
+ linux: "linux";
6
+ macos: "macos";
7
+ windows: "windows";
8
+ }>>;
9
+ requiredArch: z.ZodOptional<z.ZodEnum<{
10
+ x64: "x64";
11
+ arm64: "arm64";
12
+ }>>;
13
+ requiredHostTargetKind: z.ZodOptional<z.ZodEnum<{
14
+ cloud: "cloud";
15
+ host: "host";
16
+ provisioned: "provisioned";
17
+ }>>;
18
+ }, z.core.$strict>;
19
+ export type ResolveCodeSessionOptions = z.infer<typeof ResolveCodeSessionOptionsSchema>;
20
+ //# sourceMappingURL=code-session-resolution.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"code-session-resolution.d.ts","sourceRoot":"","sources":["../../src/schemas/code-session-resolution.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAG5B,eAAO,MAAM,+BAA+B;;;;;;;;;;;;;;;;kBAOlC,CAAC;AAEX,MAAM,MAAM,yBAAyB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAC"}
@@ -0,0 +1,11 @@
1
+ import * as z from 'zod/v4';
2
+ import { SessionHostTargetKindSchema } from "../code-session/host-target.js";
3
+ export const ResolveCodeSessionOptionsSchema = z
4
+ .object({
5
+ explicitId: z.string().trim().min(1).max(256).optional(),
6
+ requiredOs: z.enum(['linux', 'macos', 'windows']).optional(),
7
+ requiredArch: z.enum(['x64', 'arm64']).optional(),
8
+ requiredHostTargetKind: SessionHostTargetKindSchema.optional()
9
+ })
10
+ .strict();
11
+ //# sourceMappingURL=code-session-resolution.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"code-session-resolution.js","sourceRoot":"","sources":["../../src/schemas/code-session-resolution.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAC5B,OAAO,EAAE,2BAA2B,EAAE,MAAM,gCAAgC,CAAC;AAE7E,MAAM,CAAC,MAAM,+BAA+B,GAAG,CAAC;KAC9C,MAAM,CAAC;IACP,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE;IACxD,UAAU,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,OAAO,EAAE,SAAS,CAAC,CAAC,CAAC,QAAQ,EAAE;IAC5D,YAAY,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC,CAAC,QAAQ,EAAE;IACjD,sBAAsB,EAAE,2BAA2B,CAAC,QAAQ,EAAE;CAC9D,CAAC;KACD,MAAM,EAAE,CAAC"}
@@ -0,0 +1,73 @@
1
+ import * as z from 'zod/v4';
2
+ export declare const CodeSessionOperationStageSchema: z.ZodEnum<{
3
+ ready: "ready";
4
+ reserved: "reserved";
5
+ "source-preparing": "source-preparing";
6
+ "source-ready": "source-ready";
7
+ "setup-intent": "setup-intent";
8
+ "setup-running": "setup-running";
9
+ "setup-succeeded": "setup-succeeded";
10
+ "attention-required": "attention-required";
11
+ "cleanup-pending": "cleanup-pending";
12
+ "torn-down": "torn-down";
13
+ }>;
14
+ export type CodeSessionOperationStage = z.infer<typeof CodeSessionOperationStageSchema>;
15
+ export declare const CodeSessionOperationCleanupSchema: z.ZodObject<{
16
+ path: z.ZodString;
17
+ phase: z.ZodEnum<{
18
+ removed: "removed";
19
+ intent: "intent";
20
+ quarantined: "quarantined";
21
+ }>;
22
+ relay: z.ZodOptional<z.ZodObject<{
23
+ authorityId: z.ZodString;
24
+ hostId: z.ZodString;
25
+ sessionRoot: z.ZodString;
26
+ legacy: z.ZodBoolean;
27
+ }, z.core.$strict>>;
28
+ }, z.core.$strict>;
29
+ /** Durable execution-owner receipt for one create-or-get operation. */
30
+ export declare const PersistedCodeSessionOperationSchema: z.ZodObject<{
31
+ operationId: z.ZodString;
32
+ fingerprint: z.ZodString;
33
+ sessionId: z.ZodString;
34
+ stage: z.ZodEnum<{
35
+ ready: "ready";
36
+ reserved: "reserved";
37
+ "source-preparing": "source-preparing";
38
+ "source-ready": "source-ready";
39
+ "setup-intent": "setup-intent";
40
+ "setup-running": "setup-running";
41
+ "setup-succeeded": "setup-succeeded";
42
+ "attention-required": "attention-required";
43
+ "cleanup-pending": "cleanup-pending";
44
+ "torn-down": "torn-down";
45
+ }>;
46
+ generation: z.ZodNumber;
47
+ stagingPath: z.ZodOptional<z.ZodString>;
48
+ cleanup: z.ZodOptional<z.ZodObject<{
49
+ path: z.ZodString;
50
+ phase: z.ZodEnum<{
51
+ removed: "removed";
52
+ intent: "intent";
53
+ quarantined: "quarantined";
54
+ }>;
55
+ relay: z.ZodOptional<z.ZodObject<{
56
+ authorityId: z.ZodString;
57
+ hostId: z.ZodString;
58
+ sessionRoot: z.ZodString;
59
+ legacy: z.ZodBoolean;
60
+ }, z.core.$strict>>;
61
+ }, z.core.$strict>>;
62
+ createdAt: z.ZodString;
63
+ updatedAt: z.ZodString;
64
+ failure: z.ZodOptional<z.ZodString>;
65
+ }, z.core.$strict>;
66
+ export type PersistedCodeSessionOperation = z.infer<typeof PersistedCodeSessionOperationSchema>;
67
+ /** Receiving-host operation ownership; renewals retain the holder identity. */
68
+ export declare const OperationLeaseSchema: z.ZodObject<{
69
+ holderId: z.ZodString;
70
+ expiresAt: z.ZodNumber;
71
+ }, z.core.$strict>;
72
+ export type OperationLease = z.infer<typeof OperationLeaseSchema>;
73
+ //# sourceMappingURL=session-operation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"session-operation.d.ts","sourceRoot":"","sources":["../../src/schemas/session-operation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAE5B,eAAO,MAAM,+BAA+B;;;;;;;;;;;EAW1C,CAAC;AACH,MAAM,MAAM,yBAAyB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAC;AAExF,eAAO,MAAM,iCAAiC;;;;;;;;;;;;;kBAWpC,CAAC;AAEX,uEAAuE;AACvE,eAAO,MAAM,mCAAmC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBActC,CAAC;AACX,MAAM,MAAM,6BAA6B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mCAAmC,CAAC,CAAC;AAGhG,+EAA+E;AAC/E,eAAO,MAAM,oBAAoB;;;kBAGtB,CAAC;AACZ,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC"}
@@ -0,0 +1,47 @@
1
+ import * as z from 'zod/v4';
2
+ export const CodeSessionOperationStageSchema = z.enum([
3
+ 'reserved',
4
+ 'source-preparing',
5
+ 'source-ready',
6
+ 'setup-intent',
7
+ 'setup-running',
8
+ 'setup-succeeded',
9
+ 'ready',
10
+ 'attention-required',
11
+ 'cleanup-pending',
12
+ 'torn-down'
13
+ ]);
14
+ export const CodeSessionOperationCleanupSchema = z
15
+ .object({
16
+ path: z.string().min(1).max(8_192),
17
+ phase: z.enum(['intent', 'quarantined', 'removed']),
18
+ relay: z.object({
19
+ authorityId: z.string().min(1),
20
+ hostId: z.string().regex(/^[a-z0-9-]{2,64}$/),
21
+ sessionRoot: z.string().min(1).max(8_192),
22
+ legacy: z.boolean()
23
+ }).strict().optional()
24
+ })
25
+ .strict();
26
+ /** Durable execution-owner receipt for one create-or-get operation. */
27
+ export const PersistedCodeSessionOperationSchema = z
28
+ .object({
29
+ operationId: z.string().trim().min(1).max(512),
30
+ fingerprint: z.string().regex(/^sha256:[0-9a-f]{64}$/),
31
+ sessionId: z.string().trim().min(1).max(128),
32
+ stage: CodeSessionOperationStageSchema,
33
+ generation: z.number().int().positive(),
34
+ stagingPath: z.string().min(1).max(8_192).optional(),
35
+ /** Durable deletion authorization outside the reusable workspace path. */
36
+ cleanup: CodeSessionOperationCleanupSchema.optional(),
37
+ createdAt: z.string().min(1).max(64),
38
+ updatedAt: z.string().min(1).max(64),
39
+ failure: z.string().max(1_024).optional()
40
+ })
41
+ .strict();
42
+ /** Receiving-host operation ownership; renewals retain the holder identity. */
43
+ export const OperationLeaseSchema = z.object({
44
+ holderId: z.string().uuid(),
45
+ expiresAt: z.number().finite().nonnegative()
46
+ }).strict();
47
+ //# sourceMappingURL=session-operation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"session-operation.js","sourceRoot":"","sources":["../../src/schemas/session-operation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAE5B,MAAM,CAAC,MAAM,+BAA+B,GAAG,CAAC,CAAC,IAAI,CAAC;IACrD,UAAU;IACV,kBAAkB;IAClB,cAAc;IACd,cAAc;IACd,eAAe;IACf,iBAAiB;IACjB,OAAO;IACP,oBAAoB;IACpB,iBAAiB;IACjB,WAAW;CACX,CAAC,CAAC;AAGH,MAAM,CAAC,MAAM,iCAAiC,GAAG,CAAC;KAChD,MAAM,CAAC;IACP,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC;IAClC,KAAK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AG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC;IACpC,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC;IACpC,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,QAAQ,EAAE;CACzC,CAAC;KACD,MAAM,EAAE,CAAC;AAIX,+EAA+E;AAC/E,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC5C,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE;IAC3B,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,MAAM,EAAE,CAAC,WAAW,EAAE;CAC5C,CAAC,CAAC,MAAM,EAAE,CAAC"}
@@ -0,0 +1,87 @@
1
+ import * as z from 'zod/v4';
2
+ export declare const VoiceBytesSchema: z.ZodPipe<z.ZodCustom<Uint8Array<ArrayBufferLike>, Uint8Array<ArrayBufferLike>>, z.ZodTransform<Uint8Array<ArrayBufferLike>, Uint8Array<ArrayBufferLike>>>;
3
+ export declare const VoiceMetadataSchema: z.ZodRecord<z.ZodString, z.ZodType<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue, z.core.$ZodTypeInternals<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue>>>;
4
+ export type VoiceMetadata = z.infer<typeof VoiceMetadataSchema>;
5
+ /** A single utterance handed to STT. */
6
+ export declare const VoiceTurnAudioSchema: z.ZodObject<{
7
+ bytes: z.ZodPipe<z.ZodCustom<Uint8Array<ArrayBufferLike>, Uint8Array<ArrayBufferLike>>, z.ZodTransform<Uint8Array<ArrayBufferLike>, Uint8Array<ArrayBufferLike>>>;
8
+ base64: z.ZodOptional<z.ZodString>;
9
+ }, z.core.$strict>;
10
+ export type VoiceTurnAudio = z.infer<typeof VoiceTurnAudioSchema>;
11
+ export declare const VoiceTranscriptSchema: z.ZodObject<{
12
+ text: z.ZodString;
13
+ language: z.ZodOptional<z.ZodString>;
14
+ durationMs: z.ZodOptional<z.ZodNumber>;
15
+ }, z.core.$strict>;
16
+ export type VoiceTranscript = z.infer<typeof VoiceTranscriptSchema>;
17
+ export declare const VoiceReplySchema: z.ZodObject<{
18
+ text: z.ZodString;
19
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue, z.core.$ZodTypeInternals<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue>>>>;
20
+ }, z.core.$strict>;
21
+ export type VoiceReply = z.infer<typeof VoiceReplySchema>;
22
+ export declare const VoiceSynthesisSchema: z.ZodObject<{
23
+ audioBase64: z.ZodString;
24
+ format: z.ZodString;
25
+ durationMs: z.ZodOptional<z.ZodNumber>;
26
+ }, z.core.$strict>;
27
+ export type VoiceSynthesis = z.infer<typeof VoiceSynthesisSchema>;
28
+ /** Conversation history carried across turns (in-memory MVP). */
29
+ export declare const VoiceHistoryMessageSchema: z.ZodObject<{
30
+ role: z.ZodEnum<{
31
+ user: "user";
32
+ system: "system";
33
+ assistant: "assistant";
34
+ }>;
35
+ content: z.ZodString;
36
+ }, z.core.$strict>;
37
+ export type VoiceHistoryMessage = z.infer<typeof VoiceHistoryMessageSchema>;
38
+ export declare const VoiceHistorySchema: z.ZodArray<z.ZodObject<{
39
+ role: z.ZodEnum<{
40
+ user: "user";
41
+ system: "system";
42
+ assistant: "assistant";
43
+ }>;
44
+ content: z.ZodString;
45
+ }, z.core.$strict>>;
46
+ export declare const VoiceAbortSignalSchema: z.ZodInstanceOf<AbortSignal>;
47
+ export declare const VoiceSystemPromptSchema: z.ZodString;
48
+ export declare const VoicePipelineDepsSchema: z.ZodObject<{
49
+ transcribe: z.ZodFunction<z.ZodTuple<[z.ZodObject<{
50
+ bytes: z.ZodPipe<z.ZodCustom<Uint8Array<ArrayBufferLike>, Uint8Array<ArrayBufferLike>>, z.ZodTransform<Uint8Array<ArrayBufferLike>, Uint8Array<ArrayBufferLike>>>;
51
+ base64: z.ZodOptional<z.ZodString>;
52
+ }, z.core.$strict>, z.ZodOptional<z.ZodInstanceOf<AbortSignal>>], null>, z.ZodPromise<z.ZodUnknown>>;
53
+ runAgentTurn: z.ZodFunction<z.ZodTuple<[z.ZodString, z.ZodArray<z.ZodObject<{
54
+ role: z.ZodEnum<{
55
+ user: "user";
56
+ system: "system";
57
+ assistant: "assistant";
58
+ }>;
59
+ content: z.ZodString;
60
+ }, z.core.$strict>>, z.ZodOptional<z.ZodInstanceOf<AbortSignal>>], null>, z.ZodPromise<z.ZodUnknown>>;
61
+ synthesize: z.ZodFunction<z.ZodTuple<[z.ZodString, z.ZodOptional<z.ZodInstanceOf<AbortSignal>>], null>, z.ZodPromise<z.ZodUnknown>>;
62
+ }, z.core.$strip>;
63
+ export type VoicePipelineDeps = z.infer<typeof VoicePipelineDepsSchema>;
64
+ export declare const VoiceTurnTimingSchema: z.ZodObject<{
65
+ sttMs: z.ZodNumber;
66
+ agentMs: z.ZodNumber;
67
+ ttsMs: z.ZodNumber;
68
+ totalMs: z.ZodNumber;
69
+ }, z.core.$strict>;
70
+ export declare const VoiceTurnResultSchema: z.ZodObject<{
71
+ transcript: z.ZodString;
72
+ replyText: z.ZodString;
73
+ synthesis: z.ZodOptional<z.ZodObject<{
74
+ audioBase64: z.ZodString;
75
+ format: z.ZodString;
76
+ durationMs: z.ZodOptional<z.ZodNumber>;
77
+ }, z.core.$strict>>;
78
+ timing: z.ZodObject<{
79
+ sttMs: z.ZodNumber;
80
+ agentMs: z.ZodNumber;
81
+ ttsMs: z.ZodNumber;
82
+ totalMs: z.ZodNumber;
83
+ }, z.core.$strict>;
84
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue, z.core.$ZodTypeInternals<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue>>>>;
85
+ }, z.core.$strict>;
86
+ export type VoiceTurnResult = z.infer<typeof VoiceTurnResultSchema>;
87
+ //# sourceMappingURL=voice.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"voice.d.ts","sourceRoot":"","sources":["../../src/schemas/voice.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAE5B,eAAO,MAAM,gBAAgB,4JAI3B,CAAC;AAEH,eAAO,MAAM,mBAAmB,2QAAwC,CAAC;AACzE,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEhE,wCAAwC;AACxC,eAAO,MAAM,oBAAoB;;;kBAKtB,CAAC;AACZ,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAElE,eAAO,MAAM,qBAAqB;;;;kBAIvB,CAAC;AACZ,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAEpE,eAAO,MAAM,gBAAgB;;;kBAGlB,CAAC;AACZ,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAE1D,eAAO,MAAM,oBAAoB;;;;kBAKtB,CAAC;AACZ,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAElE,iEAAiE;AACjE,eAAO,MAAM,yBAAyB;;;;;;;kBAG3B,CAAC;AACZ,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAC;AAC5E,eAAO,MAAM,kBAAkB;;;;;;;mBAAqC,CAAC;AACrE,eAAO,MAAM,sBAAsB,8BAA4B,CAAC;AAChE,eAAO,MAAM,uBAAuB,aAA6B,CAAC;AAElE,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;iBAalC,CAAC;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAExE,eAAO,MAAM,qBAAqB;;;;;kBAOxB,CAAC;AAEX,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;kBAQxB,CAAC;AACX,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC"}
@@ -0,0 +1,70 @@
1
+ import { JsonValueSchema } from '@vibesdotdev/kernel/schemas/json';
2
+ import * as z from 'zod/v4';
3
+ export const VoiceBytesSchema = z.custom((value) => value instanceof Uint8Array).transform((bytes) => {
4
+ const copy = new Uint8Array(bytes.byteLength);
5
+ copy.set(bytes);
6
+ return copy;
7
+ });
8
+ export const VoiceMetadataSchema = z.record(z.string(), JsonValueSchema);
9
+ /** A single utterance handed to STT. */
10
+ export const VoiceTurnAudioSchema = z.object({
11
+ /** Raw audio bytes for the utterance (the format is the descriptor's `audioFormat`). */
12
+ bytes: VoiceBytesSchema,
13
+ /** Optional base64 alternative when the transport delivered a string. */
14
+ base64: z.string().min(1).optional()
15
+ }).strict();
16
+ export const VoiceTranscriptSchema = z.object({
17
+ text: z.string(),
18
+ language: z.string().min(1).optional(),
19
+ durationMs: z.number().nonnegative().optional()
20
+ }).strict();
21
+ export const VoiceReplySchema = z.object({
22
+ text: z.string(),
23
+ metadata: VoiceMetadataSchema.optional()
24
+ }).strict();
25
+ export const VoiceSynthesisSchema = z.object({
26
+ /** base64-encoded synthesized audio (transport-friendly). */
27
+ audioBase64: z.string(),
28
+ format: z.string().min(1),
29
+ durationMs: z.number().nonnegative().optional()
30
+ }).strict();
31
+ /** Conversation history carried across turns (in-memory MVP). */
32
+ export const VoiceHistoryMessageSchema = z.object({
33
+ role: z.enum(['system', 'user', 'assistant']),
34
+ content: z.string()
35
+ }).strict();
36
+ export const VoiceHistorySchema = z.array(VoiceHistoryMessageSchema);
37
+ export const VoiceAbortSignalSchema = z.instanceof(AbortSignal);
38
+ export const VoiceSystemPromptSchema = z.string().max(256 * 1024);
39
+ export const VoicePipelineDepsSchema = z.object({
40
+ transcribe: z.function({
41
+ input: z.tuple([VoiceTurnAudioSchema, z.instanceof(AbortSignal).optional()]),
42
+ output: z.promise(z.unknown())
43
+ }),
44
+ runAgentTurn: z.function({
45
+ input: z.tuple([z.string(), z.array(VoiceHistoryMessageSchema), z.instanceof(AbortSignal).optional()]),
46
+ output: z.promise(z.unknown())
47
+ }),
48
+ synthesize: z.function({
49
+ input: z.tuple([z.string(), z.instanceof(AbortSignal).optional()]),
50
+ output: z.promise(z.unknown())
51
+ })
52
+ });
53
+ export const VoiceTurnTimingSchema = z
54
+ .object({
55
+ sttMs: z.number().finite().nonnegative(),
56
+ agentMs: z.number().finite().nonnegative(),
57
+ ttsMs: z.number().finite().nonnegative(),
58
+ totalMs: z.number().finite().nonnegative()
59
+ })
60
+ .strict();
61
+ export const VoiceTurnResultSchema = z
62
+ .object({
63
+ transcript: z.string(),
64
+ replyText: z.string(),
65
+ synthesis: VoiceSynthesisSchema.optional(),
66
+ timing: VoiceTurnTimingSchema,
67
+ metadata: VoiceMetadataSchema.optional()
68
+ })
69
+ .strict();
70
+ //# sourceMappingURL=voice.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"voice.js","sourceRoot":"","sources":["../../src/schemas/voice.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAC;AACnE,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAE5B,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,CAAC,MAAM,CAA8B,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,YAAY,UAAU,CAAC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,EAAE,CAAC,CAAC;QACtG,MAAM,EAAE,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC;KAC9B,CAAC;IACF,UAAU,EAAE,CAAC,CAAC,QAAQ,CAAC;QACtB,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,UAAU,CAAC,WAAW,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC;QAClE,MAAM,EAAE,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC;KAC9B,CAAC;CACF,CAAC,CAAC;AAGH,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC;KACpC,MAAM,CAAC;IACP,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,MAAM,EAAE,CAAC,WAAW,EAAE;IACxC,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,MAAM,EAAE,CAAC,WAAW,EAAE;IAC1C,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,MAAM,EAAE,CAAC,WAAW,EAAE;IACxC,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,MAAM,EAAE,CAAC,WAAW,EAAE;CAC1C,CAAC;KACD,MAAM,EAAE,CAAC;AAEX,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC;KACpC,MAAM,CAAC;IACP,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE;IACtB,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE;IACrB,SAAS,EAAE,oBAAoB,CAAC,QAAQ,EAAE;IAC1C,MAAM,EAAE,qBAAqB;IAC7B,QAAQ,EAAE,mBAAmB,CAAC,QAAQ,EAAE;CACxC,CAAC;KACD,MAAM,EAAE,CAAC"}
@@ -0,0 +1,43 @@
1
+ /**
2
+ * Local-first `agent/voice` descriptor.
3
+ *
4
+ * The provider ids name runtime-owned `ai/generation` capabilities. A host
5
+ * resolves those stages and supplies them to `ConsumerAgentVoice.createSession`;
6
+ * this descriptor never imports or constructs a provider.
7
+ */
8
+ export declare const consumerAgentVoiceDescriptor: {
9
+ id: string;
10
+ kind: "agent/voice";
11
+ sttProviderId: string;
12
+ ttsProviderId: string;
13
+ agentLoopId: string;
14
+ sampleRate: number;
15
+ audioFormat: "pcm" | "wav" | "mp3" | "opus" | "aac" | "flac" | "webm";
16
+ turnTimeoutMs: number;
17
+ silenceTimeoutMs: number;
18
+ silenceThreshold: number;
19
+ interruptible: false;
20
+ priority: number;
21
+ name?: string | undefined;
22
+ description?: string | undefined;
23
+ tags?: string[] | undefined;
24
+ hardware?: string[] | undefined;
25
+ enabled?: boolean | undefined;
26
+ capabilityId?: string | undefined;
27
+ requiredContext?: string[] | undefined;
28
+ optionalContext?: string[] | undefined;
29
+ config?: unknown;
30
+ retention?: string | {
31
+ reason: string;
32
+ maxAgeDays?: number | undefined;
33
+ maxEntries?: number | undefined;
34
+ maxBytes?: number | undefined;
35
+ cascadeFrom?: string | undefined;
36
+ ageField?: string | undefined;
37
+ enforcedBy?: string | undefined;
38
+ } | undefined;
39
+ sttModelId?: string | undefined;
40
+ ttsModelId?: string | undefined;
41
+ };
42
+ export default consumerAgentVoiceDescriptor;
43
+ //# sourceMappingURL=agent-voice.consumer.descriptor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"agent-voice.consumer.descriptor.d.ts","sourceRoot":"","sources":["../../src/voice/agent-voice.consumer.descriptor.ts"],"names":[],"mappings":"AAEA;;;;;;GAMG;AACH,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAUvC,CAAC;AAEH,eAAe,4BAA4B,CAAC"}
@@ -0,0 +1,20 @@
1
+ import { createAgentVoiceDescriptor } from "./agent-voice.descriptor.js";
2
+ /**
3
+ * Local-first `agent/voice` descriptor.
4
+ *
5
+ * The provider ids name runtime-owned `ai/generation` capabilities. A host
6
+ * resolves those stages and supplies them to `ConsumerAgentVoice.createSession`;
7
+ * this descriptor never imports or constructs a provider.
8
+ */
9
+ export const consumerAgentVoiceDescriptor = createAgentVoiceDescriptor({
10
+ id: 'agent-voice-local',
11
+ name: 'Agent Voice — Local',
12
+ description: 'Local-first half-duplex voice conversation using runtime-resolved speech recognition, an agent loop, and speech synthesis.',
13
+ hardware: ['consumer'],
14
+ sttProviderId: 'whisper-cpp',
15
+ ttsProviderId: 'bark',
16
+ agentLoopId: 'native-function-loop',
17
+ priority: 100
18
+ });
19
+ export default consumerAgentVoiceDescriptor;
20
+ //# sourceMappingURL=agent-voice.consumer.descriptor.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"agent-voice.consumer.descriptor.js","sourceRoot":"","sources":["../../src/voice/agent-voice.consumer.descriptor.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,0BAA0B,EAAE,MAAM,6BAA6B,CAAC;AAEzE;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,4BAA4B,GAAG,0BAA0B,CAAC;IACtE,EAAE,EAAE,mBAAmB;IACvB,IAAI,EAAE,qBAAqB;IAC3B,WAAW,EACV,4HAA4H;IAC7H,QAAQ,EAAE,CAAC,UAAU,CAAC;IACtB,aAAa,EAAE,aAAa;IAC5B,aAAa,EAAE,MAAM;IACrB,WAAW,EAAE,sBAAsB;IACnC,QAAQ,EAAE,GAAG;CACb,CAAC,CAAC;AAEH,eAAe,4BAA4B,CAAC"}
@@ -0,0 +1,4 @@
1
+ /** Compose alongside the universal voice plugin on consumer hosts. */
2
+ export declare const agentVoiceConsumerPlugin: import("@vibesdotdev/kernel").RuntimePlugin;
3
+ export default agentVoiceConsumerPlugin;
4
+ //# sourceMappingURL=agent-voice.consumer.plugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"agent-voice.consumer.plugin.d.ts","sourceRoot":"","sources":["../../src/voice/agent-voice.consumer.plugin.ts"],"names":[],"mappings":"AAIA,sEAAsE;AACtE,eAAO,MAAM,wBAAwB,6CAOnC,CAAC;AACH,eAAe,wBAAwB,CAAC"}
@@ -0,0 +1,13 @@
1
+ import { createRuntimePlugin, loader } from '@vibesdotdev/kernel';
2
+ import { VOICE_KIND_ID } from "./agent-voice.descriptor.js";
3
+ import consumerAgentVoiceDescriptor from "./agent-voice.consumer.descriptor.js";
4
+ /** Compose alongside the universal voice plugin on consumer hosts. */
5
+ export const agentVoiceConsumerPlugin = createRuntimePlugin({
6
+ id: 'agent-voice-consumer',
7
+ name: 'Agent Voice Consumer',
8
+ dependencies: ['agent-voice'],
9
+ descriptors: [consumerAgentVoiceDescriptor],
10
+ loaders: [loader(consumerAgentVoiceDescriptor.id, { kind: VOICE_KIND_ID, scope: 'consumer' }, () => import("./agent-voice.impl.consumer.js"))]
11
+ });
12
+ export default agentVoiceConsumerPlugin;
13
+ //# sourceMappingURL=agent-voice.consumer.plugin.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"agent-voice.consumer.plugin.js","sourceRoot":"","sources":["../../src/voice/agent-voice.consumer.plugin.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAClE,OAAO,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAC;AAC5D,OAAO,4BAA4B,MAAM,sCAAsC,CAAC;AAEhF,sEAAsE;AACtE,MAAM,CAAC,MAAM,wBAAwB,GAAG,mBAAmB,CAAC;IAC3D,EAAE,EAAE,sBAAsB;IAC1B,IAAI,EAAE,sBAAsB;IAC5B,YAAY,EAAE,CAAC,aAAa,CAAC;IAC7B,WAAW,EAAE,CAAC,4BAA4B,CAAC;IAC3C,OAAO,EAAE,CAAC,MAAM,CAAC,4BAA4B,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,aAAa,EAAE,KAAK,EAAE,UAAU,EAAE,EAC3F,GAAG,EAAE,CAAC,MAAM,CAAC,gCAAgC,CAAC,CAAC,CAAC;CACjD,CAAC,CAAC;AACH,eAAe,wBAAwB,CAAC"}