skedyul 1.2.41 → 1.2.44
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/cli/commands/agents.d.ts +1 -0
- package/dist/cli/commands/chat.d.ts +1 -0
- package/dist/cli/commands/crm.d.ts +1 -0
- package/dist/cli/commands/skills.d.ts +1 -0
- package/dist/cli/index.js +17637 -6230
- package/dist/cli/utils/auth.js +495 -0
- package/dist/cli/utils/mock-context.d.ts +22 -0
- package/dist/cli/utils/sse.d.ts +100 -0
- package/dist/compiler/compiler.d.ts +12 -0
- package/dist/compiler/index.d.ts +2 -0
- package/dist/compiler/types.d.ts +173 -0
- package/dist/config/index.d.ts +1 -0
- package/dist/config/schema-loader.d.ts +156 -0
- package/dist/config/types/model.d.ts +28 -0
- package/dist/context/index.d.ts +2 -0
- package/dist/context/resolver.d.ts +51 -0
- package/dist/context/types.d.ts +217 -0
- package/dist/dedicated/server.js +23 -10
- package/dist/esm/index.mjs +9630 -449
- package/dist/events/index.d.ts +1 -0
- package/dist/events/types.d.ts +528 -0
- package/dist/index.d.ts +16 -0
- package/dist/index.js +9723 -460
- package/dist/memory/index.d.ts +4 -0
- package/dist/memory/service.d.ts +78 -0
- package/dist/memory/types.d.ts +169 -0
- package/dist/schemas/agent-schema-v3.d.ts +437 -0
- package/dist/schemas/agent-schema-v3.js +539 -0
- package/dist/schemas/agent-schema-v3.mjs +497 -0
- package/dist/schemas/agent-schema.d.ts +1504 -0
- package/dist/schemas/agent-schema.js +7896 -0
- package/dist/schemas/agent-schema.mjs +7867 -0
- package/dist/schemas/crm-schema.d.ts +448 -0
- package/dist/schemas/index.d.ts +2 -0
- package/dist/schemas.d.ts +69 -36
- package/dist/server.js +23 -10
- package/dist/serverless/server.mjs +23 -10
- package/dist/skills/index.d.ts +1 -0
- package/dist/skills/types.d.ts +355 -0
- package/dist/skills/types.js +281 -0
- package/dist/skills/types.mjs +234 -0
- package/dist/triggers/index.d.ts +2 -0
- package/dist/triggers/resolver.d.ts +31 -0
- package/dist/triggers/types.d.ts +313 -0
- package/dist/types/data-blocks.d.ts +105 -0
- package/dist/types/index.d.ts +2 -1
- package/dist/types/tool-response.d.ts +16 -0
- package/dist/types/tool.d.ts +32 -8
- package/dist/workflows/index.d.ts +1 -0
- package/dist/workflows/types.d.ts +295 -0
- package/package.json +19 -1
package/dist/dedicated/server.js
CHANGED
|
@@ -319,16 +319,20 @@ function createContextLogger() {
|
|
|
319
319
|
// src/server/tool-handler.ts
|
|
320
320
|
function buildToolMetadata(registry) {
|
|
321
321
|
return Object.values(registry).map((tool) => {
|
|
322
|
-
const
|
|
323
|
-
const
|
|
322
|
+
const toolConfig = tool.config ?? {};
|
|
323
|
+
const timeout = typeof toolConfig.timeout === "number" && toolConfig.timeout > 0 ? toolConfig.timeout : 1e4;
|
|
324
|
+
const retries = typeof toolConfig.retries === "number" && toolConfig.retries >= 1 ? toolConfig.retries : 1;
|
|
324
325
|
return {
|
|
325
326
|
name: tool.name,
|
|
326
327
|
displayName: tool.label || tool.name,
|
|
327
328
|
description: tool.description,
|
|
328
329
|
inputSchema: getJsonSchemaFromToolSchema(tool.inputSchema),
|
|
329
330
|
outputSchema: getJsonSchemaFromToolSchema(tool.outputSchema),
|
|
330
|
-
|
|
331
|
-
|
|
331
|
+
config: {
|
|
332
|
+
timeout,
|
|
333
|
+
retries,
|
|
334
|
+
completionHints: toolConfig.completionHints
|
|
335
|
+
}
|
|
332
336
|
};
|
|
333
337
|
});
|
|
334
338
|
}
|
|
@@ -437,7 +441,8 @@ function createCallToolHandler(registry, state, onMaxRequests) {
|
|
|
437
441
|
message: "OK",
|
|
438
442
|
toolName
|
|
439
443
|
},
|
|
440
|
-
effect: functionResult.effect
|
|
444
|
+
effect: functionResult.effect,
|
|
445
|
+
dataBlocks: functionResult.dataBlocks
|
|
441
446
|
};
|
|
442
447
|
} catch (error) {
|
|
443
448
|
if (error instanceof AppAuthInvalidError) {
|
|
@@ -800,8 +805,8 @@ function serializeConfig(config) {
|
|
|
800
805
|
tools: registry ? Object.entries(registry).map(([key, tool]) => ({
|
|
801
806
|
name: tool.name || key,
|
|
802
807
|
description: tool.description,
|
|
803
|
-
timeout: tool.timeout,
|
|
804
|
-
retries: tool.retries
|
|
808
|
+
timeout: tool.config?.timeout,
|
|
809
|
+
retries: tool.config?.retries
|
|
805
810
|
})) : [],
|
|
806
811
|
webhooks: webhookRegistry ? Object.values(webhookRegistry).map((w) => ({
|
|
807
812
|
name: w.name,
|
|
@@ -2037,11 +2042,19 @@ function createSkedyulServer(config) {
|
|
|
2037
2042
|
};
|
|
2038
2043
|
}
|
|
2039
2044
|
const outputData = result.output;
|
|
2045
|
+
const dataBlocks = result.dataBlocks;
|
|
2040
2046
|
let structuredContent;
|
|
2041
2047
|
if (outputData) {
|
|
2042
|
-
structuredContent = {
|
|
2043
|
-
|
|
2044
|
-
|
|
2048
|
+
structuredContent = {
|
|
2049
|
+
...outputData,
|
|
2050
|
+
__effect: result.effect,
|
|
2051
|
+
__dataBlocks: dataBlocks
|
|
2052
|
+
};
|
|
2053
|
+
} else if (result.effect || dataBlocks) {
|
|
2054
|
+
structuredContent = {
|
|
2055
|
+
__effect: result.effect,
|
|
2056
|
+
__dataBlocks: dataBlocks
|
|
2057
|
+
};
|
|
2045
2058
|
} else if (hasOutputSchema) {
|
|
2046
2059
|
structuredContent = {};
|
|
2047
2060
|
}
|