@glodon-aiot/bot-client-sdk 3.26.0-alpha.26 → 3.26.0-alpha.27

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.
@@ -1,42 +1,43 @@
1
- const E = ["list_directory", "read_file", "stat_file", "search_files", "search_text", "apply_patch", "write_file", "upload_file", "download_file"], _ = "builtin_tools", t = {
1
+ const T = ["list_directory", "read_file", "stat_file", "search_files", "search_text", "apply_patch", "write_file", "upload_file", "download_file"], _ = "builtin_tools", t = {
2
2
  dev: _,
3
3
  test: _,
4
4
  prod: _,
5
5
  local: _
6
- }, T = t, c = "current-workspace", o = 1024, e = 1024 * 1024, s = 50, I = Object.freeze({
6
+ }, E = t, c = "current-workspace", o = 1024, e = 1024 * 1024, s = 50, I = Object.freeze({
7
7
  maxReadBytes: 1 * e,
8
8
  maxWriteBytes: 5 * e,
9
9
  maxSearchResults: 200,
10
10
  maxConcurrentRequests: 4,
11
11
  maxTransferBytes: s * e,
12
12
  toolTimeoutMs: 3e4,
13
+ commandTimeoutMs: 10 * 6e4,
13
14
  searchTimeoutMs: 6e4,
14
15
  transferTimeoutMs: 10 * 6e4,
15
16
  approvalTimeoutMs: 5 * 6e4
16
- }), n = 200, L = 1e3, S = 8, a = 16, l = 2e3, O = 1 * e, A = 500, R = 3, r = 8 * o, i = Object.freeze(["glodon.com"]), C = Object.freeze([".git", "node_modules", ".svn", ".idea", ".vscode"]), N = Object.freeze(["~$*", ".~lock*", "*.tmp"]), D = ["apply_patch", "write_file", "upload_file", "download_file"], F = ["search_files", "search_text"], d = ["upload_file", "download_file"];
17
+ }), n = 200, L = 1e3, S = 8, a = 16, l = 2e3, O = 1 * e, A = 500, R = 3, i = 8 * o, r = Object.freeze(["glodon.com"]), C = Object.freeze([".git", "node_modules", ".svn", ".idea", ".vscode"]), N = Object.freeze(["~$*", ".~lock*", "*.tmp"]), D = ["apply_patch", "write_file", "upload_file", "download_file"], d = ["search_files", "search_text"], F = ["upload_file", "download_file"];
17
18
  export {
18
- r as BINARY_SNIFF_BYTES,
19
+ i as BINARY_SNIFF_BYTES,
19
20
  _ as BUILTIN_TOOLS_PLUGIN_CODE,
20
21
  t as BUILTIN_TOOLS_PLUGIN_CODES,
21
- i as DEFAULT_DOWNLOAD_URL_ALLOWLIST,
22
+ r as DEFAULT_DOWNLOAD_URL_ALLOWLIST,
22
23
  C as DEFAULT_IGNORED_DIRECTORIES,
23
24
  N as DEFAULT_IGNORED_FILE_PATTERNS,
24
25
  I as DEFAULT_LIMITS,
25
26
  o as KiB,
26
27
  n as LIST_DIRECTORY_DEFAULT_LIMIT,
27
28
  L as LIST_DIRECTORY_MAX_LIMIT,
28
- E as LOCAL_FILES_FUNCTION_CODES,
29
- T as LOCAL_FILES_PLUGIN_CODES,
29
+ T as LOCAL_FILES_FUNCTION_CODES,
30
+ E as LOCAL_FILES_PLUGIN_CODES,
30
31
  e as MiB,
31
32
  S as SEARCH_DEFAULT_DEPTH,
32
- F as SEARCH_FUNCTION_CODES,
33
+ d as SEARCH_FUNCTION_CODES,
33
34
  a as SEARCH_MAX_DEPTH,
34
35
  R as TEXT_SEARCH_MAX_CONTEXT_LINES,
35
36
  l as TEXT_SEARCH_MAX_FILES,
36
37
  O as TEXT_SEARCH_MAX_FILE_BYTES,
37
38
  A as TEXT_SEARCH_MAX_LINE_CHARS,
38
39
  s as TRANSFER_FILE_SIZE_LIMIT_MB,
39
- d as TRANSFER_FUNCTION_CODES,
40
+ F as TRANSFER_FUNCTION_CODES,
40
41
  c as WORKSPACE_GRANT_ID,
41
42
  D as WRITE_FUNCTION_CODES
42
43
  };
@@ -1,15 +1,15 @@
1
- var B = Object.defineProperty, M = Object.defineProperties;
2
- var U = Object.getOwnPropertyDescriptors;
1
+ var B = Object.defineProperty, L = Object.defineProperties;
2
+ var M = Object.getOwnPropertyDescriptors;
3
3
  var x = Object.getOwnPropertySymbols;
4
- var T = Object.prototype.hasOwnProperty, F = Object.prototype.propertyIsEnumerable;
4
+ var U = Object.prototype.hasOwnProperty, T = Object.prototype.propertyIsEnumerable;
5
5
  var b = (n, t, e) => t in n ? B(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e, m = (n, t) => {
6
6
  for (var e in t || (t = {}))
7
- T.call(t, e) && b(n, e, t[e]);
7
+ U.call(t, e) && b(n, e, t[e]);
8
8
  if (x)
9
9
  for (var e of x(t))
10
- F.call(t, e) && b(n, e, t[e]);
10
+ T.call(t, e) && b(n, e, t[e]);
11
11
  return n;
12
- }, N = (n, t) => M(n, U(t));
12
+ }, N = (n, t) => L(n, M(t));
13
13
  var y = (n, t, e) => (b(n, typeof t != "symbol" ? t + "" : t, e), e);
14
14
  var u = (n, t, e) => new Promise((r, s) => {
15
15
  var o = (a) => {
@@ -29,7 +29,7 @@ var u = (n, t, e) => new Promise((r, s) => {
29
29
  });
30
30
  import { MAX_COMMAND_OUTPUT_CHARS as w } from "../../builtinTools/command.mjs";
31
31
  import { domError as f } from "../adapters/WorkspaceFileAdapter.mjs";
32
- import { SANDBOX_PROTOCOL as A, SANDBOX_MAX_FILE_BYTES as L } from "./protocol.mjs";
32
+ import { SANDBOX_PROTOCOL as A, SANDBOX_MAX_FILE_BYTES as F } from "./protocol.mjs";
33
33
  import { decodeBinaryFrame as v, MAX_BINARY_PAYLOAD as C, encodeBinaryFrame as O } from "./sandboxFrames.mjs";
34
34
  const P = {
35
35
  revision: 0,
@@ -163,7 +163,7 @@ class J {
163
163
  });
164
164
  }
165
165
  read(o) {
166
- return u(this, arguments, function* (t, e = 0, r = L, s) {
166
+ return u(this, arguments, function* (t, e = 0, r = F, s) {
167
167
  const i = this.begin({
168
168
  op: "read",
169
169
  path: t,
@@ -249,6 +249,31 @@ class J {
249
249
  }), c;
250
250
  });
251
251
  }
252
+ skillList(t, e, r, s, o) {
253
+ return u(this, null, function* () {
254
+ const i = yield this.invoke({
255
+ op: "skillList",
256
+ applicationId: t,
257
+ skillId: e,
258
+ version: r,
259
+ path: s
260
+ }, o);
261
+ return typeof i.files == "string" ? i.files : "";
262
+ });
263
+ }
264
+ skillGrep(t, e, r, s, o, i) {
265
+ return u(this, null, function* () {
266
+ const l = yield this.invoke({
267
+ op: "skillGrep",
268
+ applicationId: t,
269
+ skillId: e,
270
+ version: r,
271
+ path: s,
272
+ pattern: o
273
+ }, i);
274
+ return typeof l.matches == "string" ? l.matches : "";
275
+ });
276
+ }
252
277
  installSkill(t, e, r) {
253
278
  return u(this, null, function* () {
254
279
  const s = this.begin(N(m({
@@ -1,4 +1,4 @@
1
- const e = "@glodon-aiot/bot-client-sdk", s = "3.26.0-alpha.26", t = "glodoncv", i = "aiot bot client js sdk", n = "module", g = !1, o = [
1
+ const e = "@glodon-aiot/bot-client-sdk", s = "3.26.0-alpha.27", t = "glodoncv", i = "aiot bot client js sdk", n = "module", g = !1, o = [
2
2
  "aiot",
3
3
  "bot",
4
4
  "bot client",
@@ -68,7 +68,7 @@ const e = "@glodon-aiot/bot-client-sdk", s = "3.26.0-alpha.26", t = "glodoncv",
68
68
  access: "public",
69
69
  registry: "https://registry.npmjs.org/"
70
70
  }, y = {
71
- "@glodon-aiot/apis": "^3.26.0-alpha.26",
71
+ "@glodon-aiot/apis": "^3.26.0-alpha.27",
72
72
  axios: "0.24.0",
73
73
  buffer: "^6.0.3",
74
74
  dayjs: "^1.11.13",