@workglow/tasks 0.0.103 → 0.0.105

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 (39) hide show
  1. package/dist/browser.js +1001 -138
  2. package/dist/browser.js.map +19 -5
  3. package/dist/bun.js +1004 -141
  4. package/dist/bun.js.map +19 -5
  5. package/dist/common.d.ts +29 -1
  6. package/dist/common.d.ts.map +1 -1
  7. package/dist/node.js +1004 -141
  8. package/dist/node.js.map +19 -5
  9. package/dist/task/DateFormatTask.d.ts +107 -0
  10. package/dist/task/DateFormatTask.d.ts.map +1 -0
  11. package/dist/task/FetchUrlTask.d.ts +20 -1
  12. package/dist/task/FetchUrlTask.d.ts.map +1 -1
  13. package/dist/task/JsonPathTask.d.ts +77 -0
  14. package/dist/task/JsonPathTask.d.ts.map +1 -0
  15. package/dist/task/RegexTask.d.ts +109 -0
  16. package/dist/task/RegexTask.d.ts.map +1 -0
  17. package/dist/task/TemplateTask.d.ts +89 -0
  18. package/dist/task/TemplateTask.d.ts.map +1 -0
  19. package/dist/task/string/StringConcatTask.d.ts +61 -0
  20. package/dist/task/string/StringConcatTask.d.ts.map +1 -0
  21. package/dist/task/string/StringIncludesTask.d.ts +81 -0
  22. package/dist/task/string/StringIncludesTask.d.ts.map +1 -0
  23. package/dist/task/string/StringJoinTask.d.ts +89 -0
  24. package/dist/task/string/StringJoinTask.d.ts.map +1 -0
  25. package/dist/task/string/StringLengthTask.d.ts +71 -0
  26. package/dist/task/string/StringLengthTask.d.ts.map +1 -0
  27. package/dist/task/string/StringLowerCaseTask.d.ts +71 -0
  28. package/dist/task/string/StringLowerCaseTask.d.ts.map +1 -0
  29. package/dist/task/string/StringReplaceTask.d.ts +91 -0
  30. package/dist/task/string/StringReplaceTask.d.ts.map +1 -0
  31. package/dist/task/string/StringSliceTask.d.ts +91 -0
  32. package/dist/task/string/StringSliceTask.d.ts.map +1 -0
  33. package/dist/task/string/StringTemplateTask.d.ts +83 -0
  34. package/dist/task/string/StringTemplateTask.d.ts.map +1 -0
  35. package/dist/task/string/StringTrimTask.d.ts +71 -0
  36. package/dist/task/string/StringTrimTask.d.ts.map +1 -0
  37. package/dist/task/string/StringUpperCaseTask.d.ts +71 -0
  38. package/dist/task/string/StringUpperCaseTask.d.ts.map +1 -0
  39. package/package.json +9 -9
package/dist/node.js CHANGED
@@ -847,6 +847,13 @@ var inputSchema12 = {
847
847
  title: "Timeout",
848
848
  description: "Request timeout in milliseconds"
849
849
  },
850
+ credential_key: {
851
+ type: "string",
852
+ format: "credential",
853
+ title: "Credential Key",
854
+ description: "Key to look up in the credential store. The resolved value is sent as a Bearer token in the Authorization header.",
855
+ "x-ui-hidden": true
856
+ },
850
857
  queue: {
851
858
  oneOf: [{ type: "boolean" }, { type: "string" }],
852
859
  description: "Queue handling: false=run inline, true=use default, string=explicit queue name",
@@ -954,13 +961,13 @@ class FetchUrlJob extends Job {
954
961
  }, async (progress) => await context.updateProgress(progress));
955
962
  if (response.ok) {
956
963
  const contentType = response.headers.get("content-type") ?? "";
957
- const headers = {};
964
+ const responseHeaders = {};
958
965
  response.headers.forEach((value, key) => {
959
- headers[key] = value;
966
+ responseHeaders[key] = value;
960
967
  });
961
968
  const metadata = {
962
969
  contentType,
963
- headers
970
+ headers: responseHeaders
964
971
  };
965
972
  let responseType = input.response_type;
966
973
  if (!responseType) {
@@ -1064,6 +1071,16 @@ class FetchUrlTask extends JobQueueTask {
1064
1071
  super(input, config);
1065
1072
  this.jobClass = FetchUrlJob;
1066
1073
  }
1074
+ async execute(input, executeContext) {
1075
+ const credential = input.credential_key;
1076
+ if (credential) {
1077
+ input = {
1078
+ ...input,
1079
+ headers: { ...input.headers, Authorization: `Bearer ${credential}` }
1080
+ };
1081
+ }
1082
+ return super.execute(input, executeContext);
1083
+ }
1067
1084
  setInput(input) {
1068
1085
  if (!("response_type" in input)) {
1069
1086
  super.setInput(input);
@@ -6041,14 +6058,326 @@ var split = (input2, config = {}) => {
6041
6058
  return task.run(input2);
6042
6059
  };
6043
6060
  Workflow20.prototype.split = CreateWorkflow19(SplitTask);
6061
+ // src/task/DateFormatTask.ts
6062
+ import {
6063
+ CreateWorkflow as CreateWorkflow20,
6064
+ Task as Task18,
6065
+ Workflow as Workflow21
6066
+ } from "@workglow/task-graph";
6067
+ var inputSchema18 = {
6068
+ type: "object",
6069
+ properties: {
6070
+ value: {
6071
+ type: "string",
6072
+ title: "Value",
6073
+ description: "Date string, ISO 8601 timestamp, or Unix timestamp in milliseconds"
6074
+ },
6075
+ format: {
6076
+ type: "string",
6077
+ title: "Format",
6078
+ enum: ["iso", "date", "time", "datetime", "unix"],
6079
+ description: "Output format: 'iso', 'date', 'time', 'datetime', 'unix'",
6080
+ default: "iso"
6081
+ },
6082
+ locale: {
6083
+ type: "string",
6084
+ title: "Locale",
6085
+ description: "Locale string (e.g. 'en-US')",
6086
+ default: "en-US"
6087
+ },
6088
+ timeZone: {
6089
+ type: "string",
6090
+ title: "Time Zone",
6091
+ description: "IANA time zone (e.g. 'America/New_York', 'UTC')"
6092
+ }
6093
+ },
6094
+ required: ["value"],
6095
+ additionalProperties: false
6096
+ };
6097
+ var outputSchema18 = {
6098
+ type: "object",
6099
+ properties: {
6100
+ result: {
6101
+ type: "string",
6102
+ title: "Result",
6103
+ description: "Formatted date string"
6104
+ }
6105
+ },
6106
+ required: ["result"],
6107
+ additionalProperties: false
6108
+ };
6109
+
6110
+ class DateFormatTask extends Task18 {
6111
+ static type = "DateFormatTask";
6112
+ static category = "Utility";
6113
+ static title = "Date Format";
6114
+ static description = "Parses and formats a date string";
6115
+ static inputSchema() {
6116
+ return inputSchema18;
6117
+ }
6118
+ static outputSchema() {
6119
+ return outputSchema18;
6120
+ }
6121
+ async executeReactive(input2, _output, _context) {
6122
+ const dateInput = /^\d+$/.test(input2.value) ? Number(input2.value) : input2.value;
6123
+ const date = new Date(dateInput);
6124
+ if (isNaN(date.getTime())) {
6125
+ throw new Error(`Invalid date: ${input2.value}`);
6126
+ }
6127
+ const format = input2.format ?? "iso";
6128
+ const locale = input2.locale;
6129
+ const timeZone = input2.timeZone;
6130
+ let result;
6131
+ switch (format) {
6132
+ case "iso":
6133
+ result = date.toISOString();
6134
+ break;
6135
+ case "date":
6136
+ result = date.toLocaleDateString(locale, timeZone ? { timeZone } : undefined);
6137
+ break;
6138
+ case "time":
6139
+ result = date.toLocaleTimeString(locale, timeZone ? { timeZone } : undefined);
6140
+ break;
6141
+ case "unix":
6142
+ result = String(date.getTime());
6143
+ break;
6144
+ case "datetime":
6145
+ default:
6146
+ result = date.toLocaleString(locale, timeZone ? { timeZone } : undefined);
6147
+ break;
6148
+ }
6149
+ return { result };
6150
+ }
6151
+ }
6152
+ Workflow21.prototype.dateFormat = CreateWorkflow20(DateFormatTask);
6153
+ // src/task/JsonPathTask.ts
6154
+ import {
6155
+ CreateWorkflow as CreateWorkflow21,
6156
+ Task as Task19,
6157
+ Workflow as Workflow22
6158
+ } from "@workglow/task-graph";
6159
+ var inputSchema19 = {
6160
+ type: "object",
6161
+ properties: {
6162
+ value: {
6163
+ title: "Value",
6164
+ description: "Input object or array to query"
6165
+ },
6166
+ path: {
6167
+ type: "string",
6168
+ title: "Path",
6169
+ description: "Dot-notation path to extract (e.g. 'a.b.c', 'items.0.name', 'items.*.name')"
6170
+ }
6171
+ },
6172
+ required: ["value", "path"],
6173
+ additionalProperties: false
6174
+ };
6175
+ var outputSchema19 = {
6176
+ type: "object",
6177
+ properties: {
6178
+ result: {
6179
+ title: "Result",
6180
+ description: "Extracted value(s) from the path"
6181
+ }
6182
+ },
6183
+ required: ["result"],
6184
+ additionalProperties: false
6185
+ };
6186
+ function resolvePath(obj, segments) {
6187
+ if (segments.length === 0)
6188
+ return obj;
6189
+ const [head, ...tail] = segments;
6190
+ if (head === "*") {
6191
+ if (Array.isArray(obj)) {
6192
+ return obj.map((item) => resolvePath(item, tail));
6193
+ }
6194
+ if (obj !== null && typeof obj === "object") {
6195
+ return Object.values(obj).map((v) => resolvePath(v, tail));
6196
+ }
6197
+ return;
6198
+ }
6199
+ if (obj === null || obj === undefined || typeof obj !== "object") {
6200
+ return;
6201
+ }
6202
+ const next2 = obj[head];
6203
+ return resolvePath(next2, tail);
6204
+ }
6205
+
6206
+ class JsonPathTask extends Task19 {
6207
+ static type = "JsonPathTask";
6208
+ static category = "Utility";
6209
+ static title = "JSON Path";
6210
+ static description = "Extracts a value from an object using a dot-notation path";
6211
+ static inputSchema() {
6212
+ return inputSchema19;
6213
+ }
6214
+ static outputSchema() {
6215
+ return outputSchema19;
6216
+ }
6217
+ async executeReactive(input2, _output, _context) {
6218
+ const segments = input2.path.split(".");
6219
+ const result = resolvePath(input2.value, segments);
6220
+ return { result };
6221
+ }
6222
+ }
6223
+ Workflow22.prototype.jsonPath = CreateWorkflow21(JsonPathTask);
6224
+ // src/task/RegexTask.ts
6225
+ import {
6226
+ CreateWorkflow as CreateWorkflow22,
6227
+ Task as Task20,
6228
+ Workflow as Workflow23
6229
+ } from "@workglow/task-graph";
6230
+ var inputSchema20 = {
6231
+ type: "object",
6232
+ properties: {
6233
+ value: {
6234
+ type: "string",
6235
+ title: "Value",
6236
+ description: "Input string to match against"
6237
+ },
6238
+ pattern: {
6239
+ type: "string",
6240
+ title: "Pattern",
6241
+ description: "Regular expression pattern"
6242
+ },
6243
+ flags: {
6244
+ type: "string",
6245
+ title: "Flags",
6246
+ description: "Regex flags (e.g. 'g', 'i', 'gi')",
6247
+ default: ""
6248
+ }
6249
+ },
6250
+ required: ["value", "pattern"],
6251
+ additionalProperties: false
6252
+ };
6253
+ var outputSchema20 = {
6254
+ type: "object",
6255
+ properties: {
6256
+ match: {
6257
+ type: "boolean",
6258
+ title: "Match",
6259
+ description: "Whether the pattern matched"
6260
+ },
6261
+ matches: {
6262
+ type: "array",
6263
+ items: { type: "string" },
6264
+ title: "Matches",
6265
+ description: "Array of matched strings (full matches when global, groups when not)"
6266
+ }
6267
+ },
6268
+ required: ["match", "matches"],
6269
+ additionalProperties: false
6270
+ };
6271
+
6272
+ class RegexTask extends Task20 {
6273
+ static type = "RegexTask";
6274
+ static category = "String";
6275
+ static title = "Regex";
6276
+ static description = "Matches a string against a regular expression pattern";
6277
+ static inputSchema() {
6278
+ return inputSchema20;
6279
+ }
6280
+ static outputSchema() {
6281
+ return outputSchema20;
6282
+ }
6283
+ async executeReactive(input2, _output, _context) {
6284
+ const flags = input2.flags ?? "";
6285
+ const regex = new RegExp(input2.pattern, flags);
6286
+ if (flags.includes("g")) {
6287
+ const allMatches = Array.from(input2.value.matchAll(new RegExp(input2.pattern, flags)));
6288
+ return {
6289
+ match: allMatches.length > 0,
6290
+ matches: allMatches.map((m) => m[0])
6291
+ };
6292
+ }
6293
+ const result = regex.exec(input2.value);
6294
+ if (!result) {
6295
+ return { match: false, matches: [] };
6296
+ }
6297
+ return {
6298
+ match: true,
6299
+ matches: result.slice(0)
6300
+ };
6301
+ }
6302
+ }
6303
+ Workflow23.prototype.regex = CreateWorkflow22(RegexTask);
6304
+ // src/task/TemplateTask.ts
6305
+ import {
6306
+ CreateWorkflow as CreateWorkflow23,
6307
+ Task as Task21,
6308
+ Workflow as Workflow24
6309
+ } from "@workglow/task-graph";
6310
+ var inputSchema21 = {
6311
+ type: "object",
6312
+ properties: {
6313
+ template: {
6314
+ type: "string",
6315
+ title: "Template",
6316
+ description: "Template string with {{key}} placeholders; supports {{key|default}} for defaults"
6317
+ },
6318
+ values: {
6319
+ type: "object",
6320
+ title: "Values",
6321
+ description: "Key-value pairs to substitute into the template",
6322
+ additionalProperties: true
6323
+ }
6324
+ },
6325
+ required: ["template", "values"],
6326
+ additionalProperties: false
6327
+ };
6328
+ var outputSchema21 = {
6329
+ type: "object",
6330
+ properties: {
6331
+ result: {
6332
+ type: "string",
6333
+ title: "Result",
6334
+ description: "Rendered template string"
6335
+ }
6336
+ },
6337
+ required: ["result"],
6338
+ additionalProperties: false
6339
+ };
6340
+
6341
+ class TemplateTask extends Task21 {
6342
+ static type = "TemplateTask";
6343
+ static category = "Utility";
6344
+ static title = "Template";
6345
+ static description = "Renders a template string with {{key}} placeholders and optional defaults";
6346
+ static inputSchema() {
6347
+ return inputSchema21;
6348
+ }
6349
+ static outputSchema() {
6350
+ return outputSchema21;
6351
+ }
6352
+ async executeReactive(input2, _output, _context) {
6353
+ const result = input2.template.replace(/\{\{([^}]+)\}\}/g, (_match, expr) => {
6354
+ const [path, defaultValue] = expr.split("|").map((s) => s.trim());
6355
+ const segments = path.split(".");
6356
+ let current = input2.values;
6357
+ for (const segment of segments) {
6358
+ if (current === null || current === undefined || typeof current !== "object") {
6359
+ current = undefined;
6360
+ break;
6361
+ }
6362
+ current = current[segment];
6363
+ }
6364
+ if (current !== undefined && current !== null) {
6365
+ return String(current);
6366
+ }
6367
+ return defaultValue !== undefined ? defaultValue : "";
6368
+ });
6369
+ return { result };
6370
+ }
6371
+ }
6372
+ Workflow24.prototype.template = CreateWorkflow23(TemplateTask);
6044
6373
  // src/task/mcp/McpListTask.ts
6045
- import { CreateWorkflow as CreateWorkflow20, Task as Task18, Workflow as Workflow21 } from "@workglow/task-graph";
6374
+ import { CreateWorkflow as CreateWorkflow24, Task as Task22, Workflow as Workflow25 } from "@workglow/task-graph";
6046
6375
  import {
6047
6376
  mcpClientFactory,
6048
6377
  mcpServerConfigSchema
6049
6378
  } from "@workglow/util";
6050
6379
  var mcpListTypes = ["tools", "resources", "prompts"];
6051
- var inputSchema18 = {
6380
+ var inputSchema22 = {
6052
6381
  type: "object",
6053
6382
  properties: {
6054
6383
  ...mcpServerConfigSchema,
@@ -6217,7 +6546,7 @@ var outputSchemaAll = {
6217
6546
  additionalProperties: false
6218
6547
  };
6219
6548
 
6220
- class McpListTask extends Task18 {
6549
+ class McpListTask extends Task22 {
6221
6550
  static type = "McpListTask";
6222
6551
  static category = "MCP";
6223
6552
  static title = "MCP List";
@@ -6225,7 +6554,7 @@ class McpListTask extends Task18 {
6225
6554
  static cacheable = false;
6226
6555
  static hasDynamicSchemas = true;
6227
6556
  static inputSchema() {
6228
- return inputSchema18;
6557
+ return inputSchema22;
6229
6558
  }
6230
6559
  static outputSchema() {
6231
6560
  return outputSchemaAll;
@@ -6285,13 +6614,13 @@ class McpListTask extends Task18 {
6285
6614
  var mcpList = async (input2, config = {}) => {
6286
6615
  return new McpListTask({}, config).run(input2);
6287
6616
  };
6288
- Workflow21.prototype.mcpList = CreateWorkflow20(McpListTask);
6617
+ Workflow25.prototype.mcpList = CreateWorkflow24(McpListTask);
6289
6618
  // src/task/mcp/McpPromptGetTask.ts
6290
6619
  import {
6291
- CreateWorkflow as CreateWorkflow21,
6292
- Task as Task19,
6620
+ CreateWorkflow as CreateWorkflow25,
6621
+ Task as Task23,
6293
6622
  TaskConfigSchema as TaskConfigSchema5,
6294
- Workflow as Workflow22
6623
+ Workflow as Workflow26
6295
6624
  } from "@workglow/task-graph";
6296
6625
  import {
6297
6626
  mcpClientFactory as mcpClientFactory2,
@@ -6448,7 +6777,7 @@ var fallbackInputSchema = {
6448
6777
  additionalProperties: false
6449
6778
  };
6450
6779
 
6451
- class McpPromptGetTask extends Task19 {
6780
+ class McpPromptGetTask extends Task23 {
6452
6781
  static type = "McpPromptGetTask";
6453
6782
  static category = "MCP";
6454
6783
  static title = "MCP Get Prompt";
@@ -6532,13 +6861,13 @@ class McpPromptGetTask extends Task19 {
6532
6861
  var mcpPromptGet = async (input2, config) => {
6533
6862
  return new McpPromptGetTask({}, config).run(input2);
6534
6863
  };
6535
- Workflow22.prototype.mcpPromptGet = CreateWorkflow21(McpPromptGetTask);
6864
+ Workflow26.prototype.mcpPromptGet = CreateWorkflow25(McpPromptGetTask);
6536
6865
  // src/task/mcp/McpResourceReadTask.ts
6537
6866
  import {
6538
- CreateWorkflow as CreateWorkflow22,
6539
- Task as Task20,
6867
+ CreateWorkflow as CreateWorkflow26,
6868
+ Task as Task24,
6540
6869
  TaskConfigSchema as TaskConfigSchema6,
6541
- Workflow as Workflow23
6870
+ Workflow as Workflow27
6542
6871
  } from "@workglow/task-graph";
6543
6872
  import {
6544
6873
  mcpClientFactory as mcpClientFactory3,
@@ -6588,12 +6917,12 @@ var contentItemSchema = {
6588
6917
  }
6589
6918
  ]
6590
6919
  };
6591
- var inputSchema19 = {
6920
+ var inputSchema23 = {
6592
6921
  type: "object",
6593
6922
  properties: {},
6594
6923
  additionalProperties: false
6595
6924
  };
6596
- var outputSchema18 = {
6925
+ var outputSchema22 = {
6597
6926
  type: "object",
6598
6927
  properties: {
6599
6928
  contents: {
@@ -6607,7 +6936,7 @@ var outputSchema18 = {
6607
6936
  additionalProperties: false
6608
6937
  };
6609
6938
 
6610
- class McpResourceReadTask extends Task20 {
6939
+ class McpResourceReadTask extends Task24 {
6611
6940
  static type = "McpResourceReadTask";
6612
6941
  static category = "MCP";
6613
6942
  static title = "MCP Read Resource";
@@ -6615,10 +6944,10 @@ class McpResourceReadTask extends Task20 {
6615
6944
  static cacheable = false;
6616
6945
  static customizable = true;
6617
6946
  static inputSchema() {
6618
- return inputSchema19;
6947
+ return inputSchema23;
6619
6948
  }
6620
6949
  static outputSchema() {
6621
- return outputSchema18;
6950
+ return outputSchema22;
6622
6951
  }
6623
6952
  static configSchema() {
6624
6953
  return configSchema3;
@@ -6636,13 +6965,13 @@ class McpResourceReadTask extends Task20 {
6636
6965
  var mcpResourceRead = async (config) => {
6637
6966
  return new McpResourceReadTask({}, config).run({});
6638
6967
  };
6639
- Workflow23.prototype.mcpResourceRead = CreateWorkflow22(McpResourceReadTask);
6968
+ Workflow27.prototype.mcpResourceRead = CreateWorkflow26(McpResourceReadTask);
6640
6969
  // src/task/mcp/McpToolCallTask.ts
6641
6970
  import {
6642
- CreateWorkflow as CreateWorkflow23,
6643
- Task as Task21,
6971
+ CreateWorkflow as CreateWorkflow27,
6972
+ Task as Task25,
6644
6973
  TaskConfigSchema as TaskConfigSchema7,
6645
- Workflow as Workflow24
6974
+ Workflow as Workflow28
6646
6975
  } from "@workglow/task-graph";
6647
6976
  import {
6648
6977
  mcpClientFactory as mcpClientFactory4,
@@ -6791,7 +7120,7 @@ var fallbackInputSchema2 = {
6791
7120
  additionalProperties: true
6792
7121
  };
6793
7122
 
6794
- class McpToolCallTask extends Task21 {
7123
+ class McpToolCallTask extends Task25 {
6795
7124
  static type = "McpToolCallTask";
6796
7125
  static category = "MCP";
6797
7126
  static title = "MCP Call Tool";
@@ -6890,69 +7219,575 @@ class McpToolCallTask extends Task21 {
6890
7219
  var mcpToolCall = async (input2, config) => {
6891
7220
  return new McpToolCallTask({}, config).run(input2);
6892
7221
  };
6893
- Workflow24.prototype.mcpToolCall = CreateWorkflow23(McpToolCallTask);
6894
- // src/task/scalar/ScalarAbsTask.ts
6895
- import { CreateWorkflow as CreateWorkflow24, Task as Task22, Workflow as Workflow25 } from "@workglow/task-graph";
6896
- var inputSchema20 = {
7222
+ Workflow28.prototype.mcpToolCall = CreateWorkflow27(McpToolCallTask);
7223
+ // src/task/string/StringConcatTask.ts
7224
+ import {
7225
+ CreateWorkflow as CreateWorkflow28,
7226
+ Task as Task26,
7227
+ Workflow as Workflow29
7228
+ } from "@workglow/task-graph";
7229
+ var inputSchema24 = {
6897
7230
  type: "object",
6898
- properties: {
6899
- value: {
6900
- type: "number",
6901
- title: "Value",
6902
- description: "Input number"
6903
- }
6904
- },
6905
- required: ["value"],
6906
- additionalProperties: false
7231
+ properties: {},
7232
+ additionalProperties: { type: "string" }
6907
7233
  };
6908
- var outputSchema19 = {
7234
+ var outputSchema23 = {
6909
7235
  type: "object",
6910
7236
  properties: {
6911
7237
  result: {
6912
- type: "number",
7238
+ type: "string",
6913
7239
  title: "Result",
6914
- description: "Absolute value"
7240
+ description: "Concatenation of all input strings"
6915
7241
  }
6916
7242
  },
6917
7243
  required: ["result"],
6918
7244
  additionalProperties: false
6919
7245
  };
6920
7246
 
6921
- class ScalarAbsTask extends Task22 {
6922
- static type = "ScalarAbsTask";
6923
- static category = "Math";
6924
- static title = "Abs";
6925
- static description = "Returns the absolute value of a number";
7247
+ class StringConcatTask extends Task26 {
7248
+ static type = "StringConcatTask";
7249
+ static category = "String";
7250
+ static title = "Concat";
7251
+ static description = "Concatenates all input strings";
6926
7252
  static inputSchema() {
6927
- return inputSchema20;
7253
+ return inputSchema24;
6928
7254
  }
6929
7255
  static outputSchema() {
6930
- return outputSchema19;
7256
+ return outputSchema23;
6931
7257
  }
6932
- async execute(input2, _context) {
6933
- return { result: Math.abs(input2.value) };
7258
+ async executeReactive(input2, _output, _context) {
7259
+ return { result: Object.values(input2).join("") };
6934
7260
  }
6935
7261
  }
6936
- Workflow25.prototype.scalarAbs = CreateWorkflow24(ScalarAbsTask);
6937
- // src/task/scalar/ScalarCeilTask.ts
6938
- import { CreateWorkflow as CreateWorkflow25, Task as Task23, Workflow as Workflow26 } from "@workglow/task-graph";
6939
- var inputSchema21 = {
7262
+ Workflow29.prototype.stringConcat = CreateWorkflow28(StringConcatTask);
7263
+ // src/task/string/StringIncludesTask.ts
7264
+ import {
7265
+ CreateWorkflow as CreateWorkflow29,
7266
+ Task as Task27,
7267
+ Workflow as Workflow30
7268
+ } from "@workglow/task-graph";
7269
+ var inputSchema25 = {
6940
7270
  type: "object",
6941
7271
  properties: {
6942
7272
  value: {
6943
- type: "number",
7273
+ type: "string",
6944
7274
  title: "Value",
6945
- description: "Input number"
7275
+ description: "Input string to search in"
7276
+ },
7277
+ search: {
7278
+ type: "string",
7279
+ title: "Search",
7280
+ description: "Substring to search for"
6946
7281
  }
6947
7282
  },
6948
- required: ["value"],
7283
+ required: ["value", "search"],
6949
7284
  additionalProperties: false
6950
7285
  };
6951
- var outputSchema20 = {
7286
+ var outputSchema24 = {
6952
7287
  type: "object",
6953
7288
  properties: {
6954
7289
  result: {
6955
- type: "number",
7290
+ type: "boolean",
7291
+ title: "Result",
7292
+ description: "Whether the string contains the search substring"
7293
+ }
7294
+ },
7295
+ required: ["result"],
7296
+ additionalProperties: false
7297
+ };
7298
+
7299
+ class StringIncludesTask extends Task27 {
7300
+ static type = "StringIncludesTask";
7301
+ static category = "String";
7302
+ static title = "Includes";
7303
+ static description = "Checks if a string contains a substring";
7304
+ static inputSchema() {
7305
+ return inputSchema25;
7306
+ }
7307
+ static outputSchema() {
7308
+ return outputSchema24;
7309
+ }
7310
+ async executeReactive(input2, output, _context) {
7311
+ return { result: input2.value.includes(input2.search) };
7312
+ }
7313
+ }
7314
+ Workflow30.prototype.stringIncludes = CreateWorkflow29(StringIncludesTask);
7315
+ // src/task/string/StringJoinTask.ts
7316
+ import {
7317
+ CreateWorkflow as CreateWorkflow30,
7318
+ Task as Task28,
7319
+ Workflow as Workflow31
7320
+ } from "@workglow/task-graph";
7321
+ var inputSchema26 = {
7322
+ type: "object",
7323
+ properties: {
7324
+ values: {
7325
+ type: "array",
7326
+ items: { type: "string" },
7327
+ title: "Values",
7328
+ description: "Array of strings to join"
7329
+ },
7330
+ separator: {
7331
+ type: "string",
7332
+ title: "Separator",
7333
+ description: "Separator between elements",
7334
+ default: ""
7335
+ }
7336
+ },
7337
+ required: ["values"],
7338
+ additionalProperties: false
7339
+ };
7340
+ var outputSchema25 = {
7341
+ type: "object",
7342
+ properties: {
7343
+ result: {
7344
+ type: "string",
7345
+ title: "Result",
7346
+ description: "Joined string"
7347
+ }
7348
+ },
7349
+ required: ["result"],
7350
+ additionalProperties: false
7351
+ };
7352
+
7353
+ class StringJoinTask extends Task28 {
7354
+ static type = "StringJoinTask";
7355
+ static category = "String";
7356
+ static title = "Join";
7357
+ static description = "Joins an array of strings with a separator";
7358
+ static inputSchema() {
7359
+ return inputSchema26;
7360
+ }
7361
+ static outputSchema() {
7362
+ return outputSchema25;
7363
+ }
7364
+ async executeReactive(input2, output, _context) {
7365
+ const separator = input2.separator ?? "";
7366
+ return { result: input2.values.join(separator) };
7367
+ }
7368
+ }
7369
+ Workflow31.prototype.stringJoin = CreateWorkflow30(StringJoinTask);
7370
+ // src/task/string/StringLengthTask.ts
7371
+ import {
7372
+ CreateWorkflow as CreateWorkflow31,
7373
+ Task as Task29,
7374
+ Workflow as Workflow32
7375
+ } from "@workglow/task-graph";
7376
+ var inputSchema27 = {
7377
+ type: "object",
7378
+ properties: {
7379
+ value: {
7380
+ type: "string",
7381
+ title: "Value",
7382
+ description: "Input string"
7383
+ }
7384
+ },
7385
+ required: ["value"],
7386
+ additionalProperties: false
7387
+ };
7388
+ var outputSchema26 = {
7389
+ type: "object",
7390
+ properties: {
7391
+ result: {
7392
+ type: "integer",
7393
+ title: "Result",
7394
+ description: "Length of the string"
7395
+ }
7396
+ },
7397
+ required: ["result"],
7398
+ additionalProperties: false
7399
+ };
7400
+
7401
+ class StringLengthTask extends Task29 {
7402
+ static type = "StringLengthTask";
7403
+ static category = "String";
7404
+ static title = "Length";
7405
+ static description = "Returns the length of a string";
7406
+ static inputSchema() {
7407
+ return inputSchema27;
7408
+ }
7409
+ static outputSchema() {
7410
+ return outputSchema26;
7411
+ }
7412
+ async executeReactive(input2, output, _context) {
7413
+ return { result: input2.value.length };
7414
+ }
7415
+ }
7416
+ Workflow32.prototype.stringLength = CreateWorkflow31(StringLengthTask);
7417
+ // src/task/string/StringLowerCaseTask.ts
7418
+ import {
7419
+ CreateWorkflow as CreateWorkflow32,
7420
+ Task as Task30,
7421
+ Workflow as Workflow33
7422
+ } from "@workglow/task-graph";
7423
+ var inputSchema28 = {
7424
+ type: "object",
7425
+ properties: {
7426
+ value: {
7427
+ type: "string",
7428
+ title: "Value",
7429
+ description: "Input string"
7430
+ }
7431
+ },
7432
+ required: ["value"],
7433
+ additionalProperties: false
7434
+ };
7435
+ var outputSchema27 = {
7436
+ type: "object",
7437
+ properties: {
7438
+ result: {
7439
+ type: "string",
7440
+ title: "Result",
7441
+ description: "Lowercased string"
7442
+ }
7443
+ },
7444
+ required: ["result"],
7445
+ additionalProperties: false
7446
+ };
7447
+
7448
+ class StringLowerCaseTask extends Task30 {
7449
+ static type = "StringLowerCaseTask";
7450
+ static category = "String";
7451
+ static title = "Lower Case";
7452
+ static description = "Converts a string to lower case";
7453
+ static inputSchema() {
7454
+ return inputSchema28;
7455
+ }
7456
+ static outputSchema() {
7457
+ return outputSchema27;
7458
+ }
7459
+ async executeReactive(input2, output, _context) {
7460
+ return { result: input2.value.toLowerCase() };
7461
+ }
7462
+ }
7463
+ Workflow33.prototype.stringLowerCase = CreateWorkflow32(StringLowerCaseTask);
7464
+ // src/task/string/StringReplaceTask.ts
7465
+ import {
7466
+ CreateWorkflow as CreateWorkflow33,
7467
+ Task as Task31,
7468
+ Workflow as Workflow34
7469
+ } from "@workglow/task-graph";
7470
+ var inputSchema29 = {
7471
+ type: "object",
7472
+ properties: {
7473
+ value: {
7474
+ type: "string",
7475
+ title: "Value",
7476
+ description: "Input string"
7477
+ },
7478
+ search: {
7479
+ type: "string",
7480
+ title: "Search",
7481
+ description: "Substring to search for"
7482
+ },
7483
+ replace: {
7484
+ type: "string",
7485
+ title: "Replace",
7486
+ description: "Replacement string"
7487
+ }
7488
+ },
7489
+ required: ["value", "search", "replace"],
7490
+ additionalProperties: false
7491
+ };
7492
+ var outputSchema28 = {
7493
+ type: "object",
7494
+ properties: {
7495
+ result: {
7496
+ type: "string",
7497
+ title: "Result",
7498
+ description: "String with all occurrences replaced"
7499
+ }
7500
+ },
7501
+ required: ["result"],
7502
+ additionalProperties: false
7503
+ };
7504
+
7505
+ class StringReplaceTask extends Task31 {
7506
+ static type = "StringReplaceTask";
7507
+ static category = "String";
7508
+ static title = "Replace";
7509
+ static description = "Replaces all occurrences of a substring";
7510
+ static inputSchema() {
7511
+ return inputSchema29;
7512
+ }
7513
+ static outputSchema() {
7514
+ return outputSchema28;
7515
+ }
7516
+ async executeReactive(input2, output, _context) {
7517
+ return { result: input2.value.replaceAll(input2.search, input2.replace) };
7518
+ }
7519
+ }
7520
+ Workflow34.prototype.stringReplace = CreateWorkflow33(StringReplaceTask);
7521
+ // src/task/string/StringSliceTask.ts
7522
+ import {
7523
+ CreateWorkflow as CreateWorkflow34,
7524
+ Task as Task32,
7525
+ Workflow as Workflow35
7526
+ } from "@workglow/task-graph";
7527
+ var inputSchema30 = {
7528
+ type: "object",
7529
+ properties: {
7530
+ value: {
7531
+ type: "string",
7532
+ title: "Value",
7533
+ description: "Input string"
7534
+ },
7535
+ start: {
7536
+ type: "integer",
7537
+ title: "Start",
7538
+ description: "Start index (inclusive, supports negative indexing)"
7539
+ },
7540
+ end: {
7541
+ type: "integer",
7542
+ title: "End",
7543
+ description: "End index (exclusive, supports negative indexing)"
7544
+ }
7545
+ },
7546
+ required: ["value", "start"],
7547
+ additionalProperties: false
7548
+ };
7549
+ var outputSchema29 = {
7550
+ type: "object",
7551
+ properties: {
7552
+ result: {
7553
+ type: "string",
7554
+ title: "Result",
7555
+ description: "Extracted substring"
7556
+ }
7557
+ },
7558
+ required: ["result"],
7559
+ additionalProperties: false
7560
+ };
7561
+
7562
+ class StringSliceTask extends Task32 {
7563
+ static type = "StringSliceTask";
7564
+ static category = "String";
7565
+ static title = "Slice";
7566
+ static description = "Extracts a substring by start and optional end index";
7567
+ static inputSchema() {
7568
+ return inputSchema30;
7569
+ }
7570
+ static outputSchema() {
7571
+ return outputSchema29;
7572
+ }
7573
+ async executeReactive(input2, output, _context) {
7574
+ return { result: input2.value.slice(input2.start, input2.end) };
7575
+ }
7576
+ }
7577
+ Workflow35.prototype.stringSlice = CreateWorkflow34(StringSliceTask);
7578
+ // src/task/string/StringTemplateTask.ts
7579
+ import {
7580
+ CreateWorkflow as CreateWorkflow35,
7581
+ Task as Task33,
7582
+ Workflow as Workflow36
7583
+ } from "@workglow/task-graph";
7584
+ var inputSchema31 = {
7585
+ type: "object",
7586
+ properties: {
7587
+ template: {
7588
+ type: "string",
7589
+ title: "Template",
7590
+ description: "Template string with {{key}} placeholders"
7591
+ },
7592
+ values: {
7593
+ type: "object",
7594
+ title: "Values",
7595
+ description: "Key-value pairs to substitute into the template",
7596
+ additionalProperties: true
7597
+ }
7598
+ },
7599
+ required: ["template", "values"],
7600
+ additionalProperties: false
7601
+ };
7602
+ var outputSchema30 = {
7603
+ type: "object",
7604
+ properties: {
7605
+ result: {
7606
+ type: "string",
7607
+ title: "Result",
7608
+ description: "Template with placeholders replaced by values"
7609
+ }
7610
+ },
7611
+ required: ["result"],
7612
+ additionalProperties: false
7613
+ };
7614
+
7615
+ class StringTemplateTask extends Task33 {
7616
+ static type = "StringTemplateTask";
7617
+ static category = "String";
7618
+ static title = "Template";
7619
+ static description = "Replaces {{key}} placeholders in a template string with values";
7620
+ static inputSchema() {
7621
+ return inputSchema31;
7622
+ }
7623
+ static outputSchema() {
7624
+ return outputSchema30;
7625
+ }
7626
+ async executeReactive(input2, output, _context) {
7627
+ let result = input2.template;
7628
+ for (const [key, value] of Object.entries(input2.values)) {
7629
+ result = result.replaceAll(`{{${key}}}`, String(value));
7630
+ }
7631
+ return { result };
7632
+ }
7633
+ }
7634
+ Workflow36.prototype.stringTemplate = CreateWorkflow35(StringTemplateTask);
7635
+ // src/task/string/StringTrimTask.ts
7636
+ import {
7637
+ CreateWorkflow as CreateWorkflow36,
7638
+ Task as Task34,
7639
+ Workflow as Workflow37
7640
+ } from "@workglow/task-graph";
7641
+ var inputSchema32 = {
7642
+ type: "object",
7643
+ properties: {
7644
+ value: {
7645
+ type: "string",
7646
+ title: "Value",
7647
+ description: "Input string"
7648
+ }
7649
+ },
7650
+ required: ["value"],
7651
+ additionalProperties: false
7652
+ };
7653
+ var outputSchema31 = {
7654
+ type: "object",
7655
+ properties: {
7656
+ result: {
7657
+ type: "string",
7658
+ title: "Result",
7659
+ description: "Trimmed string"
7660
+ }
7661
+ },
7662
+ required: ["result"],
7663
+ additionalProperties: false
7664
+ };
7665
+
7666
+ class StringTrimTask extends Task34 {
7667
+ static type = "StringTrimTask";
7668
+ static category = "String";
7669
+ static title = "Trim";
7670
+ static description = "Removes leading and trailing whitespace from a string";
7671
+ static inputSchema() {
7672
+ return inputSchema32;
7673
+ }
7674
+ static outputSchema() {
7675
+ return outputSchema31;
7676
+ }
7677
+ async executeReactive(input2, output, _context) {
7678
+ return { result: input2.value.trim() };
7679
+ }
7680
+ }
7681
+ Workflow37.prototype.stringTrim = CreateWorkflow36(StringTrimTask);
7682
+ // src/task/string/StringUpperCaseTask.ts
7683
+ import {
7684
+ CreateWorkflow as CreateWorkflow37,
7685
+ Task as Task35,
7686
+ Workflow as Workflow38
7687
+ } from "@workglow/task-graph";
7688
+ var inputSchema33 = {
7689
+ type: "object",
7690
+ properties: {
7691
+ value: {
7692
+ type: "string",
7693
+ title: "Value",
7694
+ description: "Input string"
7695
+ }
7696
+ },
7697
+ required: ["value"],
7698
+ additionalProperties: false
7699
+ };
7700
+ var outputSchema32 = {
7701
+ type: "object",
7702
+ properties: {
7703
+ result: {
7704
+ type: "string",
7705
+ title: "Result",
7706
+ description: "Uppercased string"
7707
+ }
7708
+ },
7709
+ required: ["result"],
7710
+ additionalProperties: false
7711
+ };
7712
+
7713
+ class StringUpperCaseTask extends Task35 {
7714
+ static type = "StringUpperCaseTask";
7715
+ static category = "String";
7716
+ static title = "Upper Case";
7717
+ static description = "Converts a string to upper case";
7718
+ static inputSchema() {
7719
+ return inputSchema33;
7720
+ }
7721
+ static outputSchema() {
7722
+ return outputSchema32;
7723
+ }
7724
+ async executeReactive(input2, output, _context) {
7725
+ return { result: input2.value.toUpperCase() };
7726
+ }
7727
+ }
7728
+ Workflow38.prototype.stringUpperCase = CreateWorkflow37(StringUpperCaseTask);
7729
+ // src/task/scalar/ScalarAbsTask.ts
7730
+ import { CreateWorkflow as CreateWorkflow38, Task as Task36, Workflow as Workflow39 } from "@workglow/task-graph";
7731
+ var inputSchema34 = {
7732
+ type: "object",
7733
+ properties: {
7734
+ value: {
7735
+ type: "number",
7736
+ title: "Value",
7737
+ description: "Input number"
7738
+ }
7739
+ },
7740
+ required: ["value"],
7741
+ additionalProperties: false
7742
+ };
7743
+ var outputSchema33 = {
7744
+ type: "object",
7745
+ properties: {
7746
+ result: {
7747
+ type: "number",
7748
+ title: "Result",
7749
+ description: "Absolute value"
7750
+ }
7751
+ },
7752
+ required: ["result"],
7753
+ additionalProperties: false
7754
+ };
7755
+
7756
+ class ScalarAbsTask extends Task36 {
7757
+ static type = "ScalarAbsTask";
7758
+ static category = "Math";
7759
+ static title = "Abs";
7760
+ static description = "Returns the absolute value of a number";
7761
+ static inputSchema() {
7762
+ return inputSchema34;
7763
+ }
7764
+ static outputSchema() {
7765
+ return outputSchema33;
7766
+ }
7767
+ async execute(input2, _context) {
7768
+ return { result: Math.abs(input2.value) };
7769
+ }
7770
+ }
7771
+ Workflow39.prototype.scalarAbs = CreateWorkflow38(ScalarAbsTask);
7772
+ // src/task/scalar/ScalarCeilTask.ts
7773
+ import { CreateWorkflow as CreateWorkflow39, Task as Task37, Workflow as Workflow40 } from "@workglow/task-graph";
7774
+ var inputSchema35 = {
7775
+ type: "object",
7776
+ properties: {
7777
+ value: {
7778
+ type: "number",
7779
+ title: "Value",
7780
+ description: "Input number"
7781
+ }
7782
+ },
7783
+ required: ["value"],
7784
+ additionalProperties: false
7785
+ };
7786
+ var outputSchema34 = {
7787
+ type: "object",
7788
+ properties: {
7789
+ result: {
7790
+ type: "number",
6956
7791
  title: "Result",
6957
7792
  description: "Ceiling value"
6958
7793
  }
@@ -6961,25 +7796,25 @@ var outputSchema20 = {
6961
7796
  additionalProperties: false
6962
7797
  };
6963
7798
 
6964
- class ScalarCeilTask extends Task23 {
7799
+ class ScalarCeilTask extends Task37 {
6965
7800
  static type = "ScalarCeilTask";
6966
7801
  static category = "Math";
6967
7802
  static title = "Ceil";
6968
7803
  static description = "Returns the smallest integer greater than or equal to a number";
6969
7804
  static inputSchema() {
6970
- return inputSchema21;
7805
+ return inputSchema35;
6971
7806
  }
6972
7807
  static outputSchema() {
6973
- return outputSchema20;
7808
+ return outputSchema34;
6974
7809
  }
6975
7810
  async execute(input2, _context) {
6976
7811
  return { result: Math.ceil(input2.value) };
6977
7812
  }
6978
7813
  }
6979
- Workflow26.prototype.scalarCeil = CreateWorkflow25(ScalarCeilTask);
7814
+ Workflow40.prototype.scalarCeil = CreateWorkflow39(ScalarCeilTask);
6980
7815
  // src/task/scalar/ScalarFloorTask.ts
6981
- import { CreateWorkflow as CreateWorkflow26, Task as Task24, Workflow as Workflow27 } from "@workglow/task-graph";
6982
- var inputSchema22 = {
7816
+ import { CreateWorkflow as CreateWorkflow40, Task as Task38, Workflow as Workflow41 } from "@workglow/task-graph";
7817
+ var inputSchema36 = {
6983
7818
  type: "object",
6984
7819
  properties: {
6985
7820
  value: {
@@ -6991,7 +7826,7 @@ var inputSchema22 = {
6991
7826
  required: ["value"],
6992
7827
  additionalProperties: false
6993
7828
  };
6994
- var outputSchema21 = {
7829
+ var outputSchema35 = {
6995
7830
  type: "object",
6996
7831
  properties: {
6997
7832
  result: {
@@ -7004,25 +7839,25 @@ var outputSchema21 = {
7004
7839
  additionalProperties: false
7005
7840
  };
7006
7841
 
7007
- class ScalarFloorTask extends Task24 {
7842
+ class ScalarFloorTask extends Task38 {
7008
7843
  static type = "ScalarFloorTask";
7009
7844
  static category = "Math";
7010
7845
  static title = "Floor";
7011
7846
  static description = "Returns the largest integer less than or equal to a number";
7012
7847
  static inputSchema() {
7013
- return inputSchema22;
7848
+ return inputSchema36;
7014
7849
  }
7015
7850
  static outputSchema() {
7016
- return outputSchema21;
7851
+ return outputSchema35;
7017
7852
  }
7018
7853
  async execute(input2, _context) {
7019
7854
  return { result: Math.floor(input2.value) };
7020
7855
  }
7021
7856
  }
7022
- Workflow27.prototype.scalarFloor = CreateWorkflow26(ScalarFloorTask);
7857
+ Workflow41.prototype.scalarFloor = CreateWorkflow40(ScalarFloorTask);
7023
7858
  // src/task/scalar/ScalarMaxTask.ts
7024
- import { CreateWorkflow as CreateWorkflow27, Task as Task25, Workflow as Workflow28 } from "@workglow/task-graph";
7025
- var inputSchema23 = {
7859
+ import { CreateWorkflow as CreateWorkflow41, Task as Task39, Workflow as Workflow42 } from "@workglow/task-graph";
7860
+ var inputSchema37 = {
7026
7861
  type: "object",
7027
7862
  properties: {
7028
7863
  values: {
@@ -7035,7 +7870,7 @@ var inputSchema23 = {
7035
7870
  required: ["values"],
7036
7871
  additionalProperties: false
7037
7872
  };
7038
- var outputSchema22 = {
7873
+ var outputSchema36 = {
7039
7874
  type: "object",
7040
7875
  properties: {
7041
7876
  result: {
@@ -7048,25 +7883,25 @@ var outputSchema22 = {
7048
7883
  additionalProperties: false
7049
7884
  };
7050
7885
 
7051
- class ScalarMaxTask extends Task25 {
7886
+ class ScalarMaxTask extends Task39 {
7052
7887
  static type = "ScalarMaxTask";
7053
7888
  static category = "Math";
7054
7889
  static title = "Max";
7055
7890
  static description = "Returns the largest of the given numbers";
7056
7891
  static inputSchema() {
7057
- return inputSchema23;
7892
+ return inputSchema37;
7058
7893
  }
7059
7894
  static outputSchema() {
7060
- return outputSchema22;
7895
+ return outputSchema36;
7061
7896
  }
7062
7897
  async execute(input2, _context) {
7063
7898
  return { result: Math.max(...input2.values) };
7064
7899
  }
7065
7900
  }
7066
- Workflow28.prototype.scalarMax = CreateWorkflow27(ScalarMaxTask);
7901
+ Workflow42.prototype.scalarMax = CreateWorkflow41(ScalarMaxTask);
7067
7902
  // src/task/scalar/ScalarMinTask.ts
7068
- import { CreateWorkflow as CreateWorkflow28, Task as Task26, Workflow as Workflow29 } from "@workglow/task-graph";
7069
- var inputSchema24 = {
7903
+ import { CreateWorkflow as CreateWorkflow42, Task as Task40, Workflow as Workflow43 } from "@workglow/task-graph";
7904
+ var inputSchema38 = {
7070
7905
  type: "object",
7071
7906
  properties: {
7072
7907
  values: {
@@ -7079,7 +7914,7 @@ var inputSchema24 = {
7079
7914
  required: ["values"],
7080
7915
  additionalProperties: false
7081
7916
  };
7082
- var outputSchema23 = {
7917
+ var outputSchema37 = {
7083
7918
  type: "object",
7084
7919
  properties: {
7085
7920
  result: {
@@ -7092,25 +7927,25 @@ var outputSchema23 = {
7092
7927
  additionalProperties: false
7093
7928
  };
7094
7929
 
7095
- class ScalarMinTask extends Task26 {
7930
+ class ScalarMinTask extends Task40 {
7096
7931
  static type = "ScalarMinTask";
7097
7932
  static category = "Math";
7098
7933
  static title = "Min";
7099
7934
  static description = "Returns the smallest of the given numbers";
7100
7935
  static inputSchema() {
7101
- return inputSchema24;
7936
+ return inputSchema38;
7102
7937
  }
7103
7938
  static outputSchema() {
7104
- return outputSchema23;
7939
+ return outputSchema37;
7105
7940
  }
7106
7941
  async execute(input2, _context) {
7107
7942
  return { result: Math.min(...input2.values) };
7108
7943
  }
7109
7944
  }
7110
- Workflow29.prototype.scalarMin = CreateWorkflow28(ScalarMinTask);
7945
+ Workflow43.prototype.scalarMin = CreateWorkflow42(ScalarMinTask);
7111
7946
  // src/task/scalar/ScalarRoundTask.ts
7112
- import { CreateWorkflow as CreateWorkflow29, Task as Task27, Workflow as Workflow30 } from "@workglow/task-graph";
7113
- var inputSchema25 = {
7947
+ import { CreateWorkflow as CreateWorkflow43, Task as Task41, Workflow as Workflow44 } from "@workglow/task-graph";
7948
+ var inputSchema39 = {
7114
7949
  type: "object",
7115
7950
  properties: {
7116
7951
  value: {
@@ -7122,7 +7957,7 @@ var inputSchema25 = {
7122
7957
  required: ["value"],
7123
7958
  additionalProperties: false
7124
7959
  };
7125
- var outputSchema24 = {
7960
+ var outputSchema38 = {
7126
7961
  type: "object",
7127
7962
  properties: {
7128
7963
  result: {
@@ -7135,25 +7970,25 @@ var outputSchema24 = {
7135
7970
  additionalProperties: false
7136
7971
  };
7137
7972
 
7138
- class ScalarRoundTask extends Task27 {
7973
+ class ScalarRoundTask extends Task41 {
7139
7974
  static type = "ScalarRoundTask";
7140
7975
  static category = "Math";
7141
7976
  static title = "Round";
7142
7977
  static description = "Returns the value of a number rounded to the nearest integer";
7143
7978
  static inputSchema() {
7144
- return inputSchema25;
7979
+ return inputSchema39;
7145
7980
  }
7146
7981
  static outputSchema() {
7147
- return outputSchema24;
7982
+ return outputSchema38;
7148
7983
  }
7149
7984
  async execute(input2, _context) {
7150
7985
  return { result: Math.round(input2.value) };
7151
7986
  }
7152
7987
  }
7153
- Workflow30.prototype.scalarRound = CreateWorkflow29(ScalarRoundTask);
7988
+ Workflow44.prototype.scalarRound = CreateWorkflow43(ScalarRoundTask);
7154
7989
  // src/task/scalar/ScalarTruncTask.ts
7155
- import { CreateWorkflow as CreateWorkflow30, Task as Task28, Workflow as Workflow31 } from "@workglow/task-graph";
7156
- var inputSchema26 = {
7990
+ import { CreateWorkflow as CreateWorkflow44, Task as Task42, Workflow as Workflow45 } from "@workglow/task-graph";
7991
+ var inputSchema40 = {
7157
7992
  type: "object",
7158
7993
  properties: {
7159
7994
  value: {
@@ -7165,7 +8000,7 @@ var inputSchema26 = {
7165
8000
  required: ["value"],
7166
8001
  additionalProperties: false
7167
8002
  };
7168
- var outputSchema25 = {
8003
+ var outputSchema39 = {
7169
8004
  type: "object",
7170
8005
  properties: {
7171
8006
  result: {
@@ -7178,28 +8013,28 @@ var outputSchema25 = {
7178
8013
  additionalProperties: false
7179
8014
  };
7180
8015
 
7181
- class ScalarTruncTask extends Task28 {
8016
+ class ScalarTruncTask extends Task42 {
7182
8017
  static type = "ScalarTruncTask";
7183
8018
  static category = "Math";
7184
8019
  static title = "Truncate";
7185
8020
  static description = "Returns the integer part of a number by removing fractional digits";
7186
8021
  static inputSchema() {
7187
- return inputSchema26;
8022
+ return inputSchema40;
7188
8023
  }
7189
8024
  static outputSchema() {
7190
- return outputSchema25;
8025
+ return outputSchema39;
7191
8026
  }
7192
8027
  async execute(input2, _context) {
7193
8028
  return { result: Math.trunc(input2.value) };
7194
8029
  }
7195
8030
  }
7196
- Workflow31.prototype.scalarTrunc = CreateWorkflow30(ScalarTruncTask);
8031
+ Workflow45.prototype.scalarTrunc = CreateWorkflow44(ScalarTruncTask);
7197
8032
  // src/task/vector/VectorDistanceTask.ts
7198
- import { CreateWorkflow as CreateWorkflow31, Task as Task29, Workflow as Workflow32 } from "@workglow/task-graph";
8033
+ import { CreateWorkflow as CreateWorkflow45, Task as Task43, Workflow as Workflow46 } from "@workglow/task-graph";
7199
8034
  import {
7200
8035
  TypedArraySchema as TypedArraySchema5
7201
8036
  } from "@workglow/util";
7202
- var inputSchema27 = {
8037
+ var inputSchema41 = {
7203
8038
  type: "object",
7204
8039
  properties: {
7205
8040
  vectors: {
@@ -7215,7 +8050,7 @@ var inputSchema27 = {
7215
8050
  required: ["vectors"],
7216
8051
  additionalProperties: false
7217
8052
  };
7218
- var outputSchema26 = {
8053
+ var outputSchema40 = {
7219
8054
  type: "object",
7220
8055
  properties: {
7221
8056
  result: {
@@ -7228,16 +8063,16 @@ var outputSchema26 = {
7228
8063
  additionalProperties: false
7229
8064
  };
7230
8065
 
7231
- class VectorDistanceTask extends Task29 {
8066
+ class VectorDistanceTask extends Task43 {
7232
8067
  static type = "VectorDistanceTask";
7233
8068
  static category = "Vector";
7234
8069
  static title = "Distance";
7235
8070
  static description = "Returns the Euclidean distance between the first two vectors";
7236
8071
  static inputSchema() {
7237
- return inputSchema27;
8072
+ return inputSchema41;
7238
8073
  }
7239
8074
  static outputSchema() {
7240
- return outputSchema26;
8075
+ return outputSchema40;
7241
8076
  }
7242
8077
  async execute(input2, _context) {
7243
8078
  const { vectors } = input2;
@@ -7255,13 +8090,13 @@ class VectorDistanceTask extends Task29 {
7255
8090
  return { result: Math.sqrt(sumPrecise(diffs)) };
7256
8091
  }
7257
8092
  }
7258
- Workflow32.prototype.vectorDistance = CreateWorkflow31(VectorDistanceTask);
8093
+ Workflow46.prototype.vectorDistance = CreateWorkflow45(VectorDistanceTask);
7259
8094
  // src/task/vector/VectorDotProductTask.ts
7260
- import { CreateWorkflow as CreateWorkflow32, Task as Task30, Workflow as Workflow33 } from "@workglow/task-graph";
8095
+ import { CreateWorkflow as CreateWorkflow46, Task as Task44, Workflow as Workflow47 } from "@workglow/task-graph";
7261
8096
  import {
7262
8097
  TypedArraySchema as TypedArraySchema6
7263
8098
  } from "@workglow/util";
7264
- var inputSchema28 = {
8099
+ var inputSchema42 = {
7265
8100
  type: "object",
7266
8101
  properties: {
7267
8102
  vectors: {
@@ -7277,7 +8112,7 @@ var inputSchema28 = {
7277
8112
  required: ["vectors"],
7278
8113
  additionalProperties: false
7279
8114
  };
7280
- var outputSchema27 = {
8115
+ var outputSchema41 = {
7281
8116
  type: "object",
7282
8117
  properties: {
7283
8118
  result: {
@@ -7290,16 +8125,16 @@ var outputSchema27 = {
7290
8125
  additionalProperties: false
7291
8126
  };
7292
8127
 
7293
- class VectorDotProductTask extends Task30 {
8128
+ class VectorDotProductTask extends Task44 {
7294
8129
  static type = "VectorDotProductTask";
7295
8130
  static category = "Vector";
7296
8131
  static title = "Dot Product";
7297
8132
  static description = "Returns the dot (inner) product of the first two vectors";
7298
8133
  static inputSchema() {
7299
- return inputSchema28;
8134
+ return inputSchema42;
7300
8135
  }
7301
8136
  static outputSchema() {
7302
- return outputSchema27;
8137
+ return outputSchema41;
7303
8138
  }
7304
8139
  async execute(input2, _context) {
7305
8140
  const { vectors } = input2;
@@ -7314,14 +8149,14 @@ class VectorDotProductTask extends Task30 {
7314
8149
  return { result: sumPrecise(products) };
7315
8150
  }
7316
8151
  }
7317
- Workflow33.prototype.vectorDotProduct = CreateWorkflow32(VectorDotProductTask);
8152
+ Workflow47.prototype.vectorDotProduct = CreateWorkflow46(VectorDotProductTask);
7318
8153
  // src/task/vector/VectorNormalizeTask.ts
7319
- import { CreateWorkflow as CreateWorkflow33, Task as Task31, Workflow as Workflow34 } from "@workglow/task-graph";
8154
+ import { CreateWorkflow as CreateWorkflow47, Task as Task45, Workflow as Workflow48 } from "@workglow/task-graph";
7320
8155
  import {
7321
8156
  TypedArraySchema as TypedArraySchema7,
7322
8157
  normalize
7323
8158
  } from "@workglow/util";
7324
- var inputSchema29 = {
8159
+ var inputSchema43 = {
7325
8160
  type: "object",
7326
8161
  properties: {
7327
8162
  vector: TypedArraySchema7({
@@ -7332,7 +8167,7 @@ var inputSchema29 = {
7332
8167
  required: ["vector"],
7333
8168
  additionalProperties: false
7334
8169
  };
7335
- var outputSchema28 = {
8170
+ var outputSchema42 = {
7336
8171
  type: "object",
7337
8172
  properties: {
7338
8173
  result: TypedArraySchema7({
@@ -7344,29 +8179,29 @@ var outputSchema28 = {
7344
8179
  additionalProperties: false
7345
8180
  };
7346
8181
 
7347
- class VectorNormalizeTask extends Task31 {
8182
+ class VectorNormalizeTask extends Task45 {
7348
8183
  static type = "VectorNormalizeTask";
7349
8184
  static category = "Vector";
7350
8185
  static title = "Normalize";
7351
8186
  static description = "Returns the L2-normalized (unit length) vector";
7352
8187
  static inputSchema() {
7353
- return inputSchema29;
8188
+ return inputSchema43;
7354
8189
  }
7355
8190
  static outputSchema() {
7356
- return outputSchema28;
8191
+ return outputSchema42;
7357
8192
  }
7358
8193
  async execute(input2, _context) {
7359
8194
  return { result: normalize(input2.vector) };
7360
8195
  }
7361
8196
  }
7362
- Workflow34.prototype.vectorNormalize = CreateWorkflow33(VectorNormalizeTask);
8197
+ Workflow48.prototype.vectorNormalize = CreateWorkflow47(VectorNormalizeTask);
7363
8198
  // src/task/vector/VectorScaleTask.ts
7364
- import { CreateWorkflow as CreateWorkflow34, Task as Task32, Workflow as Workflow35 } from "@workglow/task-graph";
8199
+ import { CreateWorkflow as CreateWorkflow48, Task as Task46, Workflow as Workflow49 } from "@workglow/task-graph";
7365
8200
  import {
7366
8201
  createTypedArrayFrom as createTypedArrayFrom5,
7367
8202
  TypedArraySchema as TypedArraySchema8
7368
8203
  } from "@workglow/util";
7369
- var inputSchema30 = {
8204
+ var inputSchema44 = {
7370
8205
  type: "object",
7371
8206
  properties: {
7372
8207
  vector: TypedArraySchema8({
@@ -7382,7 +8217,7 @@ var inputSchema30 = {
7382
8217
  required: ["vector", "scalar"],
7383
8218
  additionalProperties: false
7384
8219
  };
7385
- var outputSchema29 = {
8220
+ var outputSchema43 = {
7386
8221
  type: "object",
7387
8222
  properties: {
7388
8223
  result: TypedArraySchema8({
@@ -7394,16 +8229,16 @@ var outputSchema29 = {
7394
8229
  additionalProperties: false
7395
8230
  };
7396
8231
 
7397
- class VectorScaleTask extends Task32 {
8232
+ class VectorScaleTask extends Task46 {
7398
8233
  static type = "VectorScaleTask";
7399
8234
  static category = "Vector";
7400
8235
  static title = "Scale";
7401
8236
  static description = "Multiplies each element of a vector by a scalar";
7402
8237
  static inputSchema() {
7403
- return inputSchema30;
8238
+ return inputSchema44;
7404
8239
  }
7405
8240
  static outputSchema() {
7406
- return outputSchema29;
8241
+ return outputSchema43;
7407
8242
  }
7408
8243
  async execute(input2, _context) {
7409
8244
  const { vector, scalar } = input2;
@@ -7411,7 +8246,7 @@ class VectorScaleTask extends Task32 {
7411
8246
  return { result: createTypedArrayFrom5([vector], values) };
7412
8247
  }
7413
8248
  }
7414
- Workflow35.prototype.vectorScale = CreateWorkflow34(VectorScaleTask);
8249
+ Workflow49.prototype.vectorScale = CreateWorkflow48(VectorScaleTask);
7415
8250
 
7416
8251
  // src/common.ts
7417
8252
  import { TaskRegistry } from "@workglow/task-graph";
@@ -7450,7 +8285,21 @@ var registerCommonTasks = () => {
7450
8285
  McpToolCallTask,
7451
8286
  McpResourceReadTask,
7452
8287
  McpPromptGetTask,
7453
- McpListTask
8288
+ McpListTask,
8289
+ StringConcatTask,
8290
+ StringIncludesTask,
8291
+ StringJoinTask,
8292
+ StringLengthTask,
8293
+ StringLowerCaseTask,
8294
+ StringReplaceTask,
8295
+ StringSliceTask,
8296
+ StringTemplateTask,
8297
+ StringTrimTask,
8298
+ StringUpperCaseTask,
8299
+ JsonPathTask,
8300
+ TemplateTask,
8301
+ DateFormatTask,
8302
+ RegexTask
7454
8303
  ];
7455
8304
  tasks.map(TaskRegistry.registerTask);
7456
8305
  return tasks;
@@ -7458,21 +8307,21 @@ var registerCommonTasks = () => {
7458
8307
 
7459
8308
  // src/task/FileLoaderTask.server.ts
7460
8309
  import {
7461
- CreateWorkflow as CreateWorkflow36,
8310
+ CreateWorkflow as CreateWorkflow50,
7462
8311
  TaskAbortedError as TaskAbortedError3,
7463
- Workflow as Workflow37
8312
+ Workflow as Workflow51
7464
8313
  } from "@workglow/task-graph";
7465
8314
  import { readFile } from "node:fs/promises";
7466
8315
 
7467
8316
  // src/task/FileLoaderTask.ts
7468
8317
  import {
7469
- CreateWorkflow as CreateWorkflow35,
7470
- Task as Task33,
8318
+ CreateWorkflow as CreateWorkflow49,
8319
+ Task as Task47,
7471
8320
  TaskAbortedError as TaskAbortedError2,
7472
- Workflow as Workflow36
8321
+ Workflow as Workflow50
7473
8322
  } from "@workglow/task-graph";
7474
8323
  import Papa from "papaparse";
7475
- var inputSchema31 = {
8324
+ var inputSchema45 = {
7476
8325
  type: "object",
7477
8326
  properties: {
7478
8327
  url: {
@@ -7492,7 +8341,7 @@ var inputSchema31 = {
7492
8341
  required: ["url"],
7493
8342
  additionalProperties: false
7494
8343
  };
7495
- var outputSchema30 = {
8344
+ var outputSchema44 = {
7496
8345
  type: "object",
7497
8346
  properties: {
7498
8347
  text: {
@@ -7543,17 +8392,17 @@ var outputSchema30 = {
7543
8392
  additionalProperties: false
7544
8393
  };
7545
8394
 
7546
- class FileLoaderTask extends Task33 {
8395
+ class FileLoaderTask extends Task47 {
7547
8396
  static type = "FileLoaderTask";
7548
8397
  static category = "Document";
7549
8398
  static title = "File Loader";
7550
8399
  static description = "Load documents from URLs (http://, https://)";
7551
8400
  static cacheable = true;
7552
8401
  static inputSchema() {
7553
- return inputSchema31;
8402
+ return inputSchema45;
7554
8403
  }
7555
8404
  static outputSchema() {
7556
- return outputSchema30;
8405
+ return outputSchema44;
7557
8406
  }
7558
8407
  async execute(input2, context) {
7559
8408
  const { url, format = "auto" } = input2;
@@ -7906,7 +8755,7 @@ class FileLoaderTask extends Task33 {
7906
8755
  });
7907
8756
  }
7908
8757
  }
7909
- Workflow36.prototype.fileLoader = CreateWorkflow35(FileLoaderTask);
8758
+ Workflow50.prototype.fileLoader = CreateWorkflow49(FileLoaderTask);
7910
8759
 
7911
8760
  // src/task/FileLoaderTask.server.ts
7912
8761
  class FileLoaderTask2 extends FileLoaderTask {
@@ -8095,7 +8944,7 @@ class FileLoaderTask2 extends FileLoaderTask {
8095
8944
  var fileLoader = (input2, config) => {
8096
8945
  return new FileLoaderTask2({}, config).run(input2);
8097
8946
  };
8098
- Workflow37.prototype.fileLoader = CreateWorkflow36(FileLoaderTask2);
8947
+ Workflow51.prototype.fileLoader = CreateWorkflow50(FileLoaderTask2);
8099
8948
 
8100
8949
  // src/node.ts
8101
8950
  var registerCommonTasks2 = () => {
@@ -8129,6 +8978,17 @@ export {
8129
8978
  VectorDivideTask,
8130
8979
  VectorDistanceTask,
8131
8980
  TypeReplicateArray,
8981
+ TemplateTask,
8982
+ StringUpperCaseTask,
8983
+ StringTrimTask,
8984
+ StringTemplateTask,
8985
+ StringSliceTask,
8986
+ StringReplaceTask,
8987
+ StringLowerCaseTask,
8988
+ StringLengthTask,
8989
+ StringJoinTask,
8990
+ StringIncludesTask,
8991
+ StringConcatTask,
8132
8992
  SplitTask,
8133
8993
  ScalarTruncTask,
8134
8994
  ScalarSumTask,
@@ -8142,6 +9002,7 @@ export {
8142
9002
  ScalarCeilTask,
8143
9003
  ScalarAddTask,
8144
9004
  ScalarAbsTask,
9005
+ RegexTask,
8145
9006
  OutputTask,
8146
9007
  MergeTask,
8147
9008
  McpToolCallTask,
@@ -8150,6 +9011,7 @@ export {
8150
9011
  McpListTask,
8151
9012
  LambdaTask,
8152
9013
  JsonTask,
9014
+ JsonPathTask,
8153
9015
  JavaScriptTask,
8154
9016
  InputTask,
8155
9017
  FileLoaderTask2 as FileLoaderTask,
@@ -8157,7 +9019,8 @@ export {
8157
9019
  FetchUrlJob,
8158
9020
  DelayTask,
8159
9021
  DebugLogTask,
9022
+ DateFormatTask,
8160
9023
  ArrayTask
8161
9024
  };
8162
9025
 
8163
- //# debugId=A6B33698A9E8527664756E2164756E21
9026
+ //# debugId=7A3E87B880771F0564756E2164756E21