agent-swarm-kit 1.2.5 → 1.3.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.
- package/build/index.cjs +15 -12
- package/build/index.mjs +15 -12
- package/package.json +1 -1
- package/types.d.ts +1 -1
package/build/index.cjs
CHANGED
|
@@ -9249,6 +9249,9 @@ class AgentValidationService {
|
|
|
9249
9249
|
targetAgentName,
|
|
9250
9250
|
depAgentName,
|
|
9251
9251
|
});
|
|
9252
|
+
if (targetAgentName === depAgentName) {
|
|
9253
|
+
return true;
|
|
9254
|
+
}
|
|
9252
9255
|
if (this._agentDepsMap.has(targetAgentName)) {
|
|
9253
9256
|
return this._agentDepsMap.get(targetAgentName).includes(depAgentName);
|
|
9254
9257
|
}
|
|
@@ -19163,7 +19166,7 @@ const overrideCompletionInternal = beginContext(async (publicCompletionSchema) =
|
|
|
19163
19166
|
swarm$1.loggerService.log(METHOD_NAME$14, {
|
|
19164
19167
|
completionSchema: publicCompletionSchema,
|
|
19165
19168
|
});
|
|
19166
|
-
await swarm$1.
|
|
19169
|
+
await swarm$1.completionValidationService.validate(publicCompletionSchema.completionName, METHOD_NAME$14);
|
|
19167
19170
|
const completionSchema = mapCompletionSchema(publicCompletionSchema);
|
|
19168
19171
|
return swarm$1.completionSchemaService.override(completionSchema.completionName, completionSchema);
|
|
19169
19172
|
});
|
|
@@ -19200,7 +19203,7 @@ const overrideEmbedingInternal = beginContext(async (publicEmbeddingSchema) => {
|
|
|
19200
19203
|
swarm$1.loggerService.log(METHOD_NAME$13, {
|
|
19201
19204
|
embeddingSchema: publicEmbeddingSchema,
|
|
19202
19205
|
});
|
|
19203
|
-
await swarm$1.
|
|
19206
|
+
await swarm$1.embeddingValidationService.validate(publicEmbeddingSchema.embeddingName, METHOD_NAME$13);
|
|
19204
19207
|
const embeddingSchema = removeUndefined(publicEmbeddingSchema);
|
|
19205
19208
|
return swarm$1.embeddingSchemaService.override(embeddingSchema.embeddingName, embeddingSchema);
|
|
19206
19209
|
});
|
|
@@ -19238,7 +19241,7 @@ const overridePolicyInternal = beginContext(async (publicPolicySchema) => {
|
|
|
19238
19241
|
swarm$1.loggerService.log(METHOD_NAME$12, {
|
|
19239
19242
|
policySchema: publicPolicySchema,
|
|
19240
19243
|
});
|
|
19241
|
-
await swarm$1.
|
|
19244
|
+
await swarm$1.policyValidationService.validate(publicPolicySchema.policyName, METHOD_NAME$12);
|
|
19242
19245
|
const policySchema = removeUndefined(publicPolicySchema);
|
|
19243
19246
|
return swarm$1.policySchemaService.override(policySchema.policyName, policySchema);
|
|
19244
19247
|
});
|
|
@@ -19274,7 +19277,7 @@ const overrideStateInternal = beginContext(async (publicStateSchema) => {
|
|
|
19274
19277
|
swarm$1.loggerService.log(METHOD_NAME$11, {
|
|
19275
19278
|
stateSchema: publicStateSchema,
|
|
19276
19279
|
});
|
|
19277
|
-
await swarm$1.
|
|
19280
|
+
await swarm$1.stateValidationService.validate(publicStateSchema.stateName, METHOD_NAME$11);
|
|
19278
19281
|
const stateSchema = removeUndefined(publicStateSchema);
|
|
19279
19282
|
return swarm$1.stateSchemaService.override(stateSchema.stateName, stateSchema);
|
|
19280
19283
|
});
|
|
@@ -19311,7 +19314,7 @@ const overrideStorageInternal = beginContext(async (publicStorageSchema) => {
|
|
|
19311
19314
|
swarm$1.loggerService.log(METHOD_NAME$10, {
|
|
19312
19315
|
storageSchema: publicStorageSchema,
|
|
19313
19316
|
});
|
|
19314
|
-
await swarm$1.
|
|
19317
|
+
await swarm$1.storageValidationService.validate(publicStorageSchema.storageName, METHOD_NAME$10);
|
|
19315
19318
|
const storageSchema = removeUndefined(publicStorageSchema);
|
|
19316
19319
|
return swarm$1.storageSchemaService.override(storageSchema.storageName, storageSchema);
|
|
19317
19320
|
});
|
|
@@ -19349,7 +19352,7 @@ const overrideSwarmInternal = beginContext(async (publicSwarmSchema) => {
|
|
|
19349
19352
|
swarm$1.loggerService.log(METHOD_NAME$$, {
|
|
19350
19353
|
swarmSchema: publicSwarmSchema,
|
|
19351
19354
|
});
|
|
19352
|
-
await swarm$1.
|
|
19355
|
+
await swarm$1.swarmValidationService.validate(publicSwarmSchema.swarmName, METHOD_NAME$$);
|
|
19353
19356
|
const swarmSchema = removeUndefined(publicSwarmSchema);
|
|
19354
19357
|
return swarm$1.swarmSchemaService.override(swarmSchema.swarmName, swarmSchema);
|
|
19355
19358
|
});
|
|
@@ -19385,7 +19388,7 @@ const overrideToolInternal = beginContext(async (publicToolSchema) => {
|
|
|
19385
19388
|
swarm$1.loggerService.log(METHOD_NAME$_, {
|
|
19386
19389
|
toolSchema: publicToolSchema,
|
|
19387
19390
|
});
|
|
19388
|
-
await swarm$1.
|
|
19391
|
+
await swarm$1.toolValidationService.validate(publicToolSchema.toolName, METHOD_NAME$_);
|
|
19389
19392
|
const toolSchema = removeUndefined(publicToolSchema);
|
|
19390
19393
|
return swarm$1.toolSchemaService.override(toolSchema.toolName, toolSchema);
|
|
19391
19394
|
});
|
|
@@ -19420,7 +19423,7 @@ const overrideMCPInternal = beginContext(async (publicMcpSchema) => {
|
|
|
19420
19423
|
swarm$1.loggerService.log(METHOD_NAME$Z, {
|
|
19421
19424
|
mcpSchema: publicMcpSchema,
|
|
19422
19425
|
});
|
|
19423
|
-
await swarm$1.
|
|
19426
|
+
await swarm$1.mcpValidationService.validate(publicMcpSchema.mcpName, METHOD_NAME$Z);
|
|
19424
19427
|
const mcpSchema = removeUndefined(publicMcpSchema);
|
|
19425
19428
|
return swarm$1.mcpSchemaService.override(mcpSchema.mcpName, mcpSchema);
|
|
19426
19429
|
});
|
|
@@ -19441,7 +19444,7 @@ const overrideAdvisorInternal = beginContext(async (publicAdvisorSchema) => {
|
|
|
19441
19444
|
swarm$1.loggerService.log(METHOD_NAME$Y, {
|
|
19442
19445
|
advisorSchema: publicAdvisorSchema,
|
|
19443
19446
|
});
|
|
19444
|
-
await swarm$1.
|
|
19447
|
+
await swarm$1.advisorValidationService.validate(publicAdvisorSchema.advisorName, METHOD_NAME$Y);
|
|
19445
19448
|
const advisorSchema = removeUndefined(publicAdvisorSchema);
|
|
19446
19449
|
return swarm$1.advisorSchemaService.override(advisorSchema.advisorName, advisorSchema);
|
|
19447
19450
|
});
|
|
@@ -19495,7 +19498,7 @@ const overrideComputeInternal = beginContext(async (publicComputeSchema) => {
|
|
|
19495
19498
|
swarm$1.loggerService.log(METHOD_NAME$X, {
|
|
19496
19499
|
computeSchema: publicComputeSchema,
|
|
19497
19500
|
});
|
|
19498
|
-
await swarm$1.
|
|
19501
|
+
await swarm$1.computeValidationService.validate(publicComputeSchema.computeName, METHOD_NAME$X);
|
|
19499
19502
|
const computeSchema = removeUndefined(publicComputeSchema);
|
|
19500
19503
|
return swarm$1.computeSchemaService.override(computeSchema.computeName, computeSchema);
|
|
19501
19504
|
});
|
|
@@ -19526,7 +19529,7 @@ const overridePipelineInternal = beginContext(async (publicPipelineSchema) => {
|
|
|
19526
19529
|
swarm$1.loggerService.log(METHOD_NAME$W, {
|
|
19527
19530
|
pipelineSchema: publicPipelineSchema,
|
|
19528
19531
|
});
|
|
19529
|
-
await swarm$1.
|
|
19532
|
+
await swarm$1.pipelineValidationService.validate(publicPipelineSchema.pipelineName, METHOD_NAME$W);
|
|
19530
19533
|
const pipelineSchema = removeUndefined(publicPipelineSchema);
|
|
19531
19534
|
return swarm$1.pipelineSchemaService.override(pipelineSchema.pipelineName, pipelineSchema);
|
|
19532
19535
|
});
|
|
@@ -19557,7 +19560,7 @@ const overrideOutlineInternal = beginContext(async (publicOutlineSchema) => {
|
|
|
19557
19560
|
swarm$1.loggerService.log(METHOD_NAME$V, {
|
|
19558
19561
|
outlineSchema: publicOutlineSchema,
|
|
19559
19562
|
});
|
|
19560
|
-
await swarm$1.
|
|
19563
|
+
await swarm$1.outlineValidationService.validate(publicOutlineSchema.outlineName, METHOD_NAME$V);
|
|
19561
19564
|
const outlineSchema = removeUndefined(publicOutlineSchema);
|
|
19562
19565
|
return swarm$1.outlineSchemaService.override(outlineSchema.outlineName, outlineSchema);
|
|
19563
19566
|
});
|
package/build/index.mjs
CHANGED
|
@@ -9229,6 +9229,9 @@ class AgentValidationService {
|
|
|
9229
9229
|
targetAgentName,
|
|
9230
9230
|
depAgentName,
|
|
9231
9231
|
});
|
|
9232
|
+
if (targetAgentName === depAgentName) {
|
|
9233
|
+
return true;
|
|
9234
|
+
}
|
|
9232
9235
|
if (this._agentDepsMap.has(targetAgentName)) {
|
|
9233
9236
|
return this._agentDepsMap.get(targetAgentName).includes(depAgentName);
|
|
9234
9237
|
}
|
|
@@ -19143,7 +19146,7 @@ const overrideCompletionInternal = beginContext(async (publicCompletionSchema) =
|
|
|
19143
19146
|
swarm$1.loggerService.log(METHOD_NAME$14, {
|
|
19144
19147
|
completionSchema: publicCompletionSchema,
|
|
19145
19148
|
});
|
|
19146
|
-
await swarm$1.
|
|
19149
|
+
await swarm$1.completionValidationService.validate(publicCompletionSchema.completionName, METHOD_NAME$14);
|
|
19147
19150
|
const completionSchema = mapCompletionSchema(publicCompletionSchema);
|
|
19148
19151
|
return swarm$1.completionSchemaService.override(completionSchema.completionName, completionSchema);
|
|
19149
19152
|
});
|
|
@@ -19180,7 +19183,7 @@ const overrideEmbedingInternal = beginContext(async (publicEmbeddingSchema) => {
|
|
|
19180
19183
|
swarm$1.loggerService.log(METHOD_NAME$13, {
|
|
19181
19184
|
embeddingSchema: publicEmbeddingSchema,
|
|
19182
19185
|
});
|
|
19183
|
-
await swarm$1.
|
|
19186
|
+
await swarm$1.embeddingValidationService.validate(publicEmbeddingSchema.embeddingName, METHOD_NAME$13);
|
|
19184
19187
|
const embeddingSchema = removeUndefined(publicEmbeddingSchema);
|
|
19185
19188
|
return swarm$1.embeddingSchemaService.override(embeddingSchema.embeddingName, embeddingSchema);
|
|
19186
19189
|
});
|
|
@@ -19218,7 +19221,7 @@ const overridePolicyInternal = beginContext(async (publicPolicySchema) => {
|
|
|
19218
19221
|
swarm$1.loggerService.log(METHOD_NAME$12, {
|
|
19219
19222
|
policySchema: publicPolicySchema,
|
|
19220
19223
|
});
|
|
19221
|
-
await swarm$1.
|
|
19224
|
+
await swarm$1.policyValidationService.validate(publicPolicySchema.policyName, METHOD_NAME$12);
|
|
19222
19225
|
const policySchema = removeUndefined(publicPolicySchema);
|
|
19223
19226
|
return swarm$1.policySchemaService.override(policySchema.policyName, policySchema);
|
|
19224
19227
|
});
|
|
@@ -19254,7 +19257,7 @@ const overrideStateInternal = beginContext(async (publicStateSchema) => {
|
|
|
19254
19257
|
swarm$1.loggerService.log(METHOD_NAME$11, {
|
|
19255
19258
|
stateSchema: publicStateSchema,
|
|
19256
19259
|
});
|
|
19257
|
-
await swarm$1.
|
|
19260
|
+
await swarm$1.stateValidationService.validate(publicStateSchema.stateName, METHOD_NAME$11);
|
|
19258
19261
|
const stateSchema = removeUndefined(publicStateSchema);
|
|
19259
19262
|
return swarm$1.stateSchemaService.override(stateSchema.stateName, stateSchema);
|
|
19260
19263
|
});
|
|
@@ -19291,7 +19294,7 @@ const overrideStorageInternal = beginContext(async (publicStorageSchema) => {
|
|
|
19291
19294
|
swarm$1.loggerService.log(METHOD_NAME$10, {
|
|
19292
19295
|
storageSchema: publicStorageSchema,
|
|
19293
19296
|
});
|
|
19294
|
-
await swarm$1.
|
|
19297
|
+
await swarm$1.storageValidationService.validate(publicStorageSchema.storageName, METHOD_NAME$10);
|
|
19295
19298
|
const storageSchema = removeUndefined(publicStorageSchema);
|
|
19296
19299
|
return swarm$1.storageSchemaService.override(storageSchema.storageName, storageSchema);
|
|
19297
19300
|
});
|
|
@@ -19329,7 +19332,7 @@ const overrideSwarmInternal = beginContext(async (publicSwarmSchema) => {
|
|
|
19329
19332
|
swarm$1.loggerService.log(METHOD_NAME$$, {
|
|
19330
19333
|
swarmSchema: publicSwarmSchema,
|
|
19331
19334
|
});
|
|
19332
|
-
await swarm$1.
|
|
19335
|
+
await swarm$1.swarmValidationService.validate(publicSwarmSchema.swarmName, METHOD_NAME$$);
|
|
19333
19336
|
const swarmSchema = removeUndefined(publicSwarmSchema);
|
|
19334
19337
|
return swarm$1.swarmSchemaService.override(swarmSchema.swarmName, swarmSchema);
|
|
19335
19338
|
});
|
|
@@ -19365,7 +19368,7 @@ const overrideToolInternal = beginContext(async (publicToolSchema) => {
|
|
|
19365
19368
|
swarm$1.loggerService.log(METHOD_NAME$_, {
|
|
19366
19369
|
toolSchema: publicToolSchema,
|
|
19367
19370
|
});
|
|
19368
|
-
await swarm$1.
|
|
19371
|
+
await swarm$1.toolValidationService.validate(publicToolSchema.toolName, METHOD_NAME$_);
|
|
19369
19372
|
const toolSchema = removeUndefined(publicToolSchema);
|
|
19370
19373
|
return swarm$1.toolSchemaService.override(toolSchema.toolName, toolSchema);
|
|
19371
19374
|
});
|
|
@@ -19400,7 +19403,7 @@ const overrideMCPInternal = beginContext(async (publicMcpSchema) => {
|
|
|
19400
19403
|
swarm$1.loggerService.log(METHOD_NAME$Z, {
|
|
19401
19404
|
mcpSchema: publicMcpSchema,
|
|
19402
19405
|
});
|
|
19403
|
-
await swarm$1.
|
|
19406
|
+
await swarm$1.mcpValidationService.validate(publicMcpSchema.mcpName, METHOD_NAME$Z);
|
|
19404
19407
|
const mcpSchema = removeUndefined(publicMcpSchema);
|
|
19405
19408
|
return swarm$1.mcpSchemaService.override(mcpSchema.mcpName, mcpSchema);
|
|
19406
19409
|
});
|
|
@@ -19421,7 +19424,7 @@ const overrideAdvisorInternal = beginContext(async (publicAdvisorSchema) => {
|
|
|
19421
19424
|
swarm$1.loggerService.log(METHOD_NAME$Y, {
|
|
19422
19425
|
advisorSchema: publicAdvisorSchema,
|
|
19423
19426
|
});
|
|
19424
|
-
await swarm$1.
|
|
19427
|
+
await swarm$1.advisorValidationService.validate(publicAdvisorSchema.advisorName, METHOD_NAME$Y);
|
|
19425
19428
|
const advisorSchema = removeUndefined(publicAdvisorSchema);
|
|
19426
19429
|
return swarm$1.advisorSchemaService.override(advisorSchema.advisorName, advisorSchema);
|
|
19427
19430
|
});
|
|
@@ -19475,7 +19478,7 @@ const overrideComputeInternal = beginContext(async (publicComputeSchema) => {
|
|
|
19475
19478
|
swarm$1.loggerService.log(METHOD_NAME$X, {
|
|
19476
19479
|
computeSchema: publicComputeSchema,
|
|
19477
19480
|
});
|
|
19478
|
-
await swarm$1.
|
|
19481
|
+
await swarm$1.computeValidationService.validate(publicComputeSchema.computeName, METHOD_NAME$X);
|
|
19479
19482
|
const computeSchema = removeUndefined(publicComputeSchema);
|
|
19480
19483
|
return swarm$1.computeSchemaService.override(computeSchema.computeName, computeSchema);
|
|
19481
19484
|
});
|
|
@@ -19506,7 +19509,7 @@ const overridePipelineInternal = beginContext(async (publicPipelineSchema) => {
|
|
|
19506
19509
|
swarm$1.loggerService.log(METHOD_NAME$W, {
|
|
19507
19510
|
pipelineSchema: publicPipelineSchema,
|
|
19508
19511
|
});
|
|
19509
|
-
await swarm$1.
|
|
19512
|
+
await swarm$1.pipelineValidationService.validate(publicPipelineSchema.pipelineName, METHOD_NAME$W);
|
|
19510
19513
|
const pipelineSchema = removeUndefined(publicPipelineSchema);
|
|
19511
19514
|
return swarm$1.pipelineSchemaService.override(pipelineSchema.pipelineName, pipelineSchema);
|
|
19512
19515
|
});
|
|
@@ -19537,7 +19540,7 @@ const overrideOutlineInternal = beginContext(async (publicOutlineSchema) => {
|
|
|
19537
19540
|
swarm$1.loggerService.log(METHOD_NAME$V, {
|
|
19538
19541
|
outlineSchema: publicOutlineSchema,
|
|
19539
19542
|
});
|
|
19540
|
-
await swarm$1.
|
|
19543
|
+
await swarm$1.outlineValidationService.validate(publicOutlineSchema.outlineName, METHOD_NAME$V);
|
|
19541
19544
|
const outlineSchema = removeUndefined(publicOutlineSchema);
|
|
19542
19545
|
return swarm$1.outlineSchemaService.override(outlineSchema.outlineName, outlineSchema);
|
|
19543
19546
|
});
|
package/package.json
CHANGED
package/types.d.ts
CHANGED
|
@@ -1379,7 +1379,7 @@ interface IBaseMessage<Role extends string = BaseMessageRole> {
|
|
|
1379
1379
|
* Represented as binary data (Blob) or base64 strings.
|
|
1380
1380
|
* Used for messages involving visual content (e.g., user-uploaded images or tool-generated visuals).
|
|
1381
1381
|
*/
|
|
1382
|
-
images?: Blob[] | string[];
|
|
1382
|
+
images?: Blob[] | Uint8Array[] | string[];
|
|
1383
1383
|
/**
|
|
1384
1384
|
* Optional identifier of the tool call this message responds to.
|
|
1385
1385
|
* Links tool outputs to their originating requests.
|