experimental-agent 0.0.4 → 0.1.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 (44) hide show
  1. package/dist/agent-workflow.d.mts +2 -3
  2. package/dist/agent-workflow.d.ts +2 -3
  3. package/dist/agent-workflow.js +947 -436
  4. package/dist/agent-workflow.mjs +3 -2
  5. package/dist/chunk-2IIWVPZB.mjs +334 -0
  6. package/dist/chunk-A63YU65A.mjs +20 -0
  7. package/dist/{chunk-3ODWQVIA.mjs → chunk-BJTO5JO5.mjs} +1 -2
  8. package/dist/chunk-GJETDXOU.mjs +361 -0
  9. package/dist/chunk-RDKDLHXM.mjs +2031 -0
  10. package/dist/{chunk-T7PMZLOX.mjs → chunk-T2UUL6VC.mjs} +4 -4
  11. package/dist/{chunk-TQRCSTCF.mjs → chunk-VGJISV6O.mjs} +9 -4
  12. package/dist/chunk-VS7U6SXN.mjs +1261 -0
  13. package/dist/{client-SREKHM6I.mjs → client-66JIQLSA.mjs} +2 -2
  14. package/dist/client-DjcE0ATp.d.mts +710 -0
  15. package/dist/client-DwrDzn4_.d.ts +710 -0
  16. package/dist/client.mjs +1 -1
  17. package/dist/{handler-36FM5H35.mjs → handler-BQY5SOI2.mjs} +2 -2
  18. package/dist/index.d.mts +18 -4
  19. package/dist/index.d.ts +18 -4
  20. package/dist/index.js +1178 -509
  21. package/dist/index.mjs +152 -49
  22. package/dist/lifecycle-workflow.d.mts +3 -2
  23. package/dist/lifecycle-workflow.d.ts +3 -2
  24. package/dist/lifecycle-workflow.js +111 -5
  25. package/dist/lifecycle-workflow.mjs +3 -2
  26. package/dist/local-fs-handlers-Q5W52DKV.mjs +290 -0
  27. package/dist/next/loader.js +7 -7
  28. package/dist/next/loader.mjs +3 -3
  29. package/dist/next.js +9 -4
  30. package/dist/next.mjs +11 -6
  31. package/dist/{process-manager-JAKAXROL.mjs → process-manager-ZCET3VD2.mjs} +1 -1
  32. package/dist/{sandbox-QAPGBVYM.mjs → sandbox-27X2DSE3.mjs} +4 -3
  33. package/dist/{storage-Q376OZH3.mjs → storage-KQYV42J4.mjs} +3 -3
  34. package/dist/{client-6g79J0s3.d.mts → types-DuTc4UQW.d.mts} +229 -590
  35. package/dist/{client-6g79J0s3.d.ts → types-DuTc4UQW.d.ts} +229 -590
  36. package/dist/vercel-SD3JTECG.mjs +20 -0
  37. package/dist/{vercel-sdk-VHKEX2GQ.mjs → vercel-sdk-I6A4MVAN.mjs} +3 -3
  38. package/package.json +3 -3
  39. package/dist/chunk-GSRJYPWF.mjs +0 -284
  40. package/dist/chunk-JCPQQWIK.mjs +0 -2057
  41. package/dist/chunk-JEE2FQ4O.mjs +0 -844
  42. package/dist/chunk-VBLZWXVE.mjs +0 -318
  43. package/dist/local-fs-handlers-P4WGW3QY.mjs +0 -235
  44. package/dist/vercel-LLXAHKVJ.mjs +0 -20
package/dist/client.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import "./chunk-3ODWQVIA.mjs";
1
+ import "./chunk-BJTO5JO5.mjs";
2
2
 
3
3
  // src/ui.ts
4
4
  function isToolPart(part) {
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  handleStorageRpc
3
- } from "./chunk-VBLZWXVE.mjs";
4
- import "./chunk-3ODWQVIA.mjs";
3
+ } from "./chunk-GJETDXOU.mjs";
4
+ import "./chunk-BJTO5JO5.mjs";
5
5
  export {
6
6
  handleStorageRpc
7
7
  };
package/dist/index.d.mts CHANGED
@@ -1,8 +1,10 @@
1
- import { M as MethodName, S as StorageMethods } from './client-6g79J0s3.mjs';
2
- export { A as AgentOptions, B as BuiltInToolName, E as ExecResult, G as GenerationOptions, I as InferUIMessage, L as ListResult, a as Message, b as MessageNotFoundError, c as MessageUsage, P as Part, R as ResolvedStorage, d as RpcPayload, e as RpcResult, f as Sandbox, g as SandboxConfig, h as SandboxError, i as SandboxNotFoundError, j as SandboxRecord, k as SendInput, l as Session, m as SessionNotFoundError, n as SessionOptions, o as SkillSummary, p as StepUsage, q as StorageConfig, r as StorageError, T as TagsSchema, s as ToolContext, U as UploadableFile, t as UsageSummary, u as agent, v as builtinToolNames } from './client-6g79J0s3.mjs';
1
+ import { R as RpcPayload, a as RpcResult } from './client-DjcE0ATp.mjs';
2
+ export { A as AgentDataTypes, b as AgentOptions, c as AgentStatus, d as AgentStream, B as BuiltInToolName, E as ExecResult, G as GenerationOptions, I as InferUIMessage, O as OnRestart, S as Sandbox, e as SandboxSetup, f as SendInput, g as SessionOptions, h as SkillSummary, T as TagsSchema, i as ToolContext, U as UploadableFile, j as agent, k as builtinToolNames } from './client-DjcE0ATp.mjs';
3
+ import { M as MethodName, S as StorageMethods } from './types-DuTc4UQW.mjs';
4
+ export { L as ListResult, a as Message, b as MessageNotFoundError, c as MessageUsage, P as Part, R as ResolvedStorage, d as SandboxConfig, e as SandboxError, f as SandboxNotFoundError, g as SandboxRecord, h as Session, i as SessionNotFoundError, j as StepUsage, k as StorageConfig, l as StorageError, U as UsageSummary } from './types-DuTc4UQW.mjs';
3
5
  import { z } from 'zod';
4
- import 'errore';
5
6
  import 'ai';
7
+ import 'errore';
6
8
 
7
9
  type Handlers = {
8
10
  [K in MethodName]: (params: z.infer<StorageMethods[K]["params"]>) => Promise<z.infer<StorageMethods[K]["result"]>>;
@@ -23,4 +25,16 @@ type RpcErrorResponse = {
23
25
  type RpcResponse<T = unknown> = RpcSuccessResponse<T> | RpcErrorResponse;
24
26
  declare function handleStorageRpc(body: RpcRequest, handlers: Handlers): Promise<RpcResponse>;
25
27
 
26
- export { type Handlers, type RpcRequest, type RpcResponse, handleStorageRpc };
28
+ /**
29
+ * Module-level registry for agent RPC functions.
30
+ *
31
+ * RPC functions are async step functions generated by the Next.js loader
32
+ * (in steps.js). They cannot be serialized by devalue, so they must not
33
+ * appear in workflow arguments. Instead, the loader init registers each
34
+ * agent's RPC here, and workflow step functions look it up by agent name.
35
+ */
36
+
37
+ type RpcFn = (params: RpcPayload) => Promise<RpcResult>;
38
+ declare function registerRpc(name: string, fn: RpcFn): void;
39
+
40
+ export { type Handlers, RpcPayload, type RpcRequest, type RpcResponse, RpcResult, handleStorageRpc, registerRpc };
package/dist/index.d.ts CHANGED
@@ -1,8 +1,10 @@
1
- import { M as MethodName, S as StorageMethods } from './client-6g79J0s3.js';
2
- export { A as AgentOptions, B as BuiltInToolName, E as ExecResult, G as GenerationOptions, I as InferUIMessage, L as ListResult, a as Message, b as MessageNotFoundError, c as MessageUsage, P as Part, R as ResolvedStorage, d as RpcPayload, e as RpcResult, f as Sandbox, g as SandboxConfig, h as SandboxError, i as SandboxNotFoundError, j as SandboxRecord, k as SendInput, l as Session, m as SessionNotFoundError, n as SessionOptions, o as SkillSummary, p as StepUsage, q as StorageConfig, r as StorageError, T as TagsSchema, s as ToolContext, U as UploadableFile, t as UsageSummary, u as agent, v as builtinToolNames } from './client-6g79J0s3.js';
1
+ import { R as RpcPayload, a as RpcResult } from './client-DwrDzn4_.js';
2
+ export { A as AgentDataTypes, b as AgentOptions, c as AgentStatus, d as AgentStream, B as BuiltInToolName, E as ExecResult, G as GenerationOptions, I as InferUIMessage, O as OnRestart, S as Sandbox, e as SandboxSetup, f as SendInput, g as SessionOptions, h as SkillSummary, T as TagsSchema, i as ToolContext, U as UploadableFile, j as agent, k as builtinToolNames } from './client-DwrDzn4_.js';
3
+ import { M as MethodName, S as StorageMethods } from './types-DuTc4UQW.js';
4
+ export { L as ListResult, a as Message, b as MessageNotFoundError, c as MessageUsage, P as Part, R as ResolvedStorage, d as SandboxConfig, e as SandboxError, f as SandboxNotFoundError, g as SandboxRecord, h as Session, i as SessionNotFoundError, j as StepUsage, k as StorageConfig, l as StorageError, U as UsageSummary } from './types-DuTc4UQW.js';
3
5
  import { z } from 'zod';
4
- import 'errore';
5
6
  import 'ai';
7
+ import 'errore';
6
8
 
7
9
  type Handlers = {
8
10
  [K in MethodName]: (params: z.infer<StorageMethods[K]["params"]>) => Promise<z.infer<StorageMethods[K]["result"]>>;
@@ -23,4 +25,16 @@ type RpcErrorResponse = {
23
25
  type RpcResponse<T = unknown> = RpcSuccessResponse<T> | RpcErrorResponse;
24
26
  declare function handleStorageRpc(body: RpcRequest, handlers: Handlers): Promise<RpcResponse>;
25
27
 
26
- export { type Handlers, type RpcRequest, type RpcResponse, handleStorageRpc };
28
+ /**
29
+ * Module-level registry for agent RPC functions.
30
+ *
31
+ * RPC functions are async step functions generated by the Next.js loader
32
+ * (in steps.js). They cannot be serialized by devalue, so they must not
33
+ * appear in workflow arguments. Instead, the loader init registers each
34
+ * agent's RPC here, and workflow step functions look it up by agent name.
35
+ */
36
+
37
+ type RpcFn = (params: RpcPayload) => Promise<RpcResult>;
38
+ declare function registerRpc(name: string, fn: RpcFn): void;
39
+
40
+ export { type Handlers, RpcPayload, type RpcRequest, type RpcResponse, RpcResult, handleStorageRpc, registerRpc };