linkque-cli-v2 1.6.16 → 1.6.17

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 (20) hide show
  1. package/dataTransformWorker.js +175 -89
  2. package/linkquejs.js +27598 -9407
  3. package/package.json +1 -1
  4. package/vendor/linkque-agent-appwrite-integrate/data-transform/dataTransformWorker.js +175 -89
  5. package/vendor/linkque-agent-appwrite-integrate/dist/esm/{chunk-ZK7HXMMY.js → chunk-7OYTZGOC.js} +38727 -20374
  6. package/vendor/linkque-agent-appwrite-integrate/dist/esm/{chunk-ZQGBHENQ.js → chunk-EJB2EPNQ.js} +70 -3
  7. package/vendor/linkque-agent-appwrite-integrate/dist/esm/{chunk-2O5AZ546.js → chunk-RSMGFPPK.js} +1 -1
  8. package/vendor/linkque-agent-appwrite-integrate/dist/esm/{chunk-DNTEEBEH.js → chunk-SICWMO5Y.js} +1 -0
  9. package/vendor/linkque-agent-appwrite-integrate/dist/esm/{getMachineId-bsd-JGCLGHFY.js → getMachineId-bsd-NYGVHXGN.js} +1 -1
  10. package/vendor/linkque-agent-appwrite-integrate/dist/esm/{getMachineId-darwin-COHLFNXH.js → getMachineId-darwin-OPTJOAYC.js} +1 -1
  11. package/vendor/linkque-agent-appwrite-integrate/dist/esm/{getMachineId-linux-XV3Z5FQG.js → getMachineId-linux-5SQRYTUJ.js} +1 -1
  12. package/vendor/linkque-agent-appwrite-integrate/dist/esm/{getMachineId-unsupported-FCRKLIZL.js → getMachineId-unsupported-OJE7WPEH.js} +1 -1
  13. package/vendor/linkque-agent-appwrite-integrate/dist/esm/{getMachineId-win-A4WRNVV6.js → getMachineId-win-SLTTCNXU.js} +1 -1
  14. package/vendor/linkque-agent-appwrite-integrate/dist/esm/{mistral-conversations-OEOTQWE5.js → mistral-conversations-C43A6QIS.js} +1 -1
  15. package/vendor/linkque-agent-appwrite-integrate/dist/esm/{otel-WGS5CC2J.js → otel-RUUFBBFE.js} +1 -1
  16. package/vendor/linkque-agent-appwrite-integrate/dist/esm/runtime/handler/chat.js +1566 -191
  17. package/vendor/linkque-agent-appwrite-integrate/dist/esm/runtime/handler/clientCapability.js +3 -3
  18. package/vendor/linkque-agent-appwrite-integrate/dist/esm/runtime/protocol.js +3 -3
  19. package/vendor/linkque-agent-appwrite-integrate/package.json +1 -1
  20. package/worker.js +40895 -22423
@@ -22,7 +22,7 @@ import {
22
22
  RUNTIME_CONFIG_DEFAULTS,
23
23
  RuntimeConfigProvider,
24
24
  isDebugLoggingEnabled
25
- } from "./chunk-ZK7HXMMY.js";
25
+ } from "./chunk-7OYTZGOC.js";
26
26
  import {
27
27
  __commonJS,
28
28
  __require,
@@ -7336,6 +7336,47 @@ var require_agent = __commonJS({
7336
7336
  }
7337
7337
  });
7338
7338
 
7339
+ // ../linkque-agent-appwrite-integrate/dist/esm/runtime/authorizationSchemaDefinition.js
7340
+ var AUTHORIZATION_CHECKPOINT_TABLE = "linkque_authorization_checkpoints";
7341
+ var AUTHORIZATION_CHECKPOINT_COLUMNS = [
7342
+ ...[
7343
+ "ownerId",
7344
+ "agentId",
7345
+ "runId",
7346
+ "threadId",
7347
+ "itemId",
7348
+ "authorizationRequestId",
7349
+ "authSessionId",
7350
+ "expiresAt",
7351
+ "status",
7352
+ "protocolHash"
7353
+ ].map((key) => ({
7354
+ key,
7355
+ type: "varchar",
7356
+ size: key === "authSessionId" ? 256 : 128,
7357
+ required: true,
7358
+ array: false,
7359
+ default: null
7360
+ })),
7361
+ ...["requestJson", "checkpointJson", "presentationJson"].map((key) => ({
7362
+ key,
7363
+ type: "longtext",
7364
+ size: 0,
7365
+ required: false,
7366
+ array: false,
7367
+ default: null
7368
+ })),
7369
+ {
7370
+ key: "nextSeqIndex",
7371
+ type: "integer",
7372
+ size: 0,
7373
+ required: true,
7374
+ array: false,
7375
+ default: null,
7376
+ min: 0
7377
+ }
7378
+ ];
7379
+
7339
7380
  // ../linkque-agent-appwrite-integrate/dist/esm/runtime/appbaseRuntimeConfigProvider.js
7340
7381
  var LINKQUE_ENDPOINT_PRE = "https://linkquegw-pre.alipay.com";
7341
7382
  var APPBASE_RUNTIME_CONFIG_DEFAULTS = Object.freeze({
@@ -15663,6 +15704,7 @@ var API_KEY_HEADER = "x-appwrite-key";
15663
15704
  var TRIGGER_HEADER = "x-appwrite-trigger";
15664
15705
  var ENV_SELECTOR_HEADER = "x-linkque-env";
15665
15706
  var TRACE_ID_HEADER = "x-trace-id";
15707
+ var OTEL_TRACE_ID_HEADER = "x-linkque-otel-trace-id";
15666
15708
  var FRONTEND_APP_ID_HEADER = "x-linkque-alipay-app-id";
15667
15709
  var ALIPAY_AUTH_CODE_HEADER = "x-alipay-authcode";
15668
15710
  var AUTH_UNAVAILABLE_HEADER = "x-linkque-phone-auth-unavailable";
@@ -15742,6 +15784,28 @@ function readTraceId(headers) {
15742
15784
  }
15743
15785
  return void 0;
15744
15786
  }
15787
+ function readOtelTraceId(headers) {
15788
+ if (!headers)
15789
+ return { kind: "missing" };
15790
+ let found = Object.prototype.hasOwnProperty.call(headers, OTEL_TRACE_ID_HEADER);
15791
+ let value = found ? headers[OTEL_TRACE_ID_HEADER] : void 0;
15792
+ if (!found) {
15793
+ for (const [key, candidate] of Object.entries(headers)) {
15794
+ if (key.toLowerCase() === OTEL_TRACE_ID_HEADER) {
15795
+ found = true;
15796
+ value = candidate;
15797
+ break;
15798
+ }
15799
+ }
15800
+ }
15801
+ if (!found)
15802
+ return { kind: "missing" };
15803
+ const raw = headValue(value);
15804
+ if (!raw)
15805
+ return { kind: "invalid" };
15806
+ const traceId = raw.toLowerCase();
15807
+ return /^[0-9a-f]{32}$/u.test(traceId) && traceId !== "00000000000000000000000000000000" ? { kind: "valid", traceId } : { kind: "invalid" };
15808
+ }
15745
15809
  function readFrontendAppId(headers) {
15746
15810
  if (!headers)
15747
15811
  return void 0;
@@ -15896,10 +15960,12 @@ function nonEmpty(value) {
15896
15960
  }
15897
15961
 
15898
15962
  export {
15899
- APPBASE_RUNTIME_CONFIG_DEFAULTS,
15900
- AppbaseRuntimeConfigProvider,
15901
15963
  Query,
15902
15964
  TablesDB,
15965
+ AUTHORIZATION_CHECKPOINT_TABLE,
15966
+ LINKQUE_ENDPOINT_PRE,
15967
+ APPBASE_RUNTIME_CONFIG_DEFAULTS,
15968
+ AppbaseRuntimeConfigProvider,
15903
15969
  resolveRunStorage,
15904
15970
  createAppBaseClient,
15905
15971
  withIsoTimestamp,
@@ -15916,6 +15982,7 @@ export {
15916
15982
  mcpPhoneAuthorizationChallenge,
15917
15983
  readEnvSelector,
15918
15984
  readTraceId,
15985
+ readOtelTraceId,
15919
15986
  readFrontendAppId,
15920
15987
  readAuthenticatedUserId,
15921
15988
  readAppwriteApiKey,
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  EModelProvider
3
- } from "./chunk-ZK7HXMMY.js";
3
+ } from "./chunk-7OYTZGOC.js";
4
4
 
5
5
  // ../linkque-agent-appwrite-integrate/dist/esm/runtime/protocol.js
6
6
  var baked;
@@ -1632,6 +1632,7 @@ var init_esm = __esm({
1632
1632
  export {
1633
1633
  createContextKey,
1634
1634
  ROOT_CONTEXT,
1635
+ isValidTraceId,
1635
1636
  isSpanContextValid,
1636
1637
  SpanKind,
1637
1638
  SpanStatusCode,
@@ -4,7 +4,7 @@ import {
4
4
  import {
5
5
  esm_exports,
6
6
  init_esm
7
- } from "./chunk-DNTEEBEH.js";
7
+ } from "./chunk-SICWMO5Y.js";
8
8
  import {
9
9
  __commonJS,
10
10
  __require,
@@ -4,7 +4,7 @@ import {
4
4
  import {
5
5
  esm_exports,
6
6
  init_esm
7
- } from "./chunk-DNTEEBEH.js";
7
+ } from "./chunk-SICWMO5Y.js";
8
8
  import {
9
9
  __commonJS,
10
10
  __toCommonJS
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  esm_exports,
3
3
  init_esm
4
- } from "./chunk-DNTEEBEH.js";
4
+ } from "./chunk-SICWMO5Y.js";
5
5
  import {
6
6
  __commonJS,
7
7
  __require,
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  esm_exports,
3
3
  init_esm
4
- } from "./chunk-DNTEEBEH.js";
4
+ } from "./chunk-SICWMO5Y.js";
5
5
  import {
6
6
  __commonJS,
7
7
  __toCommonJS
@@ -4,7 +4,7 @@ import {
4
4
  import {
5
5
  esm_exports,
6
6
  init_esm
7
- } from "./chunk-DNTEEBEH.js";
7
+ } from "./chunk-SICWMO5Y.js";
8
8
  import {
9
9
  __commonJS,
10
10
  __require,
@@ -388,7 +388,7 @@ async function getObservabilityModule() {
388
388
  return observabilityModule;
389
389
  }
390
390
  try {
391
- observabilityModule = await import("./otel-WGS5CC2J.js");
391
+ observabilityModule = await import("./otel-RUUFBBFE.js");
392
392
  } catch {
393
393
  observabilityModule = null;
394
394
  }
@@ -258,7 +258,7 @@ import {
258
258
  init_esm,
259
259
  propagation,
260
260
  trace
261
- } from "./chunk-DNTEEBEH.js";
261
+ } from "./chunk-SICWMO5Y.js";
262
262
  import {
263
263
  __export
264
264
  } from "./chunk-2ESYSVXG.js";