@execlave/sdk 1.4.0 → 1.5.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.
Files changed (36) hide show
  1. package/README.md +1 -1
  2. package/dist/client.d.ts +11 -0
  3. package/dist/client.d.ts.map +1 -1
  4. package/dist/client.js +68 -10
  5. package/dist/client.js.map +1 -1
  6. package/dist/errors.d.ts +77 -5
  7. package/dist/errors.d.ts.map +1 -1
  8. package/dist/errors.js +105 -6
  9. package/dist/errors.js.map +1 -1
  10. package/dist/index.d.ts +1 -1
  11. package/dist/index.d.ts.map +1 -1
  12. package/dist/index.js +6 -1
  13. package/dist/index.js.map +1 -1
  14. package/dist/instrumentation/events.d.ts.map +1 -1
  15. package/dist/instrumentation/events.js +1 -8
  16. package/dist/instrumentation/events.js.map +1 -1
  17. package/dist/integrations/_actionBinding.d.ts +107 -0
  18. package/dist/integrations/_actionBinding.d.ts.map +1 -0
  19. package/dist/integrations/_actionBinding.js +204 -0
  20. package/dist/integrations/_actionBinding.js.map +1 -0
  21. package/dist/integrations/crewai.d.ts.map +1 -1
  22. package/dist/integrations/crewai.js +13 -21
  23. package/dist/integrations/crewai.js.map +1 -1
  24. package/dist/integrations/langchain.d.ts.map +1 -1
  25. package/dist/integrations/langchain.js +13 -12
  26. package/dist/integrations/langchain.js.map +1 -1
  27. package/dist/integrations/mcp.d.ts.map +1 -1
  28. package/dist/integrations/mcp.js +14 -23
  29. package/dist/integrations/mcp.js.map +1 -1
  30. package/dist/integrations/openai-agents.d.ts.map +1 -1
  31. package/dist/integrations/openai-agents.js +13 -23
  32. package/dist/integrations/openai-agents.js.map +1 -1
  33. package/dist/integrations/openai-chat.d.ts.map +1 -1
  34. package/dist/integrations/openai-chat.js +19 -23
  35. package/dist/integrations/openai-chat.js.map +1 -1
  36. package/package.json +4 -4
package/dist/errors.js CHANGED
@@ -3,7 +3,8 @@
3
3
  * Execlave SDK error classes.
4
4
  */
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.PlanLimitExceededError = exports.QuotaExceededError = exports.EnforcementUnavailableError = exports.ApprovalTimeoutError = exports.PolicyDeniedError = exports.ToolIntegrityError = exports.ValidatorDeniedError = exports.PolicyBlockedError = exports.AgentPausedError = exports.ExeclaveAuthError = exports.ExeclaveError = void 0;
6
+ exports.PlanLimitExceededError = exports.QuotaExceededError = exports.MetadataContractError = exports.EnforcementUnavailableError = exports.ApprovalVerificationError = exports.CertificateMismatchError = exports.ApprovalTimeoutError = exports.PolicyDeniedError = exports.ToolIntegrityError = exports.ValidatorDeniedError = exports.PolicyBlockedError = exports.AgentPausedError = exports.EnforcementHaltError = exports.ExeclaveAuthError = exports.ExeclaveError = void 0;
7
+ exports.isEnforcementError = isEnforcementError;
7
8
  exports.policyBlockedErrorFromViolations = policyBlockedErrorFromViolations;
8
9
  /** Base error for all Execlave SDK errors. */
9
10
  class ExeclaveError extends Error {
@@ -21,6 +22,36 @@ class ExeclaveAuthError extends ExeclaveError {
21
22
  }
22
23
  }
23
24
  exports.ExeclaveAuthError = ExeclaveAuthError;
25
+ /**
26
+ * Base class for every error that represents a governance decision to STOP
27
+ * agent execution — a policy block, an approval denial/timeout, a certificate
28
+ * that does not bind the action, an unverifiable approval, a paused agent, or a
29
+ * fail-closed enforcement outage.
30
+ *
31
+ * Integrations MUST rethrow these rather than swallowing them (see
32
+ * {@link isEnforcementError}). Deriving from a common base is deliberate: a new
33
+ * enforcement error added below automatically halts execution everywhere,
34
+ * instead of silently failing open until every wrapper's allowlist is updated.
35
+ * Errors that are NOT halt decisions (auth failures, plan/quota limits, which
36
+ * have their own fail-open handling) intentionally do not extend this.
37
+ */
38
+ class EnforcementHaltError extends ExeclaveError {
39
+ constructor(message) {
40
+ super(message);
41
+ this.name = 'EnforcementHaltError';
42
+ }
43
+ }
44
+ exports.EnforcementHaltError = EnforcementHaltError;
45
+ /**
46
+ * True when an error is a governance decision to halt execution.
47
+ *
48
+ * Single source of truth — integrations import this instead of maintaining
49
+ * their own `instanceof` allowlists (the duplication that previously let
50
+ * certificate-mismatch rejections be swallowed as "non-fatal").
51
+ */
52
+ function isEnforcementError(err) {
53
+ return err instanceof EnforcementHaltError;
54
+ }
24
55
  /**
25
56
  * Raised when an agent is paused via the kill switch.
26
57
  *
@@ -28,7 +59,7 @@ exports.ExeclaveAuthError = ExeclaveAuthError;
28
59
  * In-flight traces complete naturally (no mid-execution termination).
29
60
  * Your application should catch this and return a graceful message to users.
30
61
  */
31
- class AgentPausedError extends ExeclaveError {
62
+ class AgentPausedError extends EnforcementHaltError {
32
63
  constructor(agentId, reason) {
33
64
  const msg = reason
34
65
  ? `Agent '${agentId}' is paused: ${reason}`
@@ -47,7 +78,7 @@ exports.AgentPausedError = AgentPausedError;
47
78
  * Your application should catch this and return a safe message to users
48
79
  * instead of executing the LLM call.
49
80
  */
50
- class PolicyBlockedError extends ExeclaveError {
81
+ class PolicyBlockedError extends EnforcementHaltError {
51
82
  constructor(violations) {
52
83
  const messages = violations.map((v) => `[${v.policyType}] ${v.message}`);
53
84
  super(`Execution blocked by policy: ${messages.join('; ')}`);
@@ -109,7 +140,7 @@ function policyBlockedErrorFromViolations(violations) {
109
140
  }
110
141
  return new PolicyBlockedError(violations);
111
142
  }
112
- class PolicyDeniedError extends ExeclaveError {
143
+ class PolicyDeniedError extends EnforcementHaltError {
113
144
  constructor(approvalRequestId, reason) {
114
145
  super(reason
115
146
  ? `Approval request '${approvalRequestId}' was denied: ${reason}`
@@ -120,7 +151,7 @@ class PolicyDeniedError extends ExeclaveError {
120
151
  }
121
152
  }
122
153
  exports.PolicyDeniedError = PolicyDeniedError;
123
- class ApprovalTimeoutError extends ExeclaveError {
154
+ class ApprovalTimeoutError extends EnforcementHaltError {
124
155
  constructor(approvalRequestId) {
125
156
  super(`Approval request '${approvalRequestId}' timed out`);
126
157
  this.name = 'ApprovalTimeoutError';
@@ -128,6 +159,51 @@ class ApprovalTimeoutError extends ExeclaveError {
128
159
  }
129
160
  }
130
161
  exports.ApprovalTimeoutError = ApprovalTimeoutError;
162
+ /**
163
+ * Raised when an approval was granted but its authorization certificate does
164
+ * NOT bind to the action the SDK is about to execute — i.e. the server returned
165
+ * `valid: false` from the verify step.
166
+ *
167
+ * This is the closed-loop, fail-closed guard: an approval only authorizes the
168
+ * exact action a human approved. A mismatch means the presented action context
169
+ * differs from the approved one (`action_context_mismatch`), the certificate is
170
+ * expired (`certificate_expired`), already consumed (`certificate_already_used`),
171
+ * unanchored in the audit chain (`certificate_unanchored`), or tampered
172
+ * (`certificate_tampered`). Execution MUST NOT proceed — treat like a denial.
173
+ */
174
+ class CertificateMismatchError extends EnforcementHaltError {
175
+ constructor(approvalRequestId, reason) {
176
+ super(`Authorization certificate for approval '${approvalRequestId}' does not ` +
177
+ `bind to the action being executed` +
178
+ (reason ? ` (${reason})` : '') +
179
+ ' — execution blocked.');
180
+ this.name = 'CertificateMismatchError';
181
+ this.approvalRequestId = approvalRequestId;
182
+ this.reason = reason;
183
+ }
184
+ }
185
+ exports.CertificateMismatchError = CertificateMismatchError;
186
+ /**
187
+ * Raised when the SDK could not positively confirm an approval's certificate —
188
+ * the verify call itself failed (network error, 5xx, malformed response), as
189
+ * opposed to a definitive `valid: false` ({@link CertificateMismatchError}).
190
+ *
191
+ * Fail-closed by design: no confirmation means no execution. Catch this to
192
+ * halt the agent (and optionally retry) rather than proceeding on an
193
+ * unverified approval.
194
+ */
195
+ class ApprovalVerificationError extends EnforcementHaltError {
196
+ constructor(approvalRequestId, cause) {
197
+ super(`Could not verify the authorization certificate for approval ` +
198
+ `'${approvalRequestId}'` +
199
+ (cause ? `: ${cause}` : '') +
200
+ ' — execution blocked (fail-closed).');
201
+ this.name = 'ApprovalVerificationError';
202
+ this.approvalRequestId = approvalRequestId;
203
+ this.cause = cause;
204
+ }
205
+ }
206
+ exports.ApprovalVerificationError = ApprovalVerificationError;
131
207
  /**
132
208
  * Raised when the Execlave enforcement endpoint is unreachable
133
209
  * and the SDK is configured with `enforcementOnOutage: 'fail_closed'`.
@@ -135,7 +211,7 @@ exports.ApprovalTimeoutError = ApprovalTimeoutError;
135
211
  * The circuit breaker trips after 3 consecutive failures. When this error
136
212
  * is thrown, your application should halt agent execution.
137
213
  */
138
- class EnforcementUnavailableError extends ExeclaveError {
214
+ class EnforcementUnavailableError extends EnforcementHaltError {
139
215
  constructor(consecutiveFailures, lastError) {
140
216
  const msg = `Enforcement unavailable after ${consecutiveFailures} consecutive failures. ` +
141
217
  `SDK is in fail_closed mode — agent execution is blocked.` +
@@ -147,6 +223,29 @@ class EnforcementUnavailableError extends ExeclaveError {
147
223
  }
148
224
  }
149
225
  exports.EnforcementUnavailableError = EnforcementUnavailableError;
226
+ /**
227
+ * Raised when a framework adapter attempts to call the internal
228
+ * `enforcePolicyBound` boundary with `metadata` that was not produced by
229
+ * `sealForMetadata`/`sealMetadataEntry`/`sealMetadata` (see
230
+ * `_actionBinding.ts`).
231
+ *
232
+ * This is a contract violation in OUR OWN adapter code, not an operational
233
+ * failure or a policy decision — it means a material field could have been
234
+ * silently omitted from the certificate's canonical action context. Treated
235
+ * as fail-closed rather than the "log and continue" behavior other
236
+ * `EnforcementHaltError` subclasses get from adapters, for the same reason:
237
+ * an unbound certificate is worse than a blocked call.
238
+ */
239
+ class MetadataContractError extends EnforcementHaltError {
240
+ constructor(detail) {
241
+ super('enforcePolicy metadata must be sealed via sealForMetadata/sealMetadataEntry/' +
242
+ 'sealMetadata before crossing the enforcePolicyBound boundary' +
243
+ (detail ? ` (${detail})` : '') +
244
+ ' — execution blocked.');
245
+ this.name = 'MetadataContractError';
246
+ }
247
+ }
248
+ exports.MetadataContractError = MetadataContractError;
150
249
  /**
151
250
  * Raised when the organization's plan quota is exhausted.
152
251
  */
@@ -1 +1 @@
1
- {"version":3,"file":"errors.js","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAuHH,4EAUC;AA/HD,8CAA8C;AAC9C,MAAa,aAAc,SAAQ,KAAK;IACtC,YA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AAED;;;;;;GAMG;AACH,MAAa,sBAAuB,SAAQ,kBAAkB;IAC5D,YAAY,QAAgB,EAAE,OAAe,EAAE,GAAW,EAAE,OAAO,GAAG,EAAE;QACtE,KAAK,CAAC,QAAQ,EAAE,OAAO,EAAE,GAAG,EAAE,OAAO,CAAC,CAAC;QACvC,IAAI,CAAC,IAAI,GAAG,wBAAwB,CAAC;IACvC,CAAC;CACF;AALD,wDAKC"}
package/dist/index.d.ts CHANGED
@@ -9,6 +9,6 @@ export { Execlave as ExeclaveClient } from './client';
9
9
  export { Agent } from './agent';
10
10
  export { Trace } from './trace';
11
11
  export { runOpenAIChat, runLangChain } from './connectors';
12
- export { ExeclaveError, ExeclaveAuthError, AgentPausedError, PolicyBlockedError, ValidatorDeniedError, ToolIntegrityError, policyBlockedErrorFromViolations, PolicyDeniedError, ApprovalTimeoutError, EnforcementUnavailableError, QuotaExceededError, PlanLimitExceededError, } from './errors';
12
+ export { ExeclaveError, ExeclaveAuthError, EnforcementHaltError, isEnforcementError, AgentPausedError, PolicyBlockedError, ValidatorDeniedError, ToolIntegrityError, policyBlockedErrorFromViolations, PolicyDeniedError, ApprovalTimeoutError, CertificateMismatchError, ApprovalVerificationError, EnforcementUnavailableError, MetadataContractError, QuotaExceededError, PlanLimitExceededError, } from './errors';
13
13
  export type { ExeclaveConfig, PrivacyConfig, RegisterAgentOptions, ReportAgentMetadataOptions, ReportToolBaselineOptions, ToolDescriptorInput, AutonomyLevel, TraceOptions, DeployPromptOptions, PromptVersionData, AgentData, AgentStatus, TraceStatus, Environment, EnforcePolicyOptions, EnforceResult, EnforceViolation, AuthorizeCallOptions, AuthorizeResult, DiscoveredAgent, UsageBucket, UsageStatus, } from './types';
14
14
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;A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AiB,EACjB,oBAAoB,EACpB,wBAAwB,EACxB,yBAAyB,EACzB,2BAA2B,EAC3B,qBAAqB,EACrB,kBAAkB,EAClB,sBAAsB,GACvB,MAAM,UAAU,CAAC;AAClB,YAAY,EACV,cAAc,EACd,aAAa,EACb,oBAAoB,EACpB,0BAA0B,EAC1B,yBAAyB,EACzB,mBAAmB,EACnB,aAAa,EACb,YAAY,EACZ,mBAAmB,EACnB,iBAAiB,EACjB,SAAS,EACT,WAAW,EACX,WAAW,EACX,WAAW,EACX,oBAAoB,EACpB,aAAa,EACb,gBAAgB,EAChB,oBAAoB,EACpB,eAAe,EACf,eAAe,EACf,WAAW,EACX,WAAW,GACZ,MAAM,SAAS,CAAC"}
package/dist/index.js CHANGED
@@ -6,7 +6,7 @@
6
6
  * Provides tracing, prompt management, and governance capabilities.
7
7
  */
8
8
  Object.defineProperty(exports, "__esModule", { value: true });
9
- exports.PlanLimitExceededError = exports.QuotaExceededError = exports.EnforcementUnavailableError = exports.ApprovalTimeoutError = exports.PolicyDeniedError = exports.policyBlockedErrorFromViolations = exports.ToolIntegrityError = exports.ValidatorDeniedError = exports.PolicyBlockedError = exports.AgentPausedError = exports.ExeclaveAuthError = exports.ExeclaveError = exports.runLangChain = exports.runOpenAIChat = exports.Trace = exports.Agent = exports.ExeclaveClient = exports.Execlave = void 0;
9
+ exports.PlanLimitExceededError = exports.QuotaExceededError = exports.MetadataContractError = exports.EnforcementUnavailableError = exports.ApprovalVerificationError = exports.CertificateMismatchError = exports.ApprovalTimeoutError = exports.PolicyDeniedError = exports.policyBlockedErrorFromViolations = exports.ToolIntegrityError = exports.ValidatorDeniedError = exports.PolicyBlockedError = exports.AgentPausedError = exports.isEnforcementError = exports.EnforcementHaltError = exports.ExeclaveAuthError = exports.ExeclaveError = exports.runLangChain = exports.runOpenAIChat = exports.Trace = exports.Agent = exports.ExeclaveClient = exports.Execlave = void 0;
10
10
  var client_1 = require("./client");
11
11
  Object.defineProperty(exports, "Execlave", { enumerable: true, get: function () { return client_1.Execlave; } });
12
12
  var client_2 = require("./client"); // backward-compat alias
@@ -21,6 +21,8 @@ Object.defineProperty(exports, "runLangChain", { enumerable: true, get: function
21
21
  var errors_1 = require("./errors");
22
22
  Object.defineProperty(exports, "ExeclaveError", { enumerable: true, get: function () { return errors_1.ExeclaveError; } });
23
23
  Object.defineProperty(exports, "ExeclaveAuthError", { enumerable: true, get: function () { return errors_1.ExeclaveAuthError; } });
24
+ Object.defineProperty(exports, "EnforcementHaltError", { enumerable: true, get: function () { return errors_1.EnforcementHaltError; } });
25
+ Object.defineProperty(exports, "isEnforcementError", { enumerable: true, get: function () { return errors_1.isEnforcementError; } });
24
26
  Object.defineProperty(exports, "AgentPausedError", { enumerable: true, get: function () { return errors_1.AgentPausedError; } });
25
27
  Object.defineProperty(exports, "PolicyBlockedError", { enumerable: true, get: function () { return errors_1.PolicyBlockedError; } });
26
28
  Object.defineProperty(exports, "ValidatorDeniedError", { enumerable: true, get: function () { return errors_1.ValidatorDeniedError; } });
@@ -28,7 +30,10 @@ Object.defineProperty(exports, "ToolIntegrityError", { enumerable: true, get: fu
28
30
  Object.defineProperty(exports, "policyBlockedErrorFromViolations", { enumerable: true, get: function () { return errors_1.policyBlockedErrorFromViolations; } });
29
31
  Object.defineProperty(exports, "PolicyDeniedError", { enumerable: true, get: function () { return errors_1.PolicyDeniedError; } });
30
32
  Object.defineProperty(exports, "ApprovalTimeoutError", { enumerable: true, get: function () { return errors_1.ApprovalTimeoutError; } });
33
+ Object.defineProperty(exports, "CertificateMismatchError", { enumerable: true, get: function () { return errors_1.CertificateMismatchError; } });
34
+ Object.defineProperty(exports, "ApprovalVerificationError", { enumerable: true, get: function () { return errors_1.ApprovalVerificationError; } });
31
35
  Object.defineProperty(exports, "EnforcementUnavailableError", { enumerable: true, get: function () { return errors_1.EnforcementUnavailableError; } });
36
+ Object.defineProperty(exports, "MetadataContractError", { enumerable: true, get: function () { return errors_1.MetadataContractError; } });
32
37
  Object.defineProperty(exports, "QuotaExceededError", { enumerable: true, get: function () { return errors_1.QuotaExceededError; } });
33
38
  Object.defineProperty(exports, "PlanLimitExceededError", { enumerable: true, get: function () { return errors_1.PlanLimitExceededError; } });
34
39
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AAEH,mCAAoC;AAA3B,kGAAA,QAAQ,OAAA;AACjB,mCAAsD,CAAC,wBAAwB;AAAtE,wGAAA,QAAQ,OAAkB;AACnC,iCAAgC;AAAvB,8FAAA,KAAK,OAAA;AACd,iCAAgC;AAAvB,8FAAA,KAAK,OAAA;AACd,2CAA2D;AAAlD,2GAAA,aAAa,OAAA;AAAE,0GAAA,YAAY,OAAA;AACpC,mCAakB;AAZhB,uGAAA,aAAa,OAAA;AACb,2GAAA,iBAAiB,OAAA;AACjB,0GAAA,gBAAgB,OAAA;AAChB,4GAAA,kBAAkB,OAAA;AAClB,8GAAA,oBAAoB,OAAA;AACpB,4GAAA,kBAAkB,OAAA;AAClB,0HAAA,gCAAgC,OAAA;AAChC,2GAAA,iBAAiB,OAAA;AACjB,8GAAA,oBAAoB,OAAA;AACpB,qHAAA,2BAA2B,OAAA;AAC3B,4GAAA,kBAAkB,OAAA;AAClB,gHAAA,sBAAsB,OAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AAEH,mCAAoC;AAA3B,kGAAA,QAAQ,OAAA;AACjB,mCAAsD,CAAC,wBAAwB;AAAtE,wGAAA,QAAQ,OAAkB;AACnC,iCAAgC;AAAvB,8FAAA,KAAK,OAAA;AACd,iCAAgC;AAAvB,8FAAA,KAAK,OAAA;AACd,2CAA2D;AAAlD,2GAAA,aAAa,OAAA;AAAE,0GAAA,YAAY,OAAA;AACpC,mCAkBkB;AAjBhB,uGAAA,aAAa,OAAA;AACb,2GAA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CAAC;CACxB,EACD,EAAE,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,OAAO,CAAC,CAAC,CAAC,GAC7B,OAAO,CAAC,CAAC,CAAC,CAqBZ;AAED,wBAAsB,cAAc,CAAC,CAAC,EACpC,GAAG,EAAE,QAAQ,EACb,IAAI,EAAE;IACJ,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CACpC,EACD,EAAE,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,OAAO,CAAC,CAAC,CAAC,GAC7B,OAAO,CAAC,CAAC,CAAC,CA0BZ;AAED,wBAAgB,iBAAiB,CAC/B,GAAG,EAAE,QAAQ,EACb,IAAI,EAAE;IACJ,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CACpC,GACA,IAAI,CAQN;AAED,wBAAsB,eAAe,CAAC,CAAC,EACrC,GAAG,EAAE,QAAQ,EACb,IAAI,EAAE;IACJ,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;IACd,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CACpC,EACD,EAAE,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,OAAO,CAAC,CAAC,CAAC,GAC7B,OAAO,CAAC,CAAC,CAAC,CAkBZ"}
@@ -14,13 +14,6 @@ exports.recordAgentAction = recordAgentAction;
14
14
  exports.recordRetrieval = recordRetrieval;
15
15
  const errors_1 = require("../errors");
16
16
  const spans_1 = require("./spans");
17
- function isEnforcementError(err) {
18
- return (err instanceof errors_1.PolicyBlockedError ||
19
- err instanceof errors_1.PolicyDeniedError ||
20
- err instanceof errors_1.ApprovalTimeoutError ||
21
- err instanceof errors_1.EnforcementUnavailableError ||
22
- err instanceof errors_1.AgentPausedError);
23
- }
24
17
  async function maybeEnforce(exe, opts) {
25
18
  if (!opts.agentId || opts.input == null)
26
19
  return null;
@@ -34,7 +27,7 @@ async function maybeEnforce(exe, opts) {
34
27
  });
35
28
  }
36
29
  catch (err) {
37
- if (isEnforcementError(err))
30
+ if ((0, errors_1.isEnforcementError)(err))
38
31
  throw err;
39
32
  // eslint-disable-next-line no-console
40
33
  console.warn('[execlave] enforcePolicy failed (non-fatal):', err);
@@ -1 +1 @@
1
- {"version":3,"file":"events.js","sourceRoot":"","sources":["../../src/instrumentation/events.ts"],"names":[],"mappings":";AAAA;;;;;;;GAOG;;AAiEH,sCA+BC;AAED,wCAmCC;AAED,8CAeC;AAED,0CA2BC;AAhLD,sCAMmB;AACnB,mCAOiB;AAEjB,SAAS,kBAAkB,CAAC,GAAY;IACtC,OAAO,CACL,GAAG,YAAY,2BAAkB;QACjC,GAAG,YAAY,0BAAiB;QAChC,GAAG,YAAY,6BAAoB;QACnC,GAAG,YAAY,oCAA2B;QAC1C,GAAG,YAAY,yBAAgB,CAChC,CAAC;AACJ,CAAC;AAED,KAAK,UAAU,YAAY,CACzB,GAAa,EACb,IAMC;IAED,IAAI,CAAC,IAAI,CAAC,OAAO,IAAI,IAAI,CAAC,KAAK,IAAI,IAAI;QAAE,OAAO,IAAI,CAAC;IACrD,IAAI,CAAC;QACH,OAAO,MAAM,GAAG,CAAC,aAAa,CAAC;YAC7B,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,KAAK,EAAE,IAAI,CAAC,KAAK;YACjB,KAAK,EAAE,IAAI,CAAC,KAAK;YACjB,QAAQ,EAAE,IAAI,CAAC,QAAQ;YACvB,aAAa,EAAE,IAAI,CAAC,aAAa;SAClC,CAAC,CAAC;IACL,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QAC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,EAAE,CAAC,EAAE,IAAI,CAAC,CAAC;QAC1C,MAAM,GAAG,CAAC;IACZ,CAAC;AACH,CAAC"}
@@ -0,0 +1,107 @@
1
+ /**
2
+ * Shared action-context binding helpers for framework adapters.
3
+ *
4
+ * Single source of truth for the truncate-for-classifier /
5
+ * seal-for-metadata split every adapter uses when enforcing a policy on a
6
+ * value that may be large or structured (tool arguments, chain inputs, a
7
+ * message array, ...):
8
+ *
9
+ * - `input` sent to `enforcePolicy` is a BOUNDED string — cheap to run a
10
+ * classifier/heuristic over, not a governance-complete record.
11
+ * - `metadata` must carry the FULL, untruncated, JSON-safe value — that is
12
+ * what the server's certificate digest actually covers in whole.
13
+ *
14
+ * Before this module existed, five adapters each hand-rolled their own copy
15
+ * of this split. A prior real incident: two of those copies truncated the
16
+ * value into `input` and sealed NOTHING else, so the certificate bound to a
17
+ * 4000-char summary instead of the actual payload — a material field could
18
+ * change past the truncation point without invalidating the certificate.
19
+ * Consolidating to one module means there is exactly one place this logic
20
+ * can be gotten right or wrong, instead of five, and
21
+ * `actionBindingContract.test.ts` (JS) / `test_action_binding_contract.py`
22
+ * (Python) fail the build if any adapter file reintroduces a local copy
23
+ * instead of importing from here.
24
+ *
25
+ * Adapters MUST call `enforcePolicy` through `enforcePolicyBound` below, not
26
+ * `exe.enforcePolicy` directly — its `metadata` parameter requires the
27
+ * `SealedMetadata` brand, which only `sealForMetadata` / `sealMetadataEntry`
28
+ * / `sealMetadata` can produce. Passing a hand-built object literal there is
29
+ * a compile error, not a silent runtime gap. The public `Execlave.enforcePolicy`
30
+ * API is untouched and still accepts a plain `Record<string, unknown>` —
31
+ * that boundary is a direct customer supplying their own data, a different
32
+ * trust relationship than an adapter translating a provider request.
33
+ */
34
+ import type { Execlave } from '../client';
35
+ import type { EnforcePolicyOptions, EnforceResult } from '../types';
36
+ /** Runtime tag backing the compile-time brand — see `enforcePolicyBound`. */
37
+ declare const SEALED_TAG: unique symbol;
38
+ /**
39
+ * A `metadata` value that has passed through `sealForMetadata` /
40
+ * `sealMetadataEntry` / `sealMetadata`. Nominal (branded) so a plain object
41
+ * literal does not structurally satisfy it — the only way to get one is to
42
+ * call one of those three functions.
43
+ */
44
+ export type SealedMetadata = Record<string, unknown> & {
45
+ readonly [SEALED_TAG]?: true;
46
+ };
47
+ /**
48
+ * Truncate a value to a bounded string for the `input` field. NOT
49
+ * governance-complete on its own — pair with `sealForMetadata` for
50
+ * anything that should be part of the certificate's binding in full.
51
+ */
52
+ export declare function truncateForClassifier(value: unknown, limit?: number): string | null;
53
+ /**
54
+ * Validate a value is JSON-safe before it is embedded in `metadata`,
55
+ * replacing any individual non-serializable field with a marker rather than
56
+ * failing the whole value — see `safeSerialize` for why per-field, not
57
+ * whole-object. A raw, unvalidated object here (a circular reference, a
58
+ * BigInt, ...) would otherwise throw inside JSON.stringify at the HTTP
59
+ * layer. That throw is caught by enforcePolicy's network-error handler
60
+ * (indistinguishable from a real outage) and, under the default fail_open
61
+ * policy, silently ALLOWS the call — a governance bypass that reproduces
62
+ * on every single call with that payload shape, not a transient blip.
63
+ */
64
+ export declare function sealForMetadata(value: unknown): unknown;
65
+ /**
66
+ * Seal the ACTUAL raw request object an adapter is about to hand the
67
+ * provider SDK — every own-enumerable field, by default, not a hand-picked
68
+ * subset. `exclude` strips named fields (transport-only concerns: an
69
+ * AbortSignal, a streaming callback) and defaults to empty — start maximal,
70
+ * add an exclusion only when a specific field demonstrably needs it.
71
+ *
72
+ * This exists because a hand-picked inclusion list (`{ model, messages }`)
73
+ * silently stops covering a field the day the provider SDK adds one and the
74
+ * adapter isn't updated — the certificate binds to less than what actually
75
+ * executes, with no error, no test failure, nothing to notice. Sealing the
76
+ * whole object flips the default: a NEW provider field is covered
77
+ * automatically, and omitting one requires a deliberate, reviewable entry
78
+ * in `exclude` instead of an easy-to-forget addition to an inclusion list.
79
+ */
80
+ export declare function sealFullRequest(request: Record<string, unknown> | null | undefined, exclude?: readonly string[]): SealedMetadata;
81
+ /**
82
+ * Convenience: seal `value` under `key` for a `metadata` object, or
83
+ * `undefined` if there is nothing to seal (so callers can spread it —
84
+ * `metadata: sealMetadataEntry('toolArguments', args)` — without an extra
85
+ * null check).
86
+ */
87
+ export declare function sealMetadataEntry(key: string, value: unknown): SealedMetadata | undefined;
88
+ /**
89
+ * Seal a hand-built metadata object as a whole (e.g. `{ model, messages }`
90
+ * where only some fields need sealing) — for the one call site
91
+ * (`openai-chat.ts`) that combines a sealed field with plain scalars rather
92
+ * than sealing a single field under `sealMetadataEntry`.
93
+ */
94
+ export declare function sealMetadata(value: Record<string, unknown>): SealedMetadata;
95
+ /**
96
+ * The only sanctioned way for an adapter to call `enforcePolicy`. Requires
97
+ * `metadata` to carry the `SealedMetadata` brand — a bare object literal
98
+ * fails to compile here. Defense-in-depth: also checks the runtime tag, so
99
+ * an `as SealedMetadata` cast around the type system (or a plain-JS caller
100
+ * with no compiler at all) still fails closed via `MetadataContractError`
101
+ * instead of silently reaching the server unsealed.
102
+ */
103
+ export declare function enforcePolicyBound(exe: Execlave, opts: Omit<EnforcePolicyOptions, 'metadata'> & {
104
+ metadata?: SealedMetadata;
105
+ }): Promise<EnforceResult>;
106
+ export {};
107
+ //# sourceMappingURL=_actionBinding.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"_actionBinding.d.ts","sourceRoot":"","sources":["../../src/integrations/_actionBinding.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,KAAK,EAAE,oBAAoB,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAKpE,6EAA6E;AAC7E,QAAA,MAAM,UAAU,eAAwC,CAAC;AAEzD;;;;;GAKG;AACH,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG;IAAE,QAAQ,CAAC,CAAC,UAAU,CAAC,CAAC,EAAE,IAAI,CAAA;CAAE,CAAC;AAYxF;;;;GAIG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,OAAO,EAAE,KAAK,SAAgB,GAAG,MAAM,GAAG,IAAI,CAQ1F;AAmDD;;;;;;;;;;GAUG;AACH,wBAAgB,eAAe,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAGvD;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,eAAe,CAC7B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,EACnD,OAAO,GAAE,SAAS,MAAM,EAAO,GAC9B,cAAc,CAShB;AAED;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,GAAG,cAAc,GAAG,SAAS,CAGzF;AAED;;;;;GAKG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,cAAc,CAO3E;AAED;;;;;;;GAOG;AACH,wBAAsB,kBAAkB,CACtC,GAAG,EAAE,QAAQ,EACb,IAAI,EAAE,IAAI,CAAC,oBAAoB,EAAE,UAAU,CAAC,GAAG;IAAE,QAAQ,CAAC,EAAE,cAAc,CAAA;CAAE,GAC3E,OAAO,CAAC,aAAa,CAAC,CAOxB"}
@@ -0,0 +1,204 @@
1
+ "use strict";
2
+ /**
3
+ * Shared action-context binding helpers for framework adapters.
4
+ *
5
+ * Single source of truth for the truncate-for-classifier /
6
+ * seal-for-metadata split every adapter uses when enforcing a policy on a
7
+ * value that may be large or structured (tool arguments, chain inputs, a
8
+ * message array, ...):
9
+ *
10
+ * - `input` sent to `enforcePolicy` is a BOUNDED string — cheap to run a
11
+ * classifier/heuristic over, not a governance-complete record.
12
+ * - `metadata` must carry the FULL, untruncated, JSON-safe value — that is
13
+ * what the server's certificate digest actually covers in whole.
14
+ *
15
+ * Before this module existed, five adapters each hand-rolled their own copy
16
+ * of this split. A prior real incident: two of those copies truncated the
17
+ * value into `input` and sealed NOTHING else, so the certificate bound to a
18
+ * 4000-char summary instead of the actual payload — a material field could
19
+ * change past the truncation point without invalidating the certificate.
20
+ * Consolidating to one module means there is exactly one place this logic
21
+ * can be gotten right or wrong, instead of five, and
22
+ * `actionBindingContract.test.ts` (JS) / `test_action_binding_contract.py`
23
+ * (Python) fail the build if any adapter file reintroduces a local copy
24
+ * instead of importing from here.
25
+ *
26
+ * Adapters MUST call `enforcePolicy` through `enforcePolicyBound` below, not
27
+ * `exe.enforcePolicy` directly — its `metadata` parameter requires the
28
+ * `SealedMetadata` brand, which only `sealForMetadata` / `sealMetadataEntry`
29
+ * / `sealMetadata` can produce. Passing a hand-built object literal there is
30
+ * a compile error, not a silent runtime gap. The public `Execlave.enforcePolicy`
31
+ * API is untouched and still accepts a plain `Record<string, unknown>` —
32
+ * that boundary is a direct customer supplying their own data, a different
33
+ * trust relationship than an adapter translating a provider request.
34
+ */
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.truncateForClassifier = truncateForClassifier;
37
+ exports.sealForMetadata = sealForMetadata;
38
+ exports.sealFullRequest = sealFullRequest;
39
+ exports.sealMetadataEntry = sealMetadataEntry;
40
+ exports.sealMetadata = sealMetadata;
41
+ exports.enforcePolicyBound = enforcePolicyBound;
42
+ const errors_1 = require("../errors");
43
+ const DEFAULT_LIMIT = 4000;
44
+ /** Runtime tag backing the compile-time brand — see `enforcePolicyBound`. */
45
+ const SEALED_TAG = Symbol.for('execlave.sealedMetadata');
46
+ function brand(value) {
47
+ Object.defineProperty(value, SEALED_TAG, { value: true, enumerable: false });
48
+ return value;
49
+ }
50
+ /** True only for objects actually produced by this module's seal functions. */
51
+ function isSealed(value) {
52
+ return typeof value === 'object' && value !== null && value[SEALED_TAG] === true;
53
+ }
54
+ /**
55
+ * Truncate a value to a bounded string for the `input` field. NOT
56
+ * governance-complete on its own — pair with `sealForMetadata` for
57
+ * anything that should be part of the certificate's binding in full.
58
+ */
59
+ function truncateForClassifier(value, limit = DEFAULT_LIMIT) {
60
+ if (value === null || value === undefined)
61
+ return null;
62
+ try {
63
+ const s = typeof value === 'string' ? value : JSON.stringify(value);
64
+ return s.slice(0, limit);
65
+ }
66
+ catch {
67
+ return null;
68
+ }
69
+ }
70
+ /**
71
+ * Recursively sanitize a value into something JSON-safe, replacing only
72
+ * the individual fields that cannot serialize instead of the whole value.
73
+ *
74
+ * A prior version of `sealForMetadata` caught JSON.stringify failure at the
75
+ * TOP level only: one bad field anywhere in a large object (an AbortSignal,
76
+ * a callback, a class instance a provider SDK attaches) collapsed the
77
+ * ENTIRE sealed value to a fixed placeholder string. The certificate digest
78
+ * still matched between issuance and re-execution — both times hashing the
79
+ * same placeholder — so verification silently became a no-op for every
80
+ * other field in that payload, not just the one that couldn't serialize.
81
+ *
82
+ * This also does NOT delegate to `JSON.stringify` for detection: a function,
83
+ * Symbol, Map, or Set value doesn't throw there — `JSON.stringify` silently
84
+ * DROPS it (an object key vanishes, an array element becomes `null`), which
85
+ * is the exact material-field-omission failure mode this module exists to
86
+ * prevent, just reproduced one level deeper. Every branch below is explicit
87
+ * so nothing is dropped without leaving a marker in its place.
88
+ */
89
+ function safeSerialize(value, seen = new WeakSet()) {
90
+ if (value === undefined)
91
+ return '[unserializable:undefined]';
92
+ if (value === null)
93
+ return null;
94
+ const t = typeof value;
95
+ if (t === 'string' || t === 'number' || t === 'boolean')
96
+ return value;
97
+ if (t === 'bigint')
98
+ return '[unserializable:bigint]';
99
+ if (t === 'function')
100
+ return '[unserializable:function]';
101
+ if (t === 'symbol')
102
+ return '[unserializable:symbol]';
103
+ const obj = value;
104
+ if (seen.has(obj))
105
+ return '[unserializable:circular]';
106
+ if (Array.isArray(obj)) {
107
+ seen.add(obj);
108
+ const out = obj.map((v) => safeSerialize(v, seen));
109
+ seen.delete(obj);
110
+ return out;
111
+ }
112
+ if (obj instanceof Date)
113
+ return obj.toISOString();
114
+ if (obj instanceof Map || obj instanceof Set)
115
+ return `[unserializable:${obj.constructor.name}]`;
116
+ seen.add(obj);
117
+ const out = {};
118
+ for (const key of Object.keys(obj)) {
119
+ out[key] = safeSerialize(obj[key], seen);
120
+ }
121
+ seen.delete(obj);
122
+ return out;
123
+ }
124
+ /**
125
+ * Validate a value is JSON-safe before it is embedded in `metadata`,
126
+ * replacing any individual non-serializable field with a marker rather than
127
+ * failing the whole value — see `safeSerialize` for why per-field, not
128
+ * whole-object. A raw, unvalidated object here (a circular reference, a
129
+ * BigInt, ...) would otherwise throw inside JSON.stringify at the HTTP
130
+ * layer. That throw is caught by enforcePolicy's network-error handler
131
+ * (indistinguishable from a real outage) and, under the default fail_open
132
+ * policy, silently ALLOWS the call — a governance bypass that reproduces
133
+ * on every single call with that payload shape, not a transient blip.
134
+ */
135
+ function sealForMetadata(value) {
136
+ if (value === undefined || value === null)
137
+ return undefined;
138
+ return safeSerialize(value);
139
+ }
140
+ /**
141
+ * Seal the ACTUAL raw request object an adapter is about to hand the
142
+ * provider SDK — every own-enumerable field, by default, not a hand-picked
143
+ * subset. `exclude` strips named fields (transport-only concerns: an
144
+ * AbortSignal, a streaming callback) and defaults to empty — start maximal,
145
+ * add an exclusion only when a specific field demonstrably needs it.
146
+ *
147
+ * This exists because a hand-picked inclusion list (`{ model, messages }`)
148
+ * silently stops covering a field the day the provider SDK adds one and the
149
+ * adapter isn't updated — the certificate binds to less than what actually
150
+ * executes, with no error, no test failure, nothing to notice. Sealing the
151
+ * whole object flips the default: a NEW provider field is covered
152
+ * automatically, and omitting one requires a deliberate, reviewable entry
153
+ * in `exclude` instead of an easy-to-forget addition to an inclusion list.
154
+ */
155
+ function sealFullRequest(request, exclude = []) {
156
+ if (!request || typeof request !== 'object')
157
+ return brand({});
158
+ const excluded = new Set(exclude);
159
+ const out = {};
160
+ for (const key of Object.keys(request)) {
161
+ if (excluded.has(key))
162
+ continue;
163
+ out[key] = safeSerialize(request[key]);
164
+ }
165
+ return brand(out);
166
+ }
167
+ /**
168
+ * Convenience: seal `value` under `key` for a `metadata` object, or
169
+ * `undefined` if there is nothing to seal (so callers can spread it —
170
+ * `metadata: sealMetadataEntry('toolArguments', args)` — without an extra
171
+ * null check).
172
+ */
173
+ function sealMetadataEntry(key, value) {
174
+ const sealed = sealForMetadata(value);
175
+ return sealed !== undefined ? brand({ [key]: sealed }) : undefined;
176
+ }
177
+ /**
178
+ * Seal a hand-built metadata object as a whole (e.g. `{ model, messages }`
179
+ * where only some fields need sealing) — for the one call site
180
+ * (`openai-chat.ts`) that combines a sealed field with plain scalars rather
181
+ * than sealing a single field under `sealMetadataEntry`.
182
+ */
183
+ function sealMetadata(value) {
184
+ const sealed = sealForMetadata(value);
185
+ const safe = sealed !== undefined && typeof sealed === 'object' && sealed !== null && !Array.isArray(sealed)
186
+ ? sealed
187
+ : { unserializable: true };
188
+ return brand(safe);
189
+ }
190
+ /**
191
+ * The only sanctioned way for an adapter to call `enforcePolicy`. Requires
192
+ * `metadata` to carry the `SealedMetadata` brand — a bare object literal
193
+ * fails to compile here. Defense-in-depth: also checks the runtime tag, so
194
+ * an `as SealedMetadata` cast around the type system (or a plain-JS caller
195
+ * with no compiler at all) still fails closed via `MetadataContractError`
196
+ * instead of silently reaching the server unsealed.
197
+ */
198
+ async function enforcePolicyBound(exe, opts) {
199
+ if (opts.metadata !== undefined && !isSealed(opts.metadata)) {
200
+ throw new errors_1.MetadataContractError(`metadata for agent '${opts.agentId}' was not produced by sealForMetadata/sealMetadataEntry/sealMetadata`);
201
+ }
202
+ return exe.enforcePolicy(opts);
203
+ }
204
+ //# sourceMappingURL=_actionBinding.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"_actionBinding.js","sourceRoot":"","sources":["../../src/integrations/_actionBinding.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;;AAkCH,sDAQC;AA8DD,0CAGC;AAiBD,0CAYC;AAQD,8CAGC;AAQD,oCAOC;AAUD,gDAUC;AAlLD,sCAAkD;AA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AAC,CAAE,MAAkC;QACrC,CAAC,CAAC,EAAE,cAAc,EAAE,IAAI,EAAE,CAAC;IAC/B,OAAO,KAAK,CAAC,IAAI,CAAC,CAAC;AACrB,CAAC;AAED;;;;;;;GAOG;AACI,KAAK,UAAU,kBAAkB,CACtC,GAAa,EACb,IAA4E;IAE5E,IAAI,IAAI,CAAC,QAAQ,KAAK,SAAS,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC;QAC5D,MAAM,IAAI,8BAAqB,CAC7B,uBAAuB,IAAI,CAAC,OAAO,sEAAsE,CAC1G,CAAC;IACJ,CAAC;IACD,OAAO,GAAG,CAAC,aAAa,CAAC,IAA4B,CAAC,CAAC;AACzD,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"crewai.d.ts","sourceRoot":"","sources":["../../src/integrations/crewai.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAC;AA2B1C,MAAM,WAAW,qBAAqB;IACpC,mEAAmE;IACnE,OAAO,EAAE,MAAM,CAAC;IAChB,uDAAuD;IACvD,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,GAAG,EAAE,QAAQ,EAAE,IAAI,EAAE,qBAAqB,GAAG,CAAC,CAqDxF"}
1
+ {"version":3,"file":"crewai.d.ts","sourceRoot":"","sources":["../../src/integrations/crewai.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAC;AAY1C,MAAM,WAAW,qBAAqB;IACpC,mEAAmE;IACnE,OAAO,EAAE,MAAM,CAAC;IAChB,uDAAuD;IACvD,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,GAAG,EAAE,QAAQ,EAAE,IAAI,EAAE,qBAAqB,GAAG,CAAC,CAqDxF"}