@tangle-network/agent-runtime 0.69.0 → 0.70.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 (67) hide show
  1. package/README.md +81 -13
  2. package/dist/agent.d.ts +4 -5
  3. package/dist/agent.js +3 -4
  4. package/dist/agent.js.map +1 -1
  5. package/dist/analyst-loop.d.ts +3 -4
  6. package/dist/{chunk-K4FQSEXQ.js → chunk-BGOLR66M.js} +6 -6
  7. package/dist/{chunk-G6U3GVK2.js → chunk-CRAH5EY2.js} +2 -2
  8. package/dist/{chunk-RTDI2DHD.js → chunk-HY4YOQM2.js} +6 -6
  9. package/dist/chunk-HY4YOQM2.js.map +1 -0
  10. package/dist/{chunk-QZ6FA5LM.js → chunk-LJZ5GC6C.js} +3 -3
  11. package/dist/{chunk-NLRA6434.js → chunk-YFOPWG74.js} +577 -525
  12. package/dist/chunk-YFOPWG74.js.map +1 -0
  13. package/dist/{coordination-Curpzeyc.d.ts → coordination-C7WxwHXq.d.ts} +8 -1
  14. package/dist/{delegates-CLFNAKyi.d.ts → delegates-DqAgo32T.d.ts} +105 -10
  15. package/dist/{improvement-adapter-BC4HhuAR.d.ts → improvement-adapter-CioiEE2z.d.ts} +1 -1
  16. package/dist/index.d.ts +439 -100
  17. package/dist/index.js +591 -130
  18. package/dist/index.js.map +1 -1
  19. package/dist/intelligence.d.ts +2 -3
  20. package/dist/{loop-runner-bin-B6dzNZC8.d.ts → loop-runner-bin-a8bu4O5-.d.ts} +4 -4
  21. package/dist/loop-runner-bin.d.ts +7 -10
  22. package/dist/loop-runner-bin.js +6 -7
  23. package/dist/loops.d.ts +3149 -16
  24. package/dist/loops.js +33 -60
  25. package/dist/mcp/bin.js +13 -14
  26. package/dist/mcp/bin.js.map +1 -1
  27. package/dist/mcp/index.d.ts +8 -12
  28. package/dist/mcp/index.js +10 -12
  29. package/dist/mcp/index.js.map +1 -1
  30. package/dist/{openai-tools-CA2N3-Ak.d.ts → openai-tools-DPx9Gzvn.d.ts} +1 -1
  31. package/dist/profiles.d.ts +94 -6
  32. package/dist/profiles.js +320 -9
  33. package/dist/profiles.js.map +1 -1
  34. package/dist/{router-client-30Y_pca8.d.ts → router-client-C7kp_ECN.d.ts} +37 -1
  35. package/dist/{substrate-CUgk7F7s.d.ts → substrate-BoRXgvka.d.ts} +52 -1
  36. package/dist/{types-p8dWBIXL.d.ts → types-BC3bZpH0.d.ts} +1 -1
  37. package/dist/{types-Crxftafi.d.ts → types-BYa2ZOAx.d.ts} +83 -2
  38. package/dist/{worktree-fanout-DUiKPApb.d.ts → worktree-fanout-gNfl0Byj.d.ts} +9 -37
  39. package/package.json +17 -37
  40. package/dist/audit.d.ts +0 -93
  41. package/dist/audit.js +0 -312
  42. package/dist/audit.js.map +0 -1
  43. package/dist/chunk-4B6U4CVQ.js +0 -15
  44. package/dist/chunk-4B6U4CVQ.js.map +0 -1
  45. package/dist/chunk-NLRA6434.js.map +0 -1
  46. package/dist/chunk-O2UPHN7X.js +0 -114
  47. package/dist/chunk-O2UPHN7X.js.map +0 -1
  48. package/dist/chunk-RTDI2DHD.js.map +0 -1
  49. package/dist/coder-2leJPOvC.d.ts +0 -52
  50. package/dist/improvement.d.ts +0 -208
  51. package/dist/improvement.js +0 -343
  52. package/dist/improvement.js.map +0 -1
  53. package/dist/local-harness-BE_h8szs.d.ts +0 -93
  54. package/dist/run-loop-D3PwlG7J.d.ts +0 -112
  55. package/dist/runtime-hooks-C7JwKb9E.d.ts +0 -70
  56. package/dist/runtime.d.ts +0 -3120
  57. package/dist/runtime.js +0 -263
  58. package/dist/runtime.js.map +0 -1
  59. package/dist/topology.d.ts +0 -126
  60. package/dist/topology.js +0 -333
  61. package/dist/topology.js.map +0 -1
  62. package/dist/workflow.d.ts +0 -551
  63. package/dist/workflow.js +0 -1781
  64. package/dist/workflow.js.map +0 -1
  65. /package/dist/{chunk-K4FQSEXQ.js.map → chunk-BGOLR66M.js.map} +0 -0
  66. /package/dist/{chunk-G6U3GVK2.js.map → chunk-CRAH5EY2.js.map} +0 -0
  67. /package/dist/{chunk-QZ6FA5LM.js.map → chunk-LJZ5GC6C.js.map} +0 -0
@@ -1,70 +0,0 @@
1
- /**
2
- * @experimental
3
- *
4
- * Runtime hook contracts. Hooks are execution-scoped observers, not part of an
5
- * `AgentProfile`: profiles stay portable agent recipes; hooks attach to the
6
- * loop or product harness that is running the profile.
7
- */
8
- type RuntimeHookPhase = 'before' | 'after' | 'error' | 'event';
9
- type RuntimeHookTarget = 'agent.run' | 'agent.turn' | 'agent.tool_call' | 'agent.spawn' | 'agent.child' | 'agent.plan' | 'agent.decision' | (string & {});
10
- type RuntimeDecisionKind = 'continue' | 'verify' | 'ask' | 'retry' | 'stop' | 'memory-write' | 'memory-read' | 'tool-select' | 'skill-select' | 'workflow-select' | 'surface-promote' | (string & {});
11
- interface RuntimeHookEvent<Payload = unknown> {
12
- id: string;
13
- runId: string;
14
- scenarioId?: string;
15
- target: RuntimeHookTarget;
16
- phase: RuntimeHookPhase;
17
- timestamp: number;
18
- stepIndex?: number;
19
- parentId?: string;
20
- payload?: Payload;
21
- metadata?: Record<string, unknown>;
22
- }
23
- interface RuntimeHookContext {
24
- signal?: AbortSignal;
25
- }
26
- interface RuntimeDecisionEvidenceRef {
27
- source: string;
28
- id: string;
29
- detail?: string;
30
- metadata?: Record<string, unknown>;
31
- }
32
- interface RuntimeDecisionPoint {
33
- id: string;
34
- runId: string;
35
- scenarioId?: string;
36
- stepIndex: number;
37
- kind: RuntimeDecisionKind;
38
- candidateActions: string[];
39
- context?: string;
40
- evidence: RuntimeDecisionEvidenceRef[];
41
- metadata?: Record<string, unknown>;
42
- }
43
- interface RuntimeHookErrorContext {
44
- hook: 'onEvent' | 'onDecisionPoint';
45
- eventId?: string;
46
- target?: RuntimeHookTarget;
47
- phase?: RuntimeHookPhase;
48
- decisionId?: string;
49
- decisionKind?: RuntimeDecisionKind;
50
- }
51
- interface RuntimeHooks {
52
- /**
53
- * General before/after/event hook. Use this for telemetry, memory capture,
54
- * policy wrapping, child lifecycle observers, or product-specific extension
55
- * points.
56
- */
57
- onEvent?: (event: RuntimeHookEvent, context: RuntimeHookContext) => void | Promise<void>;
58
- /**
59
- * Semantic decision hook. Belief-state evaluation consumes this, but runtime
60
- * code should keep emitting ordinary lifecycle events as the base layer.
61
- */
62
- onDecisionPoint?: (point: RuntimeDecisionPoint, context: RuntimeHookContext) => void | Promise<void>;
63
- onHookError?: (error: Error, context: RuntimeHookErrorContext) => void | Promise<void>;
64
- }
65
- declare function defineRuntimeHooks(hooks: RuntimeHooks): RuntimeHooks;
66
- declare function composeRuntimeHooks(...entries: Array<RuntimeHooks | undefined | null | false>): RuntimeHooks;
67
- declare function notifyRuntimeHookEvent(hooks: RuntimeHooks | undefined, event: RuntimeHookEvent, context?: RuntimeHookContext): void;
68
- declare function notifyRuntimeDecisionPoint(hooks: RuntimeHooks | undefined, point: RuntimeDecisionPoint, context?: RuntimeHookContext): void;
69
-
70
- export { type RuntimeHooks as R, type RuntimeHookEvent as a, type RuntimeDecisionEvidenceRef as b, type RuntimeDecisionKind as c, type RuntimeDecisionPoint as d, type RuntimeHookContext as e, type RuntimeHookErrorContext as f, type RuntimeHookPhase as g, type RuntimeHookTarget as h, composeRuntimeHooks as i, defineRuntimeHooks as j, notifyRuntimeHookEvent as k, notifyRuntimeDecisionPoint as n };