@theokit/agents 0.30.0 → 0.30.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/dist/bridge.js CHANGED
@@ -37,7 +37,7 @@ import {
37
37
  translateToUIMessageStream,
38
38
  validateUniqueRoutes,
39
39
  walkAgentMetadata
40
- } from "./chunk-AUOCWGPS.js";
40
+ } from "./chunk-XCQNYAVU.js";
41
41
  import "./chunk-FI6ZG2YP.js";
42
42
  import "./chunk-7QVYU63E.js";
43
43
  export {
@@ -1120,14 +1120,18 @@ function applyTextTransforms(events, opts) {
1120
1120
  return out;
1121
1121
  }
1122
1122
  __name(applyTextTransforms, "applyTextTransforms");
1123
+ function hasZodInputSchema(schema) {
1124
+ return typeof schema?.parse === "function";
1125
+ }
1126
+ __name(hasZodInputSchema, "hasZodInputSchema");
1123
1127
  function buildSdkTools(compiledTools, defineTool, extraSdkTools = []) {
1124
1128
  return [
1125
- ...compiledTools.map((t) => defineTool({
1129
+ ...compiledTools.map((t) => hasZodInputSchema(t.inputSchema) ? defineTool({
1126
1130
  name: t.name,
1127
1131
  description: t.description,
1128
1132
  inputSchema: t.inputSchema,
1129
1133
  handler: t.handler
1130
- })),
1134
+ }) : t),
1131
1135
  ...extraSdkTools
1132
1136
  ];
1133
1137
  }
@@ -2312,4 +2316,4 @@ export {
2312
2316
  generateAgentManifest,
2313
2317
  agentsPlugin
2314
2318
  };
2315
- //# sourceMappingURL=chunk-AUOCWGPS.js.map
2319
+ //# sourceMappingURL=chunk-XCQNYAVU.js.map