@eigenpal/cli 0.10.6 → 0.10.7
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/CHANGELOG.md +6 -0
- package/dist/cli.js +2673 -305
- package/dist/skill/SKILL.md +16 -3
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -17080,8 +17080,138 @@ var require_picocolors = __commonJS((exports, module) => {
|
|
|
17080
17080
|
module.exports.createColors = createColors;
|
|
17081
17081
|
});
|
|
17082
17082
|
|
|
17083
|
+
// ../../node_modules/nanoid/url-alphabet/index.js
|
|
17084
|
+
var urlAlphabet = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
|
|
17085
|
+
|
|
17086
|
+
// ../../node_modules/nanoid/index.js
|
|
17087
|
+
import { webcrypto as crypto } from "node:crypto";
|
|
17088
|
+
function fillPool(bytes) {
|
|
17089
|
+
if (!pool || pool.length < bytes) {
|
|
17090
|
+
pool = Buffer.allocUnsafe(bytes * POOL_SIZE_MULTIPLIER);
|
|
17091
|
+
crypto.getRandomValues(pool);
|
|
17092
|
+
poolOffset = 0;
|
|
17093
|
+
} else if (poolOffset + bytes > pool.length) {
|
|
17094
|
+
crypto.getRandomValues(pool);
|
|
17095
|
+
poolOffset = 0;
|
|
17096
|
+
}
|
|
17097
|
+
poolOffset += bytes;
|
|
17098
|
+
}
|
|
17099
|
+
function nanoid3(size = 21) {
|
|
17100
|
+
fillPool(size |= 0);
|
|
17101
|
+
let id = "";
|
|
17102
|
+
for (let i = poolOffset - size;i < poolOffset; i++) {
|
|
17103
|
+
id += urlAlphabet[pool[i] & 63];
|
|
17104
|
+
}
|
|
17105
|
+
return id;
|
|
17106
|
+
}
|
|
17107
|
+
var POOL_SIZE_MULTIPLIER = 128, pool, poolOffset;
|
|
17108
|
+
var init_nanoid = () => {};
|
|
17109
|
+
|
|
17110
|
+
// ../types/src/core/common.ts
|
|
17111
|
+
function generateId(prefix) {
|
|
17112
|
+
const id = nanoid3();
|
|
17113
|
+
return prefix ? `${prefix}_${id}` : id;
|
|
17114
|
+
}
|
|
17115
|
+
function toJsonSchema(schema) {
|
|
17116
|
+
return exports_external.toJSONSchema(schema, { target: "draft-7" });
|
|
17117
|
+
}
|
|
17118
|
+
var ID_PREFIXES, TimestampSchema, JsonSchemaSchema, BaseEntitySchema;
|
|
17119
|
+
var init_common = __esm(() => {
|
|
17120
|
+
init_nanoid();
|
|
17121
|
+
init_zod();
|
|
17122
|
+
ID_PREFIXES = {
|
|
17123
|
+
WORKFLOW: "wf",
|
|
17124
|
+
WORKFLOW_VERSION: "wfv",
|
|
17125
|
+
WORKFLOW_HISTORY: "wfh",
|
|
17126
|
+
JOB: "job",
|
|
17127
|
+
EXECUTION: "exec",
|
|
17128
|
+
STEP_EXECUTION: "step",
|
|
17129
|
+
FILE: "file",
|
|
17130
|
+
TEMPLATE: "tmpl",
|
|
17131
|
+
USER: "user",
|
|
17132
|
+
TENANT: "org",
|
|
17133
|
+
TENANT_INVITE: "inv",
|
|
17134
|
+
API_KEY: "eig",
|
|
17135
|
+
PROCESSOR: "proc",
|
|
17136
|
+
AI_PROVIDER: "aip",
|
|
17137
|
+
ACCOUNT: "acct",
|
|
17138
|
+
SESSION: "sess",
|
|
17139
|
+
VERIFICATION: "vrf",
|
|
17140
|
+
DATASET: "ds",
|
|
17141
|
+
DATASET_EXAMPLE: "dex",
|
|
17142
|
+
EXPERIMENT: "exp",
|
|
17143
|
+
EXPERIMENT_RUN: "exr",
|
|
17144
|
+
EXPERIMENT_EVALUATION: "evl",
|
|
17145
|
+
EVAL_EXAMPLE: "evx",
|
|
17146
|
+
EVAL_RESULT: "evr",
|
|
17147
|
+
EVAL_BATCH: "evb",
|
|
17148
|
+
RUN_REVIEW: "rev",
|
|
17149
|
+
RUN_REVIEW_CORRECTION: "rvc",
|
|
17150
|
+
TABLE_ROW: "row",
|
|
17151
|
+
FOLDER: "fldr",
|
|
17152
|
+
AGENT_WORKFLOW: "awf",
|
|
17153
|
+
AGENT_EXECUTION: "aex",
|
|
17154
|
+
AGENT_EXAMPLE: "aeg",
|
|
17155
|
+
AGENT_VERSION: "avr",
|
|
17156
|
+
AGENT_TRAINING_SESSION: "ats",
|
|
17157
|
+
AGENT_EXPERIMENT: "aexp",
|
|
17158
|
+
AGENT_EMAIL_ALIAS: "aea",
|
|
17159
|
+
AGENT_EMAIL_INVOCATION: "aei",
|
|
17160
|
+
AUTOMATION_TRIGGER: "atr",
|
|
17161
|
+
FILE_SOURCE_CONFIG: "fsc",
|
|
17162
|
+
SANDBOX_WS_TOKEN: "sws"
|
|
17163
|
+
};
|
|
17164
|
+
TimestampSchema = exports_external.union([exports_external.date(), exports_external.string().datetime()]).transform((val) => {
|
|
17165
|
+
return typeof val === "string" ? new Date(val) : val;
|
|
17166
|
+
});
|
|
17167
|
+
JsonSchemaSchema = exports_external.record(exports_external.string(), exports_external.unknown());
|
|
17168
|
+
BaseEntitySchema = exports_external.object({
|
|
17169
|
+
id: exports_external.string(),
|
|
17170
|
+
createdAt: TimestampSchema.optional(),
|
|
17171
|
+
updatedAt: TimestampSchema.optional()
|
|
17172
|
+
});
|
|
17173
|
+
});
|
|
17174
|
+
|
|
17175
|
+
// ../types/src/core/ids.ts
|
|
17176
|
+
var PROCESSOR_IDS, PARSER_IDS, INPUT_KINDS;
|
|
17177
|
+
var init_ids = __esm(() => {
|
|
17178
|
+
PROCESSOR_IDS = {
|
|
17179
|
+
MERGE: "builtin/merge",
|
|
17180
|
+
DOCUMENT_PARSER: "builtin/parser",
|
|
17181
|
+
EXTRACT: "builtin/extract",
|
|
17182
|
+
SPLIT: "builtin/split",
|
|
17183
|
+
CLASSIFY: "builtin/classify",
|
|
17184
|
+
TEMPLATE: "builtin/template",
|
|
17185
|
+
PDF_EMBEDDER: "builtin/pdf-embedder",
|
|
17186
|
+
XLSX_TO_JSON: "builtin/xlsx-to-json"
|
|
17187
|
+
};
|
|
17188
|
+
PARSER_IDS = {
|
|
17189
|
+
KREUZBERG: "builtin/kreuzberg",
|
|
17190
|
+
OCR: "builtin/ocr",
|
|
17191
|
+
LLM_VISION: "builtin/llm-vision"
|
|
17192
|
+
};
|
|
17193
|
+
INPUT_KINDS = {
|
|
17194
|
+
DOCUMENT: "document",
|
|
17195
|
+
PAYLOAD: "payload"
|
|
17196
|
+
};
|
|
17197
|
+
});
|
|
17198
|
+
|
|
17199
|
+
// ../types/src/core/pagination.ts
|
|
17200
|
+
var PaginationParamsSchema, DEFAULT_PAGE_SIZE = 50, MAX_PAGE_SIZE = 100;
|
|
17201
|
+
var init_pagination = __esm(() => {
|
|
17202
|
+
init_zod();
|
|
17203
|
+
PaginationParamsSchema = exports_external.object({
|
|
17204
|
+
limit: exports_external.coerce.number().int().min(1).max(100).default(50),
|
|
17205
|
+
offset: exports_external.coerce.number().int().min(0).default(0)
|
|
17206
|
+
});
|
|
17207
|
+
});
|
|
17208
|
+
|
|
17083
17209
|
// ../types/src/core/index.ts
|
|
17084
|
-
var init_core3 = () => {
|
|
17210
|
+
var init_core3 = __esm(() => {
|
|
17211
|
+
init_common();
|
|
17212
|
+
init_ids();
|
|
17213
|
+
init_pagination();
|
|
17214
|
+
});
|
|
17085
17215
|
|
|
17086
17216
|
// ../types/src/files/legacy-boundary.ts
|
|
17087
17217
|
var LEGACY_FILE_REF_COMPATIBILITY;
|
|
@@ -17106,6 +17236,9 @@ var init_legacy_boundary = __esm(() => {
|
|
|
17106
17236
|
function isRuntimeFileRef(input) {
|
|
17107
17237
|
return RuntimeFileRefSchema.safeParse(input).success;
|
|
17108
17238
|
}
|
|
17239
|
+
function isFilePathDescriptor(input) {
|
|
17240
|
+
return FilePathDescriptorSchema.safeParse(input).success;
|
|
17241
|
+
}
|
|
17109
17242
|
function isResolvedProcessorFile(input) {
|
|
17110
17243
|
return ResolvedProcessorFileSchema.safeParse(input).success;
|
|
17111
17244
|
}
|
|
@@ -17328,11 +17461,2332 @@ var init_scoped_file_ref = __esm(() => {
|
|
|
17328
17461
|
]);
|
|
17329
17462
|
});
|
|
17330
17463
|
|
|
17464
|
+
// ../../node_modules/@opentelemetry/api/build/src/version.js
|
|
17465
|
+
var require_version = __commonJS((exports) => {
|
|
17466
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17467
|
+
exports.VERSION = undefined;
|
|
17468
|
+
exports.VERSION = "1.9.1";
|
|
17469
|
+
});
|
|
17470
|
+
|
|
17471
|
+
// ../../node_modules/@opentelemetry/api/build/src/internal/semver.js
|
|
17472
|
+
var require_semver = __commonJS((exports) => {
|
|
17473
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17474
|
+
exports.isCompatible = exports._makeCompatibilityCheck = undefined;
|
|
17475
|
+
var version_1 = require_version();
|
|
17476
|
+
var re = /^(\d+)\.(\d+)\.(\d+)(-(.+))?$/;
|
|
17477
|
+
function _makeCompatibilityCheck(ownVersion) {
|
|
17478
|
+
const acceptedVersions = new Set([ownVersion]);
|
|
17479
|
+
const rejectedVersions = new Set;
|
|
17480
|
+
const myVersionMatch = ownVersion.match(re);
|
|
17481
|
+
if (!myVersionMatch) {
|
|
17482
|
+
return () => false;
|
|
17483
|
+
}
|
|
17484
|
+
const ownVersionParsed = {
|
|
17485
|
+
major: +myVersionMatch[1],
|
|
17486
|
+
minor: +myVersionMatch[2],
|
|
17487
|
+
patch: +myVersionMatch[3],
|
|
17488
|
+
prerelease: myVersionMatch[4]
|
|
17489
|
+
};
|
|
17490
|
+
if (ownVersionParsed.prerelease != null) {
|
|
17491
|
+
return function isExactmatch(globalVersion) {
|
|
17492
|
+
return globalVersion === ownVersion;
|
|
17493
|
+
};
|
|
17494
|
+
}
|
|
17495
|
+
function _reject(v) {
|
|
17496
|
+
rejectedVersions.add(v);
|
|
17497
|
+
return false;
|
|
17498
|
+
}
|
|
17499
|
+
function _accept(v) {
|
|
17500
|
+
acceptedVersions.add(v);
|
|
17501
|
+
return true;
|
|
17502
|
+
}
|
|
17503
|
+
return function isCompatible(globalVersion) {
|
|
17504
|
+
if (acceptedVersions.has(globalVersion)) {
|
|
17505
|
+
return true;
|
|
17506
|
+
}
|
|
17507
|
+
if (rejectedVersions.has(globalVersion)) {
|
|
17508
|
+
return false;
|
|
17509
|
+
}
|
|
17510
|
+
const globalVersionMatch = globalVersion.match(re);
|
|
17511
|
+
if (!globalVersionMatch) {
|
|
17512
|
+
return _reject(globalVersion);
|
|
17513
|
+
}
|
|
17514
|
+
const globalVersionParsed = {
|
|
17515
|
+
major: +globalVersionMatch[1],
|
|
17516
|
+
minor: +globalVersionMatch[2],
|
|
17517
|
+
patch: +globalVersionMatch[3],
|
|
17518
|
+
prerelease: globalVersionMatch[4]
|
|
17519
|
+
};
|
|
17520
|
+
if (globalVersionParsed.prerelease != null) {
|
|
17521
|
+
return _reject(globalVersion);
|
|
17522
|
+
}
|
|
17523
|
+
if (ownVersionParsed.major !== globalVersionParsed.major) {
|
|
17524
|
+
return _reject(globalVersion);
|
|
17525
|
+
}
|
|
17526
|
+
if (ownVersionParsed.major === 0) {
|
|
17527
|
+
if (ownVersionParsed.minor === globalVersionParsed.minor && ownVersionParsed.patch <= globalVersionParsed.patch) {
|
|
17528
|
+
return _accept(globalVersion);
|
|
17529
|
+
}
|
|
17530
|
+
return _reject(globalVersion);
|
|
17531
|
+
}
|
|
17532
|
+
if (ownVersionParsed.minor <= globalVersionParsed.minor) {
|
|
17533
|
+
return _accept(globalVersion);
|
|
17534
|
+
}
|
|
17535
|
+
return _reject(globalVersion);
|
|
17536
|
+
};
|
|
17537
|
+
}
|
|
17538
|
+
exports._makeCompatibilityCheck = _makeCompatibilityCheck;
|
|
17539
|
+
exports.isCompatible = _makeCompatibilityCheck(version_1.VERSION);
|
|
17540
|
+
});
|
|
17541
|
+
|
|
17542
|
+
// ../../node_modules/@opentelemetry/api/build/src/internal/global-utils.js
|
|
17543
|
+
var require_global_utils = __commonJS((exports) => {
|
|
17544
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17545
|
+
exports.unregisterGlobal = exports.getGlobal = exports.registerGlobal = undefined;
|
|
17546
|
+
var version_1 = require_version();
|
|
17547
|
+
var semver_1 = require_semver();
|
|
17548
|
+
var major = version_1.VERSION.split(".")[0];
|
|
17549
|
+
var GLOBAL_OPENTELEMETRY_API_KEY = Symbol.for(`opentelemetry.js.api.${major}`);
|
|
17550
|
+
var _global = typeof globalThis === "object" ? globalThis : typeof self === "object" ? self : typeof window === "object" ? window : typeof global === "object" ? global : {};
|
|
17551
|
+
function registerGlobal(type, instance, diag, allowOverride = false) {
|
|
17552
|
+
var _a3;
|
|
17553
|
+
const api2 = _global[GLOBAL_OPENTELEMETRY_API_KEY] = (_a3 = _global[GLOBAL_OPENTELEMETRY_API_KEY]) !== null && _a3 !== undefined ? _a3 : {
|
|
17554
|
+
version: version_1.VERSION
|
|
17555
|
+
};
|
|
17556
|
+
if (!allowOverride && api2[type]) {
|
|
17557
|
+
const err = new Error(`@opentelemetry/api: Attempted duplicate registration of API: ${type}`);
|
|
17558
|
+
diag.error(err.stack || err.message);
|
|
17559
|
+
return false;
|
|
17560
|
+
}
|
|
17561
|
+
if (api2.version !== version_1.VERSION) {
|
|
17562
|
+
const err = new Error(`@opentelemetry/api: Registration of version v${api2.version} for ${type} does not match previously registered API v${version_1.VERSION}`);
|
|
17563
|
+
diag.error(err.stack || err.message);
|
|
17564
|
+
return false;
|
|
17565
|
+
}
|
|
17566
|
+
api2[type] = instance;
|
|
17567
|
+
diag.debug(`@opentelemetry/api: Registered a global for ${type} v${version_1.VERSION}.`);
|
|
17568
|
+
return true;
|
|
17569
|
+
}
|
|
17570
|
+
exports.registerGlobal = registerGlobal;
|
|
17571
|
+
function getGlobal(type) {
|
|
17572
|
+
var _a3, _b;
|
|
17573
|
+
const globalVersion = (_a3 = _global[GLOBAL_OPENTELEMETRY_API_KEY]) === null || _a3 === undefined ? undefined : _a3.version;
|
|
17574
|
+
if (!globalVersion || !(0, semver_1.isCompatible)(globalVersion)) {
|
|
17575
|
+
return;
|
|
17576
|
+
}
|
|
17577
|
+
return (_b = _global[GLOBAL_OPENTELEMETRY_API_KEY]) === null || _b === undefined ? undefined : _b[type];
|
|
17578
|
+
}
|
|
17579
|
+
exports.getGlobal = getGlobal;
|
|
17580
|
+
function unregisterGlobal(type, diag) {
|
|
17581
|
+
diag.debug(`@opentelemetry/api: Unregistering a global for ${type} v${version_1.VERSION}.`);
|
|
17582
|
+
const api2 = _global[GLOBAL_OPENTELEMETRY_API_KEY];
|
|
17583
|
+
if (api2) {
|
|
17584
|
+
delete api2[type];
|
|
17585
|
+
}
|
|
17586
|
+
}
|
|
17587
|
+
exports.unregisterGlobal = unregisterGlobal;
|
|
17588
|
+
});
|
|
17589
|
+
|
|
17590
|
+
// ../../node_modules/@opentelemetry/api/build/src/diag/ComponentLogger.js
|
|
17591
|
+
var require_ComponentLogger = __commonJS((exports) => {
|
|
17592
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17593
|
+
exports.DiagComponentLogger = undefined;
|
|
17594
|
+
var global_utils_1 = require_global_utils();
|
|
17595
|
+
|
|
17596
|
+
class DiagComponentLogger {
|
|
17597
|
+
constructor(props) {
|
|
17598
|
+
this._namespace = props.namespace || "DiagComponentLogger";
|
|
17599
|
+
}
|
|
17600
|
+
debug(...args) {
|
|
17601
|
+
return logProxy("debug", this._namespace, args);
|
|
17602
|
+
}
|
|
17603
|
+
error(...args) {
|
|
17604
|
+
return logProxy("error", this._namespace, args);
|
|
17605
|
+
}
|
|
17606
|
+
info(...args) {
|
|
17607
|
+
return logProxy("info", this._namespace, args);
|
|
17608
|
+
}
|
|
17609
|
+
warn(...args) {
|
|
17610
|
+
return logProxy("warn", this._namespace, args);
|
|
17611
|
+
}
|
|
17612
|
+
verbose(...args) {
|
|
17613
|
+
return logProxy("verbose", this._namespace, args);
|
|
17614
|
+
}
|
|
17615
|
+
}
|
|
17616
|
+
exports.DiagComponentLogger = DiagComponentLogger;
|
|
17617
|
+
function logProxy(funcName, namespace, args) {
|
|
17618
|
+
const logger = (0, global_utils_1.getGlobal)("diag");
|
|
17619
|
+
if (!logger) {
|
|
17620
|
+
return;
|
|
17621
|
+
}
|
|
17622
|
+
return logger[funcName](namespace, ...args);
|
|
17623
|
+
}
|
|
17624
|
+
});
|
|
17625
|
+
|
|
17626
|
+
// ../../node_modules/@opentelemetry/api/build/src/diag/types.js
|
|
17627
|
+
var require_types = __commonJS((exports) => {
|
|
17628
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17629
|
+
exports.DiagLogLevel = undefined;
|
|
17630
|
+
var DiagLogLevel;
|
|
17631
|
+
(function(DiagLogLevel2) {
|
|
17632
|
+
DiagLogLevel2[DiagLogLevel2["NONE"] = 0] = "NONE";
|
|
17633
|
+
DiagLogLevel2[DiagLogLevel2["ERROR"] = 30] = "ERROR";
|
|
17634
|
+
DiagLogLevel2[DiagLogLevel2["WARN"] = 50] = "WARN";
|
|
17635
|
+
DiagLogLevel2[DiagLogLevel2["INFO"] = 60] = "INFO";
|
|
17636
|
+
DiagLogLevel2[DiagLogLevel2["DEBUG"] = 70] = "DEBUG";
|
|
17637
|
+
DiagLogLevel2[DiagLogLevel2["VERBOSE"] = 80] = "VERBOSE";
|
|
17638
|
+
DiagLogLevel2[DiagLogLevel2["ALL"] = 9999] = "ALL";
|
|
17639
|
+
})(DiagLogLevel = exports.DiagLogLevel || (exports.DiagLogLevel = {}));
|
|
17640
|
+
});
|
|
17641
|
+
|
|
17642
|
+
// ../../node_modules/@opentelemetry/api/build/src/diag/internal/logLevelLogger.js
|
|
17643
|
+
var require_logLevelLogger = __commonJS((exports) => {
|
|
17644
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17645
|
+
exports.createLogLevelDiagLogger = undefined;
|
|
17646
|
+
var types_1 = require_types();
|
|
17647
|
+
function createLogLevelDiagLogger(maxLevel, logger) {
|
|
17648
|
+
if (maxLevel < types_1.DiagLogLevel.NONE) {
|
|
17649
|
+
maxLevel = types_1.DiagLogLevel.NONE;
|
|
17650
|
+
} else if (maxLevel > types_1.DiagLogLevel.ALL) {
|
|
17651
|
+
maxLevel = types_1.DiagLogLevel.ALL;
|
|
17652
|
+
}
|
|
17653
|
+
logger = logger || {};
|
|
17654
|
+
function _filterFunc(funcName, theLevel) {
|
|
17655
|
+
const theFunc = logger[funcName];
|
|
17656
|
+
if (typeof theFunc === "function" && maxLevel >= theLevel) {
|
|
17657
|
+
return theFunc.bind(logger);
|
|
17658
|
+
}
|
|
17659
|
+
return function() {};
|
|
17660
|
+
}
|
|
17661
|
+
return {
|
|
17662
|
+
error: _filterFunc("error", types_1.DiagLogLevel.ERROR),
|
|
17663
|
+
warn: _filterFunc("warn", types_1.DiagLogLevel.WARN),
|
|
17664
|
+
info: _filterFunc("info", types_1.DiagLogLevel.INFO),
|
|
17665
|
+
debug: _filterFunc("debug", types_1.DiagLogLevel.DEBUG),
|
|
17666
|
+
verbose: _filterFunc("verbose", types_1.DiagLogLevel.VERBOSE)
|
|
17667
|
+
};
|
|
17668
|
+
}
|
|
17669
|
+
exports.createLogLevelDiagLogger = createLogLevelDiagLogger;
|
|
17670
|
+
});
|
|
17671
|
+
|
|
17672
|
+
// ../../node_modules/@opentelemetry/api/build/src/api/diag.js
|
|
17673
|
+
var require_diag = __commonJS((exports) => {
|
|
17674
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17675
|
+
exports.DiagAPI = undefined;
|
|
17676
|
+
var ComponentLogger_1 = require_ComponentLogger();
|
|
17677
|
+
var logLevelLogger_1 = require_logLevelLogger();
|
|
17678
|
+
var types_1 = require_types();
|
|
17679
|
+
var global_utils_1 = require_global_utils();
|
|
17680
|
+
var API_NAME = "diag";
|
|
17681
|
+
|
|
17682
|
+
class DiagAPI {
|
|
17683
|
+
static instance() {
|
|
17684
|
+
if (!this._instance) {
|
|
17685
|
+
this._instance = new DiagAPI;
|
|
17686
|
+
}
|
|
17687
|
+
return this._instance;
|
|
17688
|
+
}
|
|
17689
|
+
constructor() {
|
|
17690
|
+
function _logProxy(funcName) {
|
|
17691
|
+
return function(...args) {
|
|
17692
|
+
const logger = (0, global_utils_1.getGlobal)("diag");
|
|
17693
|
+
if (!logger)
|
|
17694
|
+
return;
|
|
17695
|
+
return logger[funcName](...args);
|
|
17696
|
+
};
|
|
17697
|
+
}
|
|
17698
|
+
const self2 = this;
|
|
17699
|
+
const setLogger = (logger, optionsOrLogLevel = { logLevel: types_1.DiagLogLevel.INFO }) => {
|
|
17700
|
+
var _a3, _b, _c;
|
|
17701
|
+
if (logger === self2) {
|
|
17702
|
+
const err = new Error("Cannot use diag as the logger for itself. Please use a DiagLogger implementation like ConsoleDiagLogger or a custom implementation");
|
|
17703
|
+
self2.error((_a3 = err.stack) !== null && _a3 !== undefined ? _a3 : err.message);
|
|
17704
|
+
return false;
|
|
17705
|
+
}
|
|
17706
|
+
if (typeof optionsOrLogLevel === "number") {
|
|
17707
|
+
optionsOrLogLevel = {
|
|
17708
|
+
logLevel: optionsOrLogLevel
|
|
17709
|
+
};
|
|
17710
|
+
}
|
|
17711
|
+
const oldLogger = (0, global_utils_1.getGlobal)("diag");
|
|
17712
|
+
const newLogger = (0, logLevelLogger_1.createLogLevelDiagLogger)((_b = optionsOrLogLevel.logLevel) !== null && _b !== undefined ? _b : types_1.DiagLogLevel.INFO, logger);
|
|
17713
|
+
if (oldLogger && !optionsOrLogLevel.suppressOverrideMessage) {
|
|
17714
|
+
const stack = (_c = new Error().stack) !== null && _c !== undefined ? _c : "<failed to generate stacktrace>";
|
|
17715
|
+
oldLogger.warn(`Current logger will be overwritten from ${stack}`);
|
|
17716
|
+
newLogger.warn(`Current logger will overwrite one already registered from ${stack}`);
|
|
17717
|
+
}
|
|
17718
|
+
return (0, global_utils_1.registerGlobal)("diag", newLogger, self2, true);
|
|
17719
|
+
};
|
|
17720
|
+
self2.setLogger = setLogger;
|
|
17721
|
+
self2.disable = () => {
|
|
17722
|
+
(0, global_utils_1.unregisterGlobal)(API_NAME, self2);
|
|
17723
|
+
};
|
|
17724
|
+
self2.createComponentLogger = (options) => {
|
|
17725
|
+
return new ComponentLogger_1.DiagComponentLogger(options);
|
|
17726
|
+
};
|
|
17727
|
+
self2.verbose = _logProxy("verbose");
|
|
17728
|
+
self2.debug = _logProxy("debug");
|
|
17729
|
+
self2.info = _logProxy("info");
|
|
17730
|
+
self2.warn = _logProxy("warn");
|
|
17731
|
+
self2.error = _logProxy("error");
|
|
17732
|
+
}
|
|
17733
|
+
}
|
|
17734
|
+
exports.DiagAPI = DiagAPI;
|
|
17735
|
+
});
|
|
17736
|
+
|
|
17737
|
+
// ../../node_modules/@opentelemetry/api/build/src/baggage/internal/baggage-impl.js
|
|
17738
|
+
var require_baggage_impl = __commonJS((exports) => {
|
|
17739
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17740
|
+
exports.BaggageImpl = undefined;
|
|
17741
|
+
|
|
17742
|
+
class BaggageImpl {
|
|
17743
|
+
constructor(entries) {
|
|
17744
|
+
this._entries = entries ? new Map(entries) : new Map;
|
|
17745
|
+
}
|
|
17746
|
+
getEntry(key) {
|
|
17747
|
+
const entry = this._entries.get(key);
|
|
17748
|
+
if (!entry) {
|
|
17749
|
+
return;
|
|
17750
|
+
}
|
|
17751
|
+
return Object.assign({}, entry);
|
|
17752
|
+
}
|
|
17753
|
+
getAllEntries() {
|
|
17754
|
+
return Array.from(this._entries.entries());
|
|
17755
|
+
}
|
|
17756
|
+
setEntry(key, entry) {
|
|
17757
|
+
const newBaggage = new BaggageImpl(this._entries);
|
|
17758
|
+
newBaggage._entries.set(key, entry);
|
|
17759
|
+
return newBaggage;
|
|
17760
|
+
}
|
|
17761
|
+
removeEntry(key) {
|
|
17762
|
+
const newBaggage = new BaggageImpl(this._entries);
|
|
17763
|
+
newBaggage._entries.delete(key);
|
|
17764
|
+
return newBaggage;
|
|
17765
|
+
}
|
|
17766
|
+
removeEntries(...keys) {
|
|
17767
|
+
const newBaggage = new BaggageImpl(this._entries);
|
|
17768
|
+
for (const key of keys) {
|
|
17769
|
+
newBaggage._entries.delete(key);
|
|
17770
|
+
}
|
|
17771
|
+
return newBaggage;
|
|
17772
|
+
}
|
|
17773
|
+
clear() {
|
|
17774
|
+
return new BaggageImpl;
|
|
17775
|
+
}
|
|
17776
|
+
}
|
|
17777
|
+
exports.BaggageImpl = BaggageImpl;
|
|
17778
|
+
});
|
|
17779
|
+
|
|
17780
|
+
// ../../node_modules/@opentelemetry/api/build/src/baggage/internal/symbol.js
|
|
17781
|
+
var require_symbol = __commonJS((exports) => {
|
|
17782
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17783
|
+
exports.baggageEntryMetadataSymbol = undefined;
|
|
17784
|
+
exports.baggageEntryMetadataSymbol = Symbol("BaggageEntryMetadata");
|
|
17785
|
+
});
|
|
17786
|
+
|
|
17787
|
+
// ../../node_modules/@opentelemetry/api/build/src/baggage/utils.js
|
|
17788
|
+
var require_utils = __commonJS((exports) => {
|
|
17789
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17790
|
+
exports.baggageEntryMetadataFromString = exports.createBaggage = undefined;
|
|
17791
|
+
var diag_1 = require_diag();
|
|
17792
|
+
var baggage_impl_1 = require_baggage_impl();
|
|
17793
|
+
var symbol_1 = require_symbol();
|
|
17794
|
+
var diag = diag_1.DiagAPI.instance();
|
|
17795
|
+
function createBaggage(entries = {}) {
|
|
17796
|
+
return new baggage_impl_1.BaggageImpl(new Map(Object.entries(entries)));
|
|
17797
|
+
}
|
|
17798
|
+
exports.createBaggage = createBaggage;
|
|
17799
|
+
function baggageEntryMetadataFromString(str) {
|
|
17800
|
+
if (typeof str !== "string") {
|
|
17801
|
+
diag.error(`Cannot create baggage metadata from unknown type: ${typeof str}`);
|
|
17802
|
+
str = "";
|
|
17803
|
+
}
|
|
17804
|
+
return {
|
|
17805
|
+
__TYPE__: symbol_1.baggageEntryMetadataSymbol,
|
|
17806
|
+
toString() {
|
|
17807
|
+
return str;
|
|
17808
|
+
}
|
|
17809
|
+
};
|
|
17810
|
+
}
|
|
17811
|
+
exports.baggageEntryMetadataFromString = baggageEntryMetadataFromString;
|
|
17812
|
+
});
|
|
17813
|
+
|
|
17814
|
+
// ../../node_modules/@opentelemetry/api/build/src/context/context.js
|
|
17815
|
+
var require_context = __commonJS((exports) => {
|
|
17816
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17817
|
+
exports.ROOT_CONTEXT = exports.createContextKey = undefined;
|
|
17818
|
+
function createContextKey(description) {
|
|
17819
|
+
return Symbol.for(description);
|
|
17820
|
+
}
|
|
17821
|
+
exports.createContextKey = createContextKey;
|
|
17822
|
+
|
|
17823
|
+
class BaseContext {
|
|
17824
|
+
constructor(parentContext) {
|
|
17825
|
+
const self2 = this;
|
|
17826
|
+
self2._currentContext = parentContext ? new Map(parentContext) : new Map;
|
|
17827
|
+
self2.getValue = (key) => self2._currentContext.get(key);
|
|
17828
|
+
self2.setValue = (key, value) => {
|
|
17829
|
+
const context = new BaseContext(self2._currentContext);
|
|
17830
|
+
context._currentContext.set(key, value);
|
|
17831
|
+
return context;
|
|
17832
|
+
};
|
|
17833
|
+
self2.deleteValue = (key) => {
|
|
17834
|
+
const context = new BaseContext(self2._currentContext);
|
|
17835
|
+
context._currentContext.delete(key);
|
|
17836
|
+
return context;
|
|
17837
|
+
};
|
|
17838
|
+
}
|
|
17839
|
+
}
|
|
17840
|
+
exports.ROOT_CONTEXT = new BaseContext;
|
|
17841
|
+
});
|
|
17842
|
+
|
|
17843
|
+
// ../../node_modules/@opentelemetry/api/build/src/diag/consoleLogger.js
|
|
17844
|
+
var require_consoleLogger = __commonJS((exports) => {
|
|
17845
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17846
|
+
exports.DiagConsoleLogger = exports._originalConsoleMethods = undefined;
|
|
17847
|
+
var consoleMap = [
|
|
17848
|
+
{ n: "error", c: "error" },
|
|
17849
|
+
{ n: "warn", c: "warn" },
|
|
17850
|
+
{ n: "info", c: "info" },
|
|
17851
|
+
{ n: "debug", c: "debug" },
|
|
17852
|
+
{ n: "verbose", c: "trace" }
|
|
17853
|
+
];
|
|
17854
|
+
exports._originalConsoleMethods = {};
|
|
17855
|
+
if (typeof console !== "undefined") {
|
|
17856
|
+
const keys = [
|
|
17857
|
+
"error",
|
|
17858
|
+
"warn",
|
|
17859
|
+
"info",
|
|
17860
|
+
"debug",
|
|
17861
|
+
"trace",
|
|
17862
|
+
"log"
|
|
17863
|
+
];
|
|
17864
|
+
for (const key of keys) {
|
|
17865
|
+
if (typeof console[key] === "function") {
|
|
17866
|
+
exports._originalConsoleMethods[key] = console[key];
|
|
17867
|
+
}
|
|
17868
|
+
}
|
|
17869
|
+
}
|
|
17870
|
+
|
|
17871
|
+
class DiagConsoleLogger {
|
|
17872
|
+
constructor() {
|
|
17873
|
+
function _consoleFunc(funcName) {
|
|
17874
|
+
return function(...args) {
|
|
17875
|
+
let theFunc = exports._originalConsoleMethods[funcName];
|
|
17876
|
+
if (typeof theFunc !== "function") {
|
|
17877
|
+
theFunc = exports._originalConsoleMethods["log"];
|
|
17878
|
+
}
|
|
17879
|
+
if (typeof theFunc !== "function" && console) {
|
|
17880
|
+
theFunc = console[funcName];
|
|
17881
|
+
if (typeof theFunc !== "function") {
|
|
17882
|
+
theFunc = console.log;
|
|
17883
|
+
}
|
|
17884
|
+
}
|
|
17885
|
+
if (typeof theFunc === "function") {
|
|
17886
|
+
return theFunc.apply(console, args);
|
|
17887
|
+
}
|
|
17888
|
+
};
|
|
17889
|
+
}
|
|
17890
|
+
for (let i = 0;i < consoleMap.length; i++) {
|
|
17891
|
+
this[consoleMap[i].n] = _consoleFunc(consoleMap[i].c);
|
|
17892
|
+
}
|
|
17893
|
+
}
|
|
17894
|
+
}
|
|
17895
|
+
exports.DiagConsoleLogger = DiagConsoleLogger;
|
|
17896
|
+
});
|
|
17897
|
+
|
|
17898
|
+
// ../../node_modules/@opentelemetry/api/build/src/metrics/NoopMeter.js
|
|
17899
|
+
var require_NoopMeter = __commonJS((exports) => {
|
|
17900
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17901
|
+
exports.createNoopMeter = exports.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC = exports.NOOP_OBSERVABLE_GAUGE_METRIC = exports.NOOP_OBSERVABLE_COUNTER_METRIC = exports.NOOP_UP_DOWN_COUNTER_METRIC = exports.NOOP_HISTOGRAM_METRIC = exports.NOOP_GAUGE_METRIC = exports.NOOP_COUNTER_METRIC = exports.NOOP_METER = exports.NoopObservableUpDownCounterMetric = exports.NoopObservableGaugeMetric = exports.NoopObservableCounterMetric = exports.NoopObservableMetric = exports.NoopHistogramMetric = exports.NoopGaugeMetric = exports.NoopUpDownCounterMetric = exports.NoopCounterMetric = exports.NoopMetric = exports.NoopMeter = undefined;
|
|
17902
|
+
|
|
17903
|
+
class NoopMeter {
|
|
17904
|
+
constructor() {}
|
|
17905
|
+
createGauge(_name, _options) {
|
|
17906
|
+
return exports.NOOP_GAUGE_METRIC;
|
|
17907
|
+
}
|
|
17908
|
+
createHistogram(_name, _options) {
|
|
17909
|
+
return exports.NOOP_HISTOGRAM_METRIC;
|
|
17910
|
+
}
|
|
17911
|
+
createCounter(_name, _options) {
|
|
17912
|
+
return exports.NOOP_COUNTER_METRIC;
|
|
17913
|
+
}
|
|
17914
|
+
createUpDownCounter(_name, _options) {
|
|
17915
|
+
return exports.NOOP_UP_DOWN_COUNTER_METRIC;
|
|
17916
|
+
}
|
|
17917
|
+
createObservableGauge(_name, _options) {
|
|
17918
|
+
return exports.NOOP_OBSERVABLE_GAUGE_METRIC;
|
|
17919
|
+
}
|
|
17920
|
+
createObservableCounter(_name, _options) {
|
|
17921
|
+
return exports.NOOP_OBSERVABLE_COUNTER_METRIC;
|
|
17922
|
+
}
|
|
17923
|
+
createObservableUpDownCounter(_name, _options) {
|
|
17924
|
+
return exports.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC;
|
|
17925
|
+
}
|
|
17926
|
+
addBatchObservableCallback(_callback, _observables) {}
|
|
17927
|
+
removeBatchObservableCallback(_callback) {}
|
|
17928
|
+
}
|
|
17929
|
+
exports.NoopMeter = NoopMeter;
|
|
17930
|
+
|
|
17931
|
+
class NoopMetric {
|
|
17932
|
+
}
|
|
17933
|
+
exports.NoopMetric = NoopMetric;
|
|
17934
|
+
|
|
17935
|
+
class NoopCounterMetric extends NoopMetric {
|
|
17936
|
+
add(_value, _attributes) {}
|
|
17937
|
+
}
|
|
17938
|
+
exports.NoopCounterMetric = NoopCounterMetric;
|
|
17939
|
+
|
|
17940
|
+
class NoopUpDownCounterMetric extends NoopMetric {
|
|
17941
|
+
add(_value, _attributes) {}
|
|
17942
|
+
}
|
|
17943
|
+
exports.NoopUpDownCounterMetric = NoopUpDownCounterMetric;
|
|
17944
|
+
|
|
17945
|
+
class NoopGaugeMetric extends NoopMetric {
|
|
17946
|
+
record(_value, _attributes) {}
|
|
17947
|
+
}
|
|
17948
|
+
exports.NoopGaugeMetric = NoopGaugeMetric;
|
|
17949
|
+
|
|
17950
|
+
class NoopHistogramMetric extends NoopMetric {
|
|
17951
|
+
record(_value, _attributes) {}
|
|
17952
|
+
}
|
|
17953
|
+
exports.NoopHistogramMetric = NoopHistogramMetric;
|
|
17954
|
+
|
|
17955
|
+
class NoopObservableMetric {
|
|
17956
|
+
addCallback(_callback) {}
|
|
17957
|
+
removeCallback(_callback) {}
|
|
17958
|
+
}
|
|
17959
|
+
exports.NoopObservableMetric = NoopObservableMetric;
|
|
17960
|
+
|
|
17961
|
+
class NoopObservableCounterMetric extends NoopObservableMetric {
|
|
17962
|
+
}
|
|
17963
|
+
exports.NoopObservableCounterMetric = NoopObservableCounterMetric;
|
|
17964
|
+
|
|
17965
|
+
class NoopObservableGaugeMetric extends NoopObservableMetric {
|
|
17966
|
+
}
|
|
17967
|
+
exports.NoopObservableGaugeMetric = NoopObservableGaugeMetric;
|
|
17968
|
+
|
|
17969
|
+
class NoopObservableUpDownCounterMetric extends NoopObservableMetric {
|
|
17970
|
+
}
|
|
17971
|
+
exports.NoopObservableUpDownCounterMetric = NoopObservableUpDownCounterMetric;
|
|
17972
|
+
exports.NOOP_METER = new NoopMeter;
|
|
17973
|
+
exports.NOOP_COUNTER_METRIC = new NoopCounterMetric;
|
|
17974
|
+
exports.NOOP_GAUGE_METRIC = new NoopGaugeMetric;
|
|
17975
|
+
exports.NOOP_HISTOGRAM_METRIC = new NoopHistogramMetric;
|
|
17976
|
+
exports.NOOP_UP_DOWN_COUNTER_METRIC = new NoopUpDownCounterMetric;
|
|
17977
|
+
exports.NOOP_OBSERVABLE_COUNTER_METRIC = new NoopObservableCounterMetric;
|
|
17978
|
+
exports.NOOP_OBSERVABLE_GAUGE_METRIC = new NoopObservableGaugeMetric;
|
|
17979
|
+
exports.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC = new NoopObservableUpDownCounterMetric;
|
|
17980
|
+
function createNoopMeter() {
|
|
17981
|
+
return exports.NOOP_METER;
|
|
17982
|
+
}
|
|
17983
|
+
exports.createNoopMeter = createNoopMeter;
|
|
17984
|
+
});
|
|
17985
|
+
|
|
17986
|
+
// ../../node_modules/@opentelemetry/api/build/src/metrics/Metric.js
|
|
17987
|
+
var require_Metric = __commonJS((exports) => {
|
|
17988
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17989
|
+
exports.ValueType = undefined;
|
|
17990
|
+
var ValueType;
|
|
17991
|
+
(function(ValueType2) {
|
|
17992
|
+
ValueType2[ValueType2["INT"] = 0] = "INT";
|
|
17993
|
+
ValueType2[ValueType2["DOUBLE"] = 1] = "DOUBLE";
|
|
17994
|
+
})(ValueType = exports.ValueType || (exports.ValueType = {}));
|
|
17995
|
+
});
|
|
17996
|
+
|
|
17997
|
+
// ../../node_modules/@opentelemetry/api/build/src/propagation/TextMapPropagator.js
|
|
17998
|
+
var require_TextMapPropagator = __commonJS((exports) => {
|
|
17999
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18000
|
+
exports.defaultTextMapSetter = exports.defaultTextMapGetter = undefined;
|
|
18001
|
+
exports.defaultTextMapGetter = {
|
|
18002
|
+
get(carrier, key) {
|
|
18003
|
+
if (carrier == null) {
|
|
18004
|
+
return;
|
|
18005
|
+
}
|
|
18006
|
+
return carrier[key];
|
|
18007
|
+
},
|
|
18008
|
+
keys(carrier) {
|
|
18009
|
+
if (carrier == null) {
|
|
18010
|
+
return [];
|
|
18011
|
+
}
|
|
18012
|
+
return Object.keys(carrier);
|
|
18013
|
+
}
|
|
18014
|
+
};
|
|
18015
|
+
exports.defaultTextMapSetter = {
|
|
18016
|
+
set(carrier, key, value) {
|
|
18017
|
+
if (carrier == null) {
|
|
18018
|
+
return;
|
|
18019
|
+
}
|
|
18020
|
+
carrier[key] = value;
|
|
18021
|
+
}
|
|
18022
|
+
};
|
|
18023
|
+
});
|
|
18024
|
+
|
|
18025
|
+
// ../../node_modules/@opentelemetry/api/build/src/context/NoopContextManager.js
|
|
18026
|
+
var require_NoopContextManager = __commonJS((exports) => {
|
|
18027
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18028
|
+
exports.NoopContextManager = undefined;
|
|
18029
|
+
var context_1 = require_context();
|
|
18030
|
+
|
|
18031
|
+
class NoopContextManager {
|
|
18032
|
+
active() {
|
|
18033
|
+
return context_1.ROOT_CONTEXT;
|
|
18034
|
+
}
|
|
18035
|
+
with(_context, fn, thisArg, ...args) {
|
|
18036
|
+
return fn.call(thisArg, ...args);
|
|
18037
|
+
}
|
|
18038
|
+
bind(_context, target) {
|
|
18039
|
+
return target;
|
|
18040
|
+
}
|
|
18041
|
+
enable() {
|
|
18042
|
+
return this;
|
|
18043
|
+
}
|
|
18044
|
+
disable() {
|
|
18045
|
+
return this;
|
|
18046
|
+
}
|
|
18047
|
+
}
|
|
18048
|
+
exports.NoopContextManager = NoopContextManager;
|
|
18049
|
+
});
|
|
18050
|
+
|
|
18051
|
+
// ../../node_modules/@opentelemetry/api/build/src/api/context.js
|
|
18052
|
+
var require_context2 = __commonJS((exports) => {
|
|
18053
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18054
|
+
exports.ContextAPI = undefined;
|
|
18055
|
+
var NoopContextManager_1 = require_NoopContextManager();
|
|
18056
|
+
var global_utils_1 = require_global_utils();
|
|
18057
|
+
var diag_1 = require_diag();
|
|
18058
|
+
var API_NAME = "context";
|
|
18059
|
+
var NOOP_CONTEXT_MANAGER = new NoopContextManager_1.NoopContextManager;
|
|
18060
|
+
|
|
18061
|
+
class ContextAPI {
|
|
18062
|
+
constructor() {}
|
|
18063
|
+
static getInstance() {
|
|
18064
|
+
if (!this._instance) {
|
|
18065
|
+
this._instance = new ContextAPI;
|
|
18066
|
+
}
|
|
18067
|
+
return this._instance;
|
|
18068
|
+
}
|
|
18069
|
+
setGlobalContextManager(contextManager) {
|
|
18070
|
+
return (0, global_utils_1.registerGlobal)(API_NAME, contextManager, diag_1.DiagAPI.instance());
|
|
18071
|
+
}
|
|
18072
|
+
active() {
|
|
18073
|
+
return this._getContextManager().active();
|
|
18074
|
+
}
|
|
18075
|
+
with(context, fn, thisArg, ...args) {
|
|
18076
|
+
return this._getContextManager().with(context, fn, thisArg, ...args);
|
|
18077
|
+
}
|
|
18078
|
+
bind(context, target) {
|
|
18079
|
+
return this._getContextManager().bind(context, target);
|
|
18080
|
+
}
|
|
18081
|
+
_getContextManager() {
|
|
18082
|
+
return (0, global_utils_1.getGlobal)(API_NAME) || NOOP_CONTEXT_MANAGER;
|
|
18083
|
+
}
|
|
18084
|
+
disable() {
|
|
18085
|
+
this._getContextManager().disable();
|
|
18086
|
+
(0, global_utils_1.unregisterGlobal)(API_NAME, diag_1.DiagAPI.instance());
|
|
18087
|
+
}
|
|
18088
|
+
}
|
|
18089
|
+
exports.ContextAPI = ContextAPI;
|
|
18090
|
+
});
|
|
18091
|
+
|
|
18092
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/trace_flags.js
|
|
18093
|
+
var require_trace_flags = __commonJS((exports) => {
|
|
18094
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18095
|
+
exports.TraceFlags = undefined;
|
|
18096
|
+
var TraceFlags;
|
|
18097
|
+
(function(TraceFlags2) {
|
|
18098
|
+
TraceFlags2[TraceFlags2["NONE"] = 0] = "NONE";
|
|
18099
|
+
TraceFlags2[TraceFlags2["SAMPLED"] = 1] = "SAMPLED";
|
|
18100
|
+
})(TraceFlags = exports.TraceFlags || (exports.TraceFlags = {}));
|
|
18101
|
+
});
|
|
18102
|
+
|
|
18103
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/invalid-span-constants.js
|
|
18104
|
+
var require_invalid_span_constants = __commonJS((exports) => {
|
|
18105
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18106
|
+
exports.INVALID_SPAN_CONTEXT = exports.INVALID_TRACEID = exports.INVALID_SPANID = undefined;
|
|
18107
|
+
var trace_flags_1 = require_trace_flags();
|
|
18108
|
+
exports.INVALID_SPANID = "0000000000000000";
|
|
18109
|
+
exports.INVALID_TRACEID = "00000000000000000000000000000000";
|
|
18110
|
+
exports.INVALID_SPAN_CONTEXT = {
|
|
18111
|
+
traceId: exports.INVALID_TRACEID,
|
|
18112
|
+
spanId: exports.INVALID_SPANID,
|
|
18113
|
+
traceFlags: trace_flags_1.TraceFlags.NONE
|
|
18114
|
+
};
|
|
18115
|
+
});
|
|
18116
|
+
|
|
18117
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/NonRecordingSpan.js
|
|
18118
|
+
var require_NonRecordingSpan = __commonJS((exports) => {
|
|
18119
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18120
|
+
exports.NonRecordingSpan = undefined;
|
|
18121
|
+
var invalid_span_constants_1 = require_invalid_span_constants();
|
|
18122
|
+
|
|
18123
|
+
class NonRecordingSpan {
|
|
18124
|
+
constructor(spanContext = invalid_span_constants_1.INVALID_SPAN_CONTEXT) {
|
|
18125
|
+
this._spanContext = spanContext;
|
|
18126
|
+
}
|
|
18127
|
+
spanContext() {
|
|
18128
|
+
return this._spanContext;
|
|
18129
|
+
}
|
|
18130
|
+
setAttribute(_key, _value) {
|
|
18131
|
+
return this;
|
|
18132
|
+
}
|
|
18133
|
+
setAttributes(_attributes) {
|
|
18134
|
+
return this;
|
|
18135
|
+
}
|
|
18136
|
+
addEvent(_name, _attributes) {
|
|
18137
|
+
return this;
|
|
18138
|
+
}
|
|
18139
|
+
addLink(_link) {
|
|
18140
|
+
return this;
|
|
18141
|
+
}
|
|
18142
|
+
addLinks(_links) {
|
|
18143
|
+
return this;
|
|
18144
|
+
}
|
|
18145
|
+
setStatus(_status) {
|
|
18146
|
+
return this;
|
|
18147
|
+
}
|
|
18148
|
+
updateName(_name) {
|
|
18149
|
+
return this;
|
|
18150
|
+
}
|
|
18151
|
+
end(_endTime) {}
|
|
18152
|
+
isRecording() {
|
|
18153
|
+
return false;
|
|
18154
|
+
}
|
|
18155
|
+
recordException(_exception, _time) {}
|
|
18156
|
+
}
|
|
18157
|
+
exports.NonRecordingSpan = NonRecordingSpan;
|
|
18158
|
+
});
|
|
18159
|
+
|
|
18160
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/context-utils.js
|
|
18161
|
+
var require_context_utils = __commonJS((exports) => {
|
|
18162
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18163
|
+
exports.getSpanContext = exports.setSpanContext = exports.deleteSpan = exports.setSpan = exports.getActiveSpan = exports.getSpan = undefined;
|
|
18164
|
+
var context_1 = require_context();
|
|
18165
|
+
var NonRecordingSpan_1 = require_NonRecordingSpan();
|
|
18166
|
+
var context_2 = require_context2();
|
|
18167
|
+
var SPAN_KEY = (0, context_1.createContextKey)("OpenTelemetry Context Key SPAN");
|
|
18168
|
+
function getSpan(context) {
|
|
18169
|
+
return context.getValue(SPAN_KEY) || undefined;
|
|
18170
|
+
}
|
|
18171
|
+
exports.getSpan = getSpan;
|
|
18172
|
+
function getActiveSpan() {
|
|
18173
|
+
return getSpan(context_2.ContextAPI.getInstance().active());
|
|
18174
|
+
}
|
|
18175
|
+
exports.getActiveSpan = getActiveSpan;
|
|
18176
|
+
function setSpan(context, span) {
|
|
18177
|
+
return context.setValue(SPAN_KEY, span);
|
|
18178
|
+
}
|
|
18179
|
+
exports.setSpan = setSpan;
|
|
18180
|
+
function deleteSpan(context) {
|
|
18181
|
+
return context.deleteValue(SPAN_KEY);
|
|
18182
|
+
}
|
|
18183
|
+
exports.deleteSpan = deleteSpan;
|
|
18184
|
+
function setSpanContext(context, spanContext) {
|
|
18185
|
+
return setSpan(context, new NonRecordingSpan_1.NonRecordingSpan(spanContext));
|
|
18186
|
+
}
|
|
18187
|
+
exports.setSpanContext = setSpanContext;
|
|
18188
|
+
function getSpanContext(context) {
|
|
18189
|
+
var _a3;
|
|
18190
|
+
return (_a3 = getSpan(context)) === null || _a3 === undefined ? undefined : _a3.spanContext();
|
|
18191
|
+
}
|
|
18192
|
+
exports.getSpanContext = getSpanContext;
|
|
18193
|
+
});
|
|
18194
|
+
|
|
18195
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/spancontext-utils.js
|
|
18196
|
+
var require_spancontext_utils = __commonJS((exports) => {
|
|
18197
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18198
|
+
exports.wrapSpanContext = exports.isSpanContextValid = exports.isValidSpanId = exports.isValidTraceId = undefined;
|
|
18199
|
+
var invalid_span_constants_1 = require_invalid_span_constants();
|
|
18200
|
+
var NonRecordingSpan_1 = require_NonRecordingSpan();
|
|
18201
|
+
var isHex = new Uint8Array([
|
|
18202
|
+
0,
|
|
18203
|
+
0,
|
|
18204
|
+
0,
|
|
18205
|
+
0,
|
|
18206
|
+
0,
|
|
18207
|
+
0,
|
|
18208
|
+
0,
|
|
18209
|
+
0,
|
|
18210
|
+
0,
|
|
18211
|
+
0,
|
|
18212
|
+
0,
|
|
18213
|
+
0,
|
|
18214
|
+
0,
|
|
18215
|
+
0,
|
|
18216
|
+
0,
|
|
18217
|
+
0,
|
|
18218
|
+
0,
|
|
18219
|
+
0,
|
|
18220
|
+
0,
|
|
18221
|
+
0,
|
|
18222
|
+
0,
|
|
18223
|
+
0,
|
|
18224
|
+
0,
|
|
18225
|
+
0,
|
|
18226
|
+
0,
|
|
18227
|
+
0,
|
|
18228
|
+
0,
|
|
18229
|
+
0,
|
|
18230
|
+
0,
|
|
18231
|
+
0,
|
|
18232
|
+
0,
|
|
18233
|
+
0,
|
|
18234
|
+
0,
|
|
18235
|
+
0,
|
|
18236
|
+
0,
|
|
18237
|
+
0,
|
|
18238
|
+
0,
|
|
18239
|
+
0,
|
|
18240
|
+
0,
|
|
18241
|
+
0,
|
|
18242
|
+
0,
|
|
18243
|
+
0,
|
|
18244
|
+
0,
|
|
18245
|
+
0,
|
|
18246
|
+
0,
|
|
18247
|
+
0,
|
|
18248
|
+
0,
|
|
18249
|
+
0,
|
|
18250
|
+
1,
|
|
18251
|
+
1,
|
|
18252
|
+
1,
|
|
18253
|
+
1,
|
|
18254
|
+
1,
|
|
18255
|
+
1,
|
|
18256
|
+
1,
|
|
18257
|
+
1,
|
|
18258
|
+
1,
|
|
18259
|
+
1,
|
|
18260
|
+
0,
|
|
18261
|
+
0,
|
|
18262
|
+
0,
|
|
18263
|
+
0,
|
|
18264
|
+
0,
|
|
18265
|
+
0,
|
|
18266
|
+
0,
|
|
18267
|
+
1,
|
|
18268
|
+
1,
|
|
18269
|
+
1,
|
|
18270
|
+
1,
|
|
18271
|
+
1,
|
|
18272
|
+
1,
|
|
18273
|
+
0,
|
|
18274
|
+
0,
|
|
18275
|
+
0,
|
|
18276
|
+
0,
|
|
18277
|
+
0,
|
|
18278
|
+
0,
|
|
18279
|
+
0,
|
|
18280
|
+
0,
|
|
18281
|
+
0,
|
|
18282
|
+
0,
|
|
18283
|
+
0,
|
|
18284
|
+
0,
|
|
18285
|
+
0,
|
|
18286
|
+
0,
|
|
18287
|
+
0,
|
|
18288
|
+
0,
|
|
18289
|
+
0,
|
|
18290
|
+
0,
|
|
18291
|
+
0,
|
|
18292
|
+
0,
|
|
18293
|
+
0,
|
|
18294
|
+
0,
|
|
18295
|
+
0,
|
|
18296
|
+
0,
|
|
18297
|
+
0,
|
|
18298
|
+
0,
|
|
18299
|
+
1,
|
|
18300
|
+
1,
|
|
18301
|
+
1,
|
|
18302
|
+
1,
|
|
18303
|
+
1,
|
|
18304
|
+
1
|
|
18305
|
+
]);
|
|
18306
|
+
function isValidHex(id, length) {
|
|
18307
|
+
if (typeof id !== "string" || id.length !== length)
|
|
18308
|
+
return false;
|
|
18309
|
+
let r = 0;
|
|
18310
|
+
for (let i = 0;i < id.length; i += 4) {
|
|
18311
|
+
r += (isHex[id.charCodeAt(i)] | 0) + (isHex[id.charCodeAt(i + 1)] | 0) + (isHex[id.charCodeAt(i + 2)] | 0) + (isHex[id.charCodeAt(i + 3)] | 0);
|
|
18312
|
+
}
|
|
18313
|
+
return r === length;
|
|
18314
|
+
}
|
|
18315
|
+
function isValidTraceId(traceId) {
|
|
18316
|
+
return isValidHex(traceId, 32) && traceId !== invalid_span_constants_1.INVALID_TRACEID;
|
|
18317
|
+
}
|
|
18318
|
+
exports.isValidTraceId = isValidTraceId;
|
|
18319
|
+
function isValidSpanId(spanId) {
|
|
18320
|
+
return isValidHex(spanId, 16) && spanId !== invalid_span_constants_1.INVALID_SPANID;
|
|
18321
|
+
}
|
|
18322
|
+
exports.isValidSpanId = isValidSpanId;
|
|
18323
|
+
function isSpanContextValid(spanContext) {
|
|
18324
|
+
return isValidTraceId(spanContext.traceId) && isValidSpanId(spanContext.spanId);
|
|
18325
|
+
}
|
|
18326
|
+
exports.isSpanContextValid = isSpanContextValid;
|
|
18327
|
+
function wrapSpanContext(spanContext) {
|
|
18328
|
+
return new NonRecordingSpan_1.NonRecordingSpan(spanContext);
|
|
18329
|
+
}
|
|
18330
|
+
exports.wrapSpanContext = wrapSpanContext;
|
|
18331
|
+
});
|
|
18332
|
+
|
|
18333
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/NoopTracer.js
|
|
18334
|
+
var require_NoopTracer = __commonJS((exports) => {
|
|
18335
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18336
|
+
exports.NoopTracer = undefined;
|
|
18337
|
+
var context_1 = require_context2();
|
|
18338
|
+
var context_utils_1 = require_context_utils();
|
|
18339
|
+
var NonRecordingSpan_1 = require_NonRecordingSpan();
|
|
18340
|
+
var spancontext_utils_1 = require_spancontext_utils();
|
|
18341
|
+
var contextApi = context_1.ContextAPI.getInstance();
|
|
18342
|
+
|
|
18343
|
+
class NoopTracer {
|
|
18344
|
+
startSpan(name, options, context = contextApi.active()) {
|
|
18345
|
+
const root = Boolean(options === null || options === undefined ? undefined : options.root);
|
|
18346
|
+
if (root) {
|
|
18347
|
+
return new NonRecordingSpan_1.NonRecordingSpan;
|
|
18348
|
+
}
|
|
18349
|
+
const parentFromContext = context && (0, context_utils_1.getSpanContext)(context);
|
|
18350
|
+
if (isSpanContext(parentFromContext) && (0, spancontext_utils_1.isSpanContextValid)(parentFromContext)) {
|
|
18351
|
+
return new NonRecordingSpan_1.NonRecordingSpan(parentFromContext);
|
|
18352
|
+
} else {
|
|
18353
|
+
return new NonRecordingSpan_1.NonRecordingSpan;
|
|
18354
|
+
}
|
|
18355
|
+
}
|
|
18356
|
+
startActiveSpan(name, arg2, arg3, arg4) {
|
|
18357
|
+
let opts;
|
|
18358
|
+
let ctx;
|
|
18359
|
+
let fn;
|
|
18360
|
+
if (arguments.length < 2) {
|
|
18361
|
+
return;
|
|
18362
|
+
} else if (arguments.length === 2) {
|
|
18363
|
+
fn = arg2;
|
|
18364
|
+
} else if (arguments.length === 3) {
|
|
18365
|
+
opts = arg2;
|
|
18366
|
+
fn = arg3;
|
|
18367
|
+
} else {
|
|
18368
|
+
opts = arg2;
|
|
18369
|
+
ctx = arg3;
|
|
18370
|
+
fn = arg4;
|
|
18371
|
+
}
|
|
18372
|
+
const parentContext = ctx !== null && ctx !== undefined ? ctx : contextApi.active();
|
|
18373
|
+
const span = this.startSpan(name, opts, parentContext);
|
|
18374
|
+
const contextWithSpanSet = (0, context_utils_1.setSpan)(parentContext, span);
|
|
18375
|
+
return contextApi.with(contextWithSpanSet, fn, undefined, span);
|
|
18376
|
+
}
|
|
18377
|
+
}
|
|
18378
|
+
exports.NoopTracer = NoopTracer;
|
|
18379
|
+
function isSpanContext(spanContext) {
|
|
18380
|
+
return spanContext !== null && typeof spanContext === "object" && "spanId" in spanContext && typeof spanContext["spanId"] === "string" && "traceId" in spanContext && typeof spanContext["traceId"] === "string" && "traceFlags" in spanContext && typeof spanContext["traceFlags"] === "number";
|
|
18381
|
+
}
|
|
18382
|
+
});
|
|
18383
|
+
|
|
18384
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/ProxyTracer.js
|
|
18385
|
+
var require_ProxyTracer = __commonJS((exports) => {
|
|
18386
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18387
|
+
exports.ProxyTracer = undefined;
|
|
18388
|
+
var NoopTracer_1 = require_NoopTracer();
|
|
18389
|
+
var NOOP_TRACER = new NoopTracer_1.NoopTracer;
|
|
18390
|
+
|
|
18391
|
+
class ProxyTracer {
|
|
18392
|
+
constructor(provider, name, version2, options) {
|
|
18393
|
+
this._provider = provider;
|
|
18394
|
+
this.name = name;
|
|
18395
|
+
this.version = version2;
|
|
18396
|
+
this.options = options;
|
|
18397
|
+
}
|
|
18398
|
+
startSpan(name, options, context) {
|
|
18399
|
+
return this._getTracer().startSpan(name, options, context);
|
|
18400
|
+
}
|
|
18401
|
+
startActiveSpan(_name, _options, _context, _fn) {
|
|
18402
|
+
const tracer = this._getTracer();
|
|
18403
|
+
return Reflect.apply(tracer.startActiveSpan, tracer, arguments);
|
|
18404
|
+
}
|
|
18405
|
+
_getTracer() {
|
|
18406
|
+
if (this._delegate) {
|
|
18407
|
+
return this._delegate;
|
|
18408
|
+
}
|
|
18409
|
+
const tracer = this._provider.getDelegateTracer(this.name, this.version, this.options);
|
|
18410
|
+
if (!tracer) {
|
|
18411
|
+
return NOOP_TRACER;
|
|
18412
|
+
}
|
|
18413
|
+
this._delegate = tracer;
|
|
18414
|
+
return this._delegate;
|
|
18415
|
+
}
|
|
18416
|
+
}
|
|
18417
|
+
exports.ProxyTracer = ProxyTracer;
|
|
18418
|
+
});
|
|
18419
|
+
|
|
18420
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/NoopTracerProvider.js
|
|
18421
|
+
var require_NoopTracerProvider = __commonJS((exports) => {
|
|
18422
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18423
|
+
exports.NoopTracerProvider = undefined;
|
|
18424
|
+
var NoopTracer_1 = require_NoopTracer();
|
|
18425
|
+
|
|
18426
|
+
class NoopTracerProvider {
|
|
18427
|
+
getTracer(_name, _version, _options) {
|
|
18428
|
+
return new NoopTracer_1.NoopTracer;
|
|
18429
|
+
}
|
|
18430
|
+
}
|
|
18431
|
+
exports.NoopTracerProvider = NoopTracerProvider;
|
|
18432
|
+
});
|
|
18433
|
+
|
|
18434
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/ProxyTracerProvider.js
|
|
18435
|
+
var require_ProxyTracerProvider = __commonJS((exports) => {
|
|
18436
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18437
|
+
exports.ProxyTracerProvider = undefined;
|
|
18438
|
+
var ProxyTracer_1 = require_ProxyTracer();
|
|
18439
|
+
var NoopTracerProvider_1 = require_NoopTracerProvider();
|
|
18440
|
+
var NOOP_TRACER_PROVIDER = new NoopTracerProvider_1.NoopTracerProvider;
|
|
18441
|
+
|
|
18442
|
+
class ProxyTracerProvider {
|
|
18443
|
+
getTracer(name, version2, options) {
|
|
18444
|
+
var _a3;
|
|
18445
|
+
return (_a3 = this.getDelegateTracer(name, version2, options)) !== null && _a3 !== undefined ? _a3 : new ProxyTracer_1.ProxyTracer(this, name, version2, options);
|
|
18446
|
+
}
|
|
18447
|
+
getDelegate() {
|
|
18448
|
+
var _a3;
|
|
18449
|
+
return (_a3 = this._delegate) !== null && _a3 !== undefined ? _a3 : NOOP_TRACER_PROVIDER;
|
|
18450
|
+
}
|
|
18451
|
+
setDelegate(delegate) {
|
|
18452
|
+
this._delegate = delegate;
|
|
18453
|
+
}
|
|
18454
|
+
getDelegateTracer(name, version2, options) {
|
|
18455
|
+
var _a3;
|
|
18456
|
+
return (_a3 = this._delegate) === null || _a3 === undefined ? undefined : _a3.getTracer(name, version2, options);
|
|
18457
|
+
}
|
|
18458
|
+
}
|
|
18459
|
+
exports.ProxyTracerProvider = ProxyTracerProvider;
|
|
18460
|
+
});
|
|
18461
|
+
|
|
18462
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/SamplingResult.js
|
|
18463
|
+
var require_SamplingResult = __commonJS((exports) => {
|
|
18464
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18465
|
+
exports.SamplingDecision = undefined;
|
|
18466
|
+
var SamplingDecision;
|
|
18467
|
+
(function(SamplingDecision2) {
|
|
18468
|
+
SamplingDecision2[SamplingDecision2["NOT_RECORD"] = 0] = "NOT_RECORD";
|
|
18469
|
+
SamplingDecision2[SamplingDecision2["RECORD"] = 1] = "RECORD";
|
|
18470
|
+
SamplingDecision2[SamplingDecision2["RECORD_AND_SAMPLED"] = 2] = "RECORD_AND_SAMPLED";
|
|
18471
|
+
})(SamplingDecision = exports.SamplingDecision || (exports.SamplingDecision = {}));
|
|
18472
|
+
});
|
|
18473
|
+
|
|
18474
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/span_kind.js
|
|
18475
|
+
var require_span_kind = __commonJS((exports) => {
|
|
18476
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18477
|
+
exports.SpanKind = undefined;
|
|
18478
|
+
var SpanKind;
|
|
18479
|
+
(function(SpanKind2) {
|
|
18480
|
+
SpanKind2[SpanKind2["INTERNAL"] = 0] = "INTERNAL";
|
|
18481
|
+
SpanKind2[SpanKind2["SERVER"] = 1] = "SERVER";
|
|
18482
|
+
SpanKind2[SpanKind2["CLIENT"] = 2] = "CLIENT";
|
|
18483
|
+
SpanKind2[SpanKind2["PRODUCER"] = 3] = "PRODUCER";
|
|
18484
|
+
SpanKind2[SpanKind2["CONSUMER"] = 4] = "CONSUMER";
|
|
18485
|
+
})(SpanKind = exports.SpanKind || (exports.SpanKind = {}));
|
|
18486
|
+
});
|
|
18487
|
+
|
|
18488
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/status.js
|
|
18489
|
+
var require_status = __commonJS((exports) => {
|
|
18490
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18491
|
+
exports.SpanStatusCode = undefined;
|
|
18492
|
+
var SpanStatusCode;
|
|
18493
|
+
(function(SpanStatusCode2) {
|
|
18494
|
+
SpanStatusCode2[SpanStatusCode2["UNSET"] = 0] = "UNSET";
|
|
18495
|
+
SpanStatusCode2[SpanStatusCode2["OK"] = 1] = "OK";
|
|
18496
|
+
SpanStatusCode2[SpanStatusCode2["ERROR"] = 2] = "ERROR";
|
|
18497
|
+
})(SpanStatusCode = exports.SpanStatusCode || (exports.SpanStatusCode = {}));
|
|
18498
|
+
});
|
|
18499
|
+
|
|
18500
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/internal/tracestate-validators.js
|
|
18501
|
+
var require_tracestate_validators = __commonJS((exports) => {
|
|
18502
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18503
|
+
exports.validateValue = exports.validateKey = undefined;
|
|
18504
|
+
var VALID_KEY_CHAR_RANGE = "[_0-9a-z-*/]";
|
|
18505
|
+
var VALID_KEY = `[a-z]${VALID_KEY_CHAR_RANGE}{0,255}`;
|
|
18506
|
+
var VALID_VENDOR_KEY = `[a-z0-9]${VALID_KEY_CHAR_RANGE}{0,240}@[a-z]${VALID_KEY_CHAR_RANGE}{0,13}`;
|
|
18507
|
+
var VALID_KEY_REGEX = new RegExp(`^(?:${VALID_KEY}|${VALID_VENDOR_KEY})$`);
|
|
18508
|
+
var VALID_VALUE_BASE_REGEX = /^[ -~]{0,255}[!-~]$/;
|
|
18509
|
+
var INVALID_VALUE_COMMA_EQUAL_REGEX = /,|=/;
|
|
18510
|
+
function validateKey(key) {
|
|
18511
|
+
return VALID_KEY_REGEX.test(key);
|
|
18512
|
+
}
|
|
18513
|
+
exports.validateKey = validateKey;
|
|
18514
|
+
function validateValue(value) {
|
|
18515
|
+
return VALID_VALUE_BASE_REGEX.test(value) && !INVALID_VALUE_COMMA_EQUAL_REGEX.test(value);
|
|
18516
|
+
}
|
|
18517
|
+
exports.validateValue = validateValue;
|
|
18518
|
+
});
|
|
18519
|
+
|
|
18520
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/internal/tracestate-impl.js
|
|
18521
|
+
var require_tracestate_impl = __commonJS((exports) => {
|
|
18522
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18523
|
+
exports.TraceStateImpl = undefined;
|
|
18524
|
+
var tracestate_validators_1 = require_tracestate_validators();
|
|
18525
|
+
var MAX_TRACE_STATE_ITEMS = 32;
|
|
18526
|
+
var MAX_TRACE_STATE_LEN = 512;
|
|
18527
|
+
var LIST_MEMBERS_SEPARATOR = ",";
|
|
18528
|
+
var LIST_MEMBER_KEY_VALUE_SPLITTER = "=";
|
|
18529
|
+
|
|
18530
|
+
class TraceStateImpl {
|
|
18531
|
+
constructor(rawTraceState) {
|
|
18532
|
+
this._internalState = new Map;
|
|
18533
|
+
if (rawTraceState)
|
|
18534
|
+
this._parse(rawTraceState);
|
|
18535
|
+
}
|
|
18536
|
+
set(key, value) {
|
|
18537
|
+
const traceState = this._clone();
|
|
18538
|
+
if (traceState._internalState.has(key)) {
|
|
18539
|
+
traceState._internalState.delete(key);
|
|
18540
|
+
}
|
|
18541
|
+
traceState._internalState.set(key, value);
|
|
18542
|
+
return traceState;
|
|
18543
|
+
}
|
|
18544
|
+
unset(key) {
|
|
18545
|
+
const traceState = this._clone();
|
|
18546
|
+
traceState._internalState.delete(key);
|
|
18547
|
+
return traceState;
|
|
18548
|
+
}
|
|
18549
|
+
get(key) {
|
|
18550
|
+
return this._internalState.get(key);
|
|
18551
|
+
}
|
|
18552
|
+
serialize() {
|
|
18553
|
+
return Array.from(this._internalState.keys()).reduceRight((agg, key) => {
|
|
18554
|
+
agg.push(key + LIST_MEMBER_KEY_VALUE_SPLITTER + this.get(key));
|
|
18555
|
+
return agg;
|
|
18556
|
+
}, []).join(LIST_MEMBERS_SEPARATOR);
|
|
18557
|
+
}
|
|
18558
|
+
_parse(rawTraceState) {
|
|
18559
|
+
if (rawTraceState.length > MAX_TRACE_STATE_LEN)
|
|
18560
|
+
return;
|
|
18561
|
+
this._internalState = rawTraceState.split(LIST_MEMBERS_SEPARATOR).reduceRight((agg, part) => {
|
|
18562
|
+
const listMember = part.trim();
|
|
18563
|
+
const i = listMember.indexOf(LIST_MEMBER_KEY_VALUE_SPLITTER);
|
|
18564
|
+
if (i !== -1) {
|
|
18565
|
+
const key = listMember.slice(0, i);
|
|
18566
|
+
const value = listMember.slice(i + 1, part.length);
|
|
18567
|
+
if ((0, tracestate_validators_1.validateKey)(key) && (0, tracestate_validators_1.validateValue)(value)) {
|
|
18568
|
+
agg.set(key, value);
|
|
18569
|
+
}
|
|
18570
|
+
}
|
|
18571
|
+
return agg;
|
|
18572
|
+
}, new Map);
|
|
18573
|
+
if (this._internalState.size > MAX_TRACE_STATE_ITEMS) {
|
|
18574
|
+
this._internalState = new Map(Array.from(this._internalState.entries()).reverse().slice(0, MAX_TRACE_STATE_ITEMS));
|
|
18575
|
+
}
|
|
18576
|
+
}
|
|
18577
|
+
_keys() {
|
|
18578
|
+
return Array.from(this._internalState.keys()).reverse();
|
|
18579
|
+
}
|
|
18580
|
+
_clone() {
|
|
18581
|
+
const traceState = new TraceStateImpl;
|
|
18582
|
+
traceState._internalState = new Map(this._internalState);
|
|
18583
|
+
return traceState;
|
|
18584
|
+
}
|
|
18585
|
+
}
|
|
18586
|
+
exports.TraceStateImpl = TraceStateImpl;
|
|
18587
|
+
});
|
|
18588
|
+
|
|
18589
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace/internal/utils.js
|
|
18590
|
+
var require_utils2 = __commonJS((exports) => {
|
|
18591
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18592
|
+
exports.createTraceState = undefined;
|
|
18593
|
+
var tracestate_impl_1 = require_tracestate_impl();
|
|
18594
|
+
function createTraceState(rawTraceState) {
|
|
18595
|
+
return new tracestate_impl_1.TraceStateImpl(rawTraceState);
|
|
18596
|
+
}
|
|
18597
|
+
exports.createTraceState = createTraceState;
|
|
18598
|
+
});
|
|
18599
|
+
|
|
18600
|
+
// ../../node_modules/@opentelemetry/api/build/src/context-api.js
|
|
18601
|
+
var require_context_api = __commonJS((exports) => {
|
|
18602
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18603
|
+
exports.context = undefined;
|
|
18604
|
+
var context_1 = require_context2();
|
|
18605
|
+
exports.context = context_1.ContextAPI.getInstance();
|
|
18606
|
+
});
|
|
18607
|
+
|
|
18608
|
+
// ../../node_modules/@opentelemetry/api/build/src/diag-api.js
|
|
18609
|
+
var require_diag_api = __commonJS((exports) => {
|
|
18610
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18611
|
+
exports.diag = undefined;
|
|
18612
|
+
var diag_1 = require_diag();
|
|
18613
|
+
exports.diag = diag_1.DiagAPI.instance();
|
|
18614
|
+
});
|
|
18615
|
+
|
|
18616
|
+
// ../../node_modules/@opentelemetry/api/build/src/metrics/NoopMeterProvider.js
|
|
18617
|
+
var require_NoopMeterProvider = __commonJS((exports) => {
|
|
18618
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18619
|
+
exports.NOOP_METER_PROVIDER = exports.NoopMeterProvider = undefined;
|
|
18620
|
+
var NoopMeter_1 = require_NoopMeter();
|
|
18621
|
+
|
|
18622
|
+
class NoopMeterProvider {
|
|
18623
|
+
getMeter(_name, _version, _options) {
|
|
18624
|
+
return NoopMeter_1.NOOP_METER;
|
|
18625
|
+
}
|
|
18626
|
+
}
|
|
18627
|
+
exports.NoopMeterProvider = NoopMeterProvider;
|
|
18628
|
+
exports.NOOP_METER_PROVIDER = new NoopMeterProvider;
|
|
18629
|
+
});
|
|
18630
|
+
|
|
18631
|
+
// ../../node_modules/@opentelemetry/api/build/src/api/metrics.js
|
|
18632
|
+
var require_metrics = __commonJS((exports) => {
|
|
18633
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18634
|
+
exports.MetricsAPI = undefined;
|
|
18635
|
+
var NoopMeterProvider_1 = require_NoopMeterProvider();
|
|
18636
|
+
var global_utils_1 = require_global_utils();
|
|
18637
|
+
var diag_1 = require_diag();
|
|
18638
|
+
var API_NAME = "metrics";
|
|
18639
|
+
|
|
18640
|
+
class MetricsAPI {
|
|
18641
|
+
constructor() {}
|
|
18642
|
+
static getInstance() {
|
|
18643
|
+
if (!this._instance) {
|
|
18644
|
+
this._instance = new MetricsAPI;
|
|
18645
|
+
}
|
|
18646
|
+
return this._instance;
|
|
18647
|
+
}
|
|
18648
|
+
setGlobalMeterProvider(provider) {
|
|
18649
|
+
return (0, global_utils_1.registerGlobal)(API_NAME, provider, diag_1.DiagAPI.instance());
|
|
18650
|
+
}
|
|
18651
|
+
getMeterProvider() {
|
|
18652
|
+
return (0, global_utils_1.getGlobal)(API_NAME) || NoopMeterProvider_1.NOOP_METER_PROVIDER;
|
|
18653
|
+
}
|
|
18654
|
+
getMeter(name, version2, options) {
|
|
18655
|
+
return this.getMeterProvider().getMeter(name, version2, options);
|
|
18656
|
+
}
|
|
18657
|
+
disable() {
|
|
18658
|
+
(0, global_utils_1.unregisterGlobal)(API_NAME, diag_1.DiagAPI.instance());
|
|
18659
|
+
}
|
|
18660
|
+
}
|
|
18661
|
+
exports.MetricsAPI = MetricsAPI;
|
|
18662
|
+
});
|
|
18663
|
+
|
|
18664
|
+
// ../../node_modules/@opentelemetry/api/build/src/metrics-api.js
|
|
18665
|
+
var require_metrics_api = __commonJS((exports) => {
|
|
18666
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18667
|
+
exports.metrics = undefined;
|
|
18668
|
+
var metrics_1 = require_metrics();
|
|
18669
|
+
exports.metrics = metrics_1.MetricsAPI.getInstance();
|
|
18670
|
+
});
|
|
18671
|
+
|
|
18672
|
+
// ../../node_modules/@opentelemetry/api/build/src/propagation/NoopTextMapPropagator.js
|
|
18673
|
+
var require_NoopTextMapPropagator = __commonJS((exports) => {
|
|
18674
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18675
|
+
exports.NoopTextMapPropagator = undefined;
|
|
18676
|
+
|
|
18677
|
+
class NoopTextMapPropagator {
|
|
18678
|
+
inject(_context, _carrier) {}
|
|
18679
|
+
extract(context, _carrier) {
|
|
18680
|
+
return context;
|
|
18681
|
+
}
|
|
18682
|
+
fields() {
|
|
18683
|
+
return [];
|
|
18684
|
+
}
|
|
18685
|
+
}
|
|
18686
|
+
exports.NoopTextMapPropagator = NoopTextMapPropagator;
|
|
18687
|
+
});
|
|
18688
|
+
|
|
18689
|
+
// ../../node_modules/@opentelemetry/api/build/src/baggage/context-helpers.js
|
|
18690
|
+
var require_context_helpers = __commonJS((exports) => {
|
|
18691
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18692
|
+
exports.deleteBaggage = exports.setBaggage = exports.getActiveBaggage = exports.getBaggage = undefined;
|
|
18693
|
+
var context_1 = require_context2();
|
|
18694
|
+
var context_2 = require_context();
|
|
18695
|
+
var BAGGAGE_KEY = (0, context_2.createContextKey)("OpenTelemetry Baggage Key");
|
|
18696
|
+
function getBaggage(context) {
|
|
18697
|
+
return context.getValue(BAGGAGE_KEY) || undefined;
|
|
18698
|
+
}
|
|
18699
|
+
exports.getBaggage = getBaggage;
|
|
18700
|
+
function getActiveBaggage() {
|
|
18701
|
+
return getBaggage(context_1.ContextAPI.getInstance().active());
|
|
18702
|
+
}
|
|
18703
|
+
exports.getActiveBaggage = getActiveBaggage;
|
|
18704
|
+
function setBaggage(context, baggage) {
|
|
18705
|
+
return context.setValue(BAGGAGE_KEY, baggage);
|
|
18706
|
+
}
|
|
18707
|
+
exports.setBaggage = setBaggage;
|
|
18708
|
+
function deleteBaggage(context) {
|
|
18709
|
+
return context.deleteValue(BAGGAGE_KEY);
|
|
18710
|
+
}
|
|
18711
|
+
exports.deleteBaggage = deleteBaggage;
|
|
18712
|
+
});
|
|
18713
|
+
|
|
18714
|
+
// ../../node_modules/@opentelemetry/api/build/src/api/propagation.js
|
|
18715
|
+
var require_propagation = __commonJS((exports) => {
|
|
18716
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18717
|
+
exports.PropagationAPI = undefined;
|
|
18718
|
+
var global_utils_1 = require_global_utils();
|
|
18719
|
+
var NoopTextMapPropagator_1 = require_NoopTextMapPropagator();
|
|
18720
|
+
var TextMapPropagator_1 = require_TextMapPropagator();
|
|
18721
|
+
var context_helpers_1 = require_context_helpers();
|
|
18722
|
+
var utils_1 = require_utils();
|
|
18723
|
+
var diag_1 = require_diag();
|
|
18724
|
+
var API_NAME = "propagation";
|
|
18725
|
+
var NOOP_TEXT_MAP_PROPAGATOR = new NoopTextMapPropagator_1.NoopTextMapPropagator;
|
|
18726
|
+
|
|
18727
|
+
class PropagationAPI {
|
|
18728
|
+
constructor() {
|
|
18729
|
+
this.createBaggage = utils_1.createBaggage;
|
|
18730
|
+
this.getBaggage = context_helpers_1.getBaggage;
|
|
18731
|
+
this.getActiveBaggage = context_helpers_1.getActiveBaggage;
|
|
18732
|
+
this.setBaggage = context_helpers_1.setBaggage;
|
|
18733
|
+
this.deleteBaggage = context_helpers_1.deleteBaggage;
|
|
18734
|
+
}
|
|
18735
|
+
static getInstance() {
|
|
18736
|
+
if (!this._instance) {
|
|
18737
|
+
this._instance = new PropagationAPI;
|
|
18738
|
+
}
|
|
18739
|
+
return this._instance;
|
|
18740
|
+
}
|
|
18741
|
+
setGlobalPropagator(propagator) {
|
|
18742
|
+
return (0, global_utils_1.registerGlobal)(API_NAME, propagator, diag_1.DiagAPI.instance());
|
|
18743
|
+
}
|
|
18744
|
+
inject(context, carrier, setter = TextMapPropagator_1.defaultTextMapSetter) {
|
|
18745
|
+
return this._getGlobalPropagator().inject(context, carrier, setter);
|
|
18746
|
+
}
|
|
18747
|
+
extract(context, carrier, getter = TextMapPropagator_1.defaultTextMapGetter) {
|
|
18748
|
+
return this._getGlobalPropagator().extract(context, carrier, getter);
|
|
18749
|
+
}
|
|
18750
|
+
fields() {
|
|
18751
|
+
return this._getGlobalPropagator().fields();
|
|
18752
|
+
}
|
|
18753
|
+
disable() {
|
|
18754
|
+
(0, global_utils_1.unregisterGlobal)(API_NAME, diag_1.DiagAPI.instance());
|
|
18755
|
+
}
|
|
18756
|
+
_getGlobalPropagator() {
|
|
18757
|
+
return (0, global_utils_1.getGlobal)(API_NAME) || NOOP_TEXT_MAP_PROPAGATOR;
|
|
18758
|
+
}
|
|
18759
|
+
}
|
|
18760
|
+
exports.PropagationAPI = PropagationAPI;
|
|
18761
|
+
});
|
|
18762
|
+
|
|
18763
|
+
// ../../node_modules/@opentelemetry/api/build/src/propagation-api.js
|
|
18764
|
+
var require_propagation_api = __commonJS((exports) => {
|
|
18765
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18766
|
+
exports.propagation = undefined;
|
|
18767
|
+
var propagation_1 = require_propagation();
|
|
18768
|
+
exports.propagation = propagation_1.PropagationAPI.getInstance();
|
|
18769
|
+
});
|
|
18770
|
+
|
|
18771
|
+
// ../../node_modules/@opentelemetry/api/build/src/api/trace.js
|
|
18772
|
+
var require_trace = __commonJS((exports) => {
|
|
18773
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18774
|
+
exports.TraceAPI = undefined;
|
|
18775
|
+
var global_utils_1 = require_global_utils();
|
|
18776
|
+
var ProxyTracerProvider_1 = require_ProxyTracerProvider();
|
|
18777
|
+
var spancontext_utils_1 = require_spancontext_utils();
|
|
18778
|
+
var context_utils_1 = require_context_utils();
|
|
18779
|
+
var diag_1 = require_diag();
|
|
18780
|
+
var API_NAME = "trace";
|
|
18781
|
+
|
|
18782
|
+
class TraceAPI {
|
|
18783
|
+
constructor() {
|
|
18784
|
+
this._proxyTracerProvider = new ProxyTracerProvider_1.ProxyTracerProvider;
|
|
18785
|
+
this.wrapSpanContext = spancontext_utils_1.wrapSpanContext;
|
|
18786
|
+
this.isSpanContextValid = spancontext_utils_1.isSpanContextValid;
|
|
18787
|
+
this.deleteSpan = context_utils_1.deleteSpan;
|
|
18788
|
+
this.getSpan = context_utils_1.getSpan;
|
|
18789
|
+
this.getActiveSpan = context_utils_1.getActiveSpan;
|
|
18790
|
+
this.getSpanContext = context_utils_1.getSpanContext;
|
|
18791
|
+
this.setSpan = context_utils_1.setSpan;
|
|
18792
|
+
this.setSpanContext = context_utils_1.setSpanContext;
|
|
18793
|
+
}
|
|
18794
|
+
static getInstance() {
|
|
18795
|
+
if (!this._instance) {
|
|
18796
|
+
this._instance = new TraceAPI;
|
|
18797
|
+
}
|
|
18798
|
+
return this._instance;
|
|
18799
|
+
}
|
|
18800
|
+
setGlobalTracerProvider(provider) {
|
|
18801
|
+
const success3 = (0, global_utils_1.registerGlobal)(API_NAME, this._proxyTracerProvider, diag_1.DiagAPI.instance());
|
|
18802
|
+
if (success3) {
|
|
18803
|
+
this._proxyTracerProvider.setDelegate(provider);
|
|
18804
|
+
}
|
|
18805
|
+
return success3;
|
|
18806
|
+
}
|
|
18807
|
+
getTracerProvider() {
|
|
18808
|
+
return (0, global_utils_1.getGlobal)(API_NAME) || this._proxyTracerProvider;
|
|
18809
|
+
}
|
|
18810
|
+
getTracer(name, version2) {
|
|
18811
|
+
return this.getTracerProvider().getTracer(name, version2);
|
|
18812
|
+
}
|
|
18813
|
+
disable() {
|
|
18814
|
+
(0, global_utils_1.unregisterGlobal)(API_NAME, diag_1.DiagAPI.instance());
|
|
18815
|
+
this._proxyTracerProvider = new ProxyTracerProvider_1.ProxyTracerProvider;
|
|
18816
|
+
}
|
|
18817
|
+
}
|
|
18818
|
+
exports.TraceAPI = TraceAPI;
|
|
18819
|
+
});
|
|
18820
|
+
|
|
18821
|
+
// ../../node_modules/@opentelemetry/api/build/src/trace-api.js
|
|
18822
|
+
var require_trace_api = __commonJS((exports) => {
|
|
18823
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18824
|
+
exports.trace = undefined;
|
|
18825
|
+
var trace_1 = require_trace();
|
|
18826
|
+
exports.trace = trace_1.TraceAPI.getInstance();
|
|
18827
|
+
});
|
|
18828
|
+
|
|
18829
|
+
// ../../node_modules/@opentelemetry/api/build/src/index.js
|
|
18830
|
+
var require_src = __commonJS((exports) => {
|
|
18831
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18832
|
+
exports.trace = exports.propagation = exports.metrics = exports.diag = exports.context = exports.INVALID_SPAN_CONTEXT = exports.INVALID_TRACEID = exports.INVALID_SPANID = exports.isValidSpanId = exports.isValidTraceId = exports.isSpanContextValid = exports.createTraceState = exports.TraceFlags = exports.SpanStatusCode = exports.SpanKind = exports.SamplingDecision = exports.ProxyTracerProvider = exports.ProxyTracer = exports.defaultTextMapSetter = exports.defaultTextMapGetter = exports.ValueType = exports.createNoopMeter = exports.DiagLogLevel = exports.DiagConsoleLogger = exports.ROOT_CONTEXT = exports.createContextKey = exports.baggageEntryMetadataFromString = undefined;
|
|
18833
|
+
var utils_1 = require_utils();
|
|
18834
|
+
Object.defineProperty(exports, "baggageEntryMetadataFromString", { enumerable: true, get: function() {
|
|
18835
|
+
return utils_1.baggageEntryMetadataFromString;
|
|
18836
|
+
} });
|
|
18837
|
+
var context_1 = require_context();
|
|
18838
|
+
Object.defineProperty(exports, "createContextKey", { enumerable: true, get: function() {
|
|
18839
|
+
return context_1.createContextKey;
|
|
18840
|
+
} });
|
|
18841
|
+
Object.defineProperty(exports, "ROOT_CONTEXT", { enumerable: true, get: function() {
|
|
18842
|
+
return context_1.ROOT_CONTEXT;
|
|
18843
|
+
} });
|
|
18844
|
+
var consoleLogger_1 = require_consoleLogger();
|
|
18845
|
+
Object.defineProperty(exports, "DiagConsoleLogger", { enumerable: true, get: function() {
|
|
18846
|
+
return consoleLogger_1.DiagConsoleLogger;
|
|
18847
|
+
} });
|
|
18848
|
+
var types_1 = require_types();
|
|
18849
|
+
Object.defineProperty(exports, "DiagLogLevel", { enumerable: true, get: function() {
|
|
18850
|
+
return types_1.DiagLogLevel;
|
|
18851
|
+
} });
|
|
18852
|
+
var NoopMeter_1 = require_NoopMeter();
|
|
18853
|
+
Object.defineProperty(exports, "createNoopMeter", { enumerable: true, get: function() {
|
|
18854
|
+
return NoopMeter_1.createNoopMeter;
|
|
18855
|
+
} });
|
|
18856
|
+
var Metric_1 = require_Metric();
|
|
18857
|
+
Object.defineProperty(exports, "ValueType", { enumerable: true, get: function() {
|
|
18858
|
+
return Metric_1.ValueType;
|
|
18859
|
+
} });
|
|
18860
|
+
var TextMapPropagator_1 = require_TextMapPropagator();
|
|
18861
|
+
Object.defineProperty(exports, "defaultTextMapGetter", { enumerable: true, get: function() {
|
|
18862
|
+
return TextMapPropagator_1.defaultTextMapGetter;
|
|
18863
|
+
} });
|
|
18864
|
+
Object.defineProperty(exports, "defaultTextMapSetter", { enumerable: true, get: function() {
|
|
18865
|
+
return TextMapPropagator_1.defaultTextMapSetter;
|
|
18866
|
+
} });
|
|
18867
|
+
var ProxyTracer_1 = require_ProxyTracer();
|
|
18868
|
+
Object.defineProperty(exports, "ProxyTracer", { enumerable: true, get: function() {
|
|
18869
|
+
return ProxyTracer_1.ProxyTracer;
|
|
18870
|
+
} });
|
|
18871
|
+
var ProxyTracerProvider_1 = require_ProxyTracerProvider();
|
|
18872
|
+
Object.defineProperty(exports, "ProxyTracerProvider", { enumerable: true, get: function() {
|
|
18873
|
+
return ProxyTracerProvider_1.ProxyTracerProvider;
|
|
18874
|
+
} });
|
|
18875
|
+
var SamplingResult_1 = require_SamplingResult();
|
|
18876
|
+
Object.defineProperty(exports, "SamplingDecision", { enumerable: true, get: function() {
|
|
18877
|
+
return SamplingResult_1.SamplingDecision;
|
|
18878
|
+
} });
|
|
18879
|
+
var span_kind_1 = require_span_kind();
|
|
18880
|
+
Object.defineProperty(exports, "SpanKind", { enumerable: true, get: function() {
|
|
18881
|
+
return span_kind_1.SpanKind;
|
|
18882
|
+
} });
|
|
18883
|
+
var status_1 = require_status();
|
|
18884
|
+
Object.defineProperty(exports, "SpanStatusCode", { enumerable: true, get: function() {
|
|
18885
|
+
return status_1.SpanStatusCode;
|
|
18886
|
+
} });
|
|
18887
|
+
var trace_flags_1 = require_trace_flags();
|
|
18888
|
+
Object.defineProperty(exports, "TraceFlags", { enumerable: true, get: function() {
|
|
18889
|
+
return trace_flags_1.TraceFlags;
|
|
18890
|
+
} });
|
|
18891
|
+
var utils_2 = require_utils2();
|
|
18892
|
+
Object.defineProperty(exports, "createTraceState", { enumerable: true, get: function() {
|
|
18893
|
+
return utils_2.createTraceState;
|
|
18894
|
+
} });
|
|
18895
|
+
var spancontext_utils_1 = require_spancontext_utils();
|
|
18896
|
+
Object.defineProperty(exports, "isSpanContextValid", { enumerable: true, get: function() {
|
|
18897
|
+
return spancontext_utils_1.isSpanContextValid;
|
|
18898
|
+
} });
|
|
18899
|
+
Object.defineProperty(exports, "isValidTraceId", { enumerable: true, get: function() {
|
|
18900
|
+
return spancontext_utils_1.isValidTraceId;
|
|
18901
|
+
} });
|
|
18902
|
+
Object.defineProperty(exports, "isValidSpanId", { enumerable: true, get: function() {
|
|
18903
|
+
return spancontext_utils_1.isValidSpanId;
|
|
18904
|
+
} });
|
|
18905
|
+
var invalid_span_constants_1 = require_invalid_span_constants();
|
|
18906
|
+
Object.defineProperty(exports, "INVALID_SPANID", { enumerable: true, get: function() {
|
|
18907
|
+
return invalid_span_constants_1.INVALID_SPANID;
|
|
18908
|
+
} });
|
|
18909
|
+
Object.defineProperty(exports, "INVALID_TRACEID", { enumerable: true, get: function() {
|
|
18910
|
+
return invalid_span_constants_1.INVALID_TRACEID;
|
|
18911
|
+
} });
|
|
18912
|
+
Object.defineProperty(exports, "INVALID_SPAN_CONTEXT", { enumerable: true, get: function() {
|
|
18913
|
+
return invalid_span_constants_1.INVALID_SPAN_CONTEXT;
|
|
18914
|
+
} });
|
|
18915
|
+
var context_api_1 = require_context_api();
|
|
18916
|
+
Object.defineProperty(exports, "context", { enumerable: true, get: function() {
|
|
18917
|
+
return context_api_1.context;
|
|
18918
|
+
} });
|
|
18919
|
+
var diag_api_1 = require_diag_api();
|
|
18920
|
+
Object.defineProperty(exports, "diag", { enumerable: true, get: function() {
|
|
18921
|
+
return diag_api_1.diag;
|
|
18922
|
+
} });
|
|
18923
|
+
var metrics_api_1 = require_metrics_api();
|
|
18924
|
+
Object.defineProperty(exports, "metrics", { enumerable: true, get: function() {
|
|
18925
|
+
return metrics_api_1.metrics;
|
|
18926
|
+
} });
|
|
18927
|
+
var propagation_api_1 = require_propagation_api();
|
|
18928
|
+
Object.defineProperty(exports, "propagation", { enumerable: true, get: function() {
|
|
18929
|
+
return propagation_api_1.propagation;
|
|
18930
|
+
} });
|
|
18931
|
+
var trace_api_1 = require_trace_api();
|
|
18932
|
+
Object.defineProperty(exports, "trace", { enumerable: true, get: function() {
|
|
18933
|
+
return trace_api_1.trace;
|
|
18934
|
+
} });
|
|
18935
|
+
exports.default = {
|
|
18936
|
+
context: context_api_1.context,
|
|
18937
|
+
diag: diag_api_1.diag,
|
|
18938
|
+
metrics: metrics_api_1.metrics,
|
|
18939
|
+
propagation: propagation_api_1.propagation,
|
|
18940
|
+
trace: trace_api_1.trace
|
|
18941
|
+
};
|
|
18942
|
+
});
|
|
18943
|
+
|
|
18944
|
+
// ../types/src/processor/processor.ts
|
|
18945
|
+
var import_api, noopTracingContext, ProcessorPortSchema, ProcessorDefinitionSchema, ProcessorExecutionContextSchema, TraceStatus;
|
|
18946
|
+
var init_processor = __esm(() => {
|
|
18947
|
+
init_zod();
|
|
18948
|
+
init_common();
|
|
18949
|
+
import_api = __toESM(require_src(), 1);
|
|
18950
|
+
noopTracingContext = {
|
|
18951
|
+
traceId: "",
|
|
18952
|
+
getActiveSpan() {
|
|
18953
|
+
return;
|
|
18954
|
+
},
|
|
18955
|
+
async withSpan(_name, _options, fn) {
|
|
18956
|
+
const noopSpan = {
|
|
18957
|
+
spanContext: () => ({
|
|
18958
|
+
traceId: "",
|
|
18959
|
+
spanId: "",
|
|
18960
|
+
traceFlags: 0
|
|
18961
|
+
}),
|
|
18962
|
+
setAttribute: () => noopSpan,
|
|
18963
|
+
setAttributes: () => noopSpan,
|
|
18964
|
+
addEvent: () => noopSpan,
|
|
18965
|
+
addLink: () => noopSpan,
|
|
18966
|
+
addLinks: () => noopSpan,
|
|
18967
|
+
setStatus: () => noopSpan,
|
|
18968
|
+
updateName: () => noopSpan,
|
|
18969
|
+
end: () => {},
|
|
18970
|
+
isRecording: () => false,
|
|
18971
|
+
recordException: () => {}
|
|
18972
|
+
};
|
|
18973
|
+
return fn(noopSpan);
|
|
18974
|
+
}
|
|
18975
|
+
};
|
|
18976
|
+
ProcessorPortSchema = exports_external.object({
|
|
18977
|
+
name: exports_external.string(),
|
|
18978
|
+
schema: JsonSchemaSchema,
|
|
18979
|
+
required: exports_external.boolean().default(true)
|
|
18980
|
+
});
|
|
18981
|
+
ProcessorDefinitionSchema = exports_external.object({
|
|
18982
|
+
id: exports_external.string(),
|
|
18983
|
+
name: exports_external.string(),
|
|
18984
|
+
description: exports_external.string().optional(),
|
|
18985
|
+
inputSchema: JsonSchemaSchema,
|
|
18986
|
+
outputSchema: JsonSchemaSchema,
|
|
18987
|
+
configSchema: JsonSchemaSchema.optional(),
|
|
18988
|
+
inputPorts: exports_external.array(ProcessorPortSchema).optional(),
|
|
18989
|
+
outputPorts: exports_external.array(ProcessorPortSchema).optional(),
|
|
18990
|
+
isBuiltin: exports_external.boolean().default(true),
|
|
18991
|
+
pluginName: exports_external.string().optional()
|
|
18992
|
+
});
|
|
18993
|
+
ProcessorExecutionContextSchema = exports_external.object({
|
|
18994
|
+
jobId: exports_external.string(),
|
|
18995
|
+
stepId: exports_external.string(),
|
|
18996
|
+
tenantId: exports_external.string(),
|
|
18997
|
+
automationId: exports_external.string().optional(),
|
|
18998
|
+
workflowId: exports_external.string(),
|
|
18999
|
+
workerId: exports_external.string().optional()
|
|
19000
|
+
});
|
|
19001
|
+
((TraceStatus2) => {
|
|
19002
|
+
TraceStatus2["PENDING"] = "pending";
|
|
19003
|
+
TraceStatus2["RUNNING"] = "running";
|
|
19004
|
+
TraceStatus2["COMPLETED"] = "completed";
|
|
19005
|
+
TraceStatus2["FAILED"] = "failed";
|
|
19006
|
+
})(TraceStatus ||= {});
|
|
19007
|
+
});
|
|
19008
|
+
|
|
19009
|
+
// ../types/src/processor/execution.ts
|
|
19010
|
+
function asTuple(values) {
|
|
19011
|
+
return values;
|
|
19012
|
+
}
|
|
19013
|
+
var WorkflowExecutionStatusValue, WorkflowExecutionStatusSchema, StepExecutionStatusValue, StepExecutionStatusSchema, TriggerTypeValue, TriggerTypeSchema, ExecutionTypeValue, ExecutionTypeSchema, WORKFLOW_EXECUTION_STATUSES, STEP_EXECUTION_STATUSES, TRIGGER_TYPES, EXECUTION_TYPES;
|
|
19014
|
+
var init_execution = __esm(() => {
|
|
19015
|
+
init_zod();
|
|
19016
|
+
WorkflowExecutionStatusValue = {
|
|
19017
|
+
CREATED: "created",
|
|
19018
|
+
PENDING: "pending",
|
|
19019
|
+
RUNNING: "running",
|
|
19020
|
+
WAITING: "waiting",
|
|
19021
|
+
COMPLETED: "completed",
|
|
19022
|
+
FAILED: "failed",
|
|
19023
|
+
CANCELLED: "cancelled"
|
|
19024
|
+
};
|
|
19025
|
+
WorkflowExecutionStatusSchema = exports_external.enum([
|
|
19026
|
+
WorkflowExecutionStatusValue.CREATED,
|
|
19027
|
+
WorkflowExecutionStatusValue.PENDING,
|
|
19028
|
+
WorkflowExecutionStatusValue.RUNNING,
|
|
19029
|
+
WorkflowExecutionStatusValue.WAITING,
|
|
19030
|
+
WorkflowExecutionStatusValue.COMPLETED,
|
|
19031
|
+
WorkflowExecutionStatusValue.FAILED,
|
|
19032
|
+
WorkflowExecutionStatusValue.CANCELLED
|
|
19033
|
+
]);
|
|
19034
|
+
StepExecutionStatusValue = {
|
|
19035
|
+
PENDING: "pending",
|
|
19036
|
+
RUNNING: "running",
|
|
19037
|
+
SUCCESS: "success",
|
|
19038
|
+
FAILURE: "failure",
|
|
19039
|
+
WAITING: "waiting",
|
|
19040
|
+
SKIPPED: "skipped"
|
|
19041
|
+
};
|
|
19042
|
+
StepExecutionStatusSchema = exports_external.enum([
|
|
19043
|
+
StepExecutionStatusValue.PENDING,
|
|
19044
|
+
StepExecutionStatusValue.RUNNING,
|
|
19045
|
+
StepExecutionStatusValue.SUCCESS,
|
|
19046
|
+
StepExecutionStatusValue.FAILURE,
|
|
19047
|
+
StepExecutionStatusValue.WAITING,
|
|
19048
|
+
StepExecutionStatusValue.SKIPPED
|
|
19049
|
+
]);
|
|
19050
|
+
TriggerTypeValue = {
|
|
19051
|
+
MANUAL: "manual",
|
|
19052
|
+
API: "api",
|
|
19053
|
+
WEBHOOK: "webhook",
|
|
19054
|
+
SCHEDULE: "schedule",
|
|
19055
|
+
EMAIL: "email",
|
|
19056
|
+
EVAL: "eval",
|
|
19057
|
+
CLI: "cli"
|
|
19058
|
+
};
|
|
19059
|
+
TriggerTypeSchema = exports_external.enum([
|
|
19060
|
+
TriggerTypeValue.MANUAL,
|
|
19061
|
+
TriggerTypeValue.API,
|
|
19062
|
+
TriggerTypeValue.WEBHOOK,
|
|
19063
|
+
TriggerTypeValue.SCHEDULE,
|
|
19064
|
+
TriggerTypeValue.EMAIL,
|
|
19065
|
+
TriggerTypeValue.EVAL,
|
|
19066
|
+
TriggerTypeValue.CLI
|
|
19067
|
+
]);
|
|
19068
|
+
ExecutionTypeValue = {
|
|
19069
|
+
PROD: "prod",
|
|
19070
|
+
EVAL: "eval",
|
|
19071
|
+
PLAYGROUND: "playground"
|
|
19072
|
+
};
|
|
19073
|
+
ExecutionTypeSchema = exports_external.enum([
|
|
19074
|
+
ExecutionTypeValue.PROD,
|
|
19075
|
+
ExecutionTypeValue.EVAL,
|
|
19076
|
+
ExecutionTypeValue.PLAYGROUND
|
|
19077
|
+
]);
|
|
19078
|
+
WORKFLOW_EXECUTION_STATUSES = asTuple(WorkflowExecutionStatusSchema.options);
|
|
19079
|
+
STEP_EXECUTION_STATUSES = asTuple(StepExecutionStatusSchema.options);
|
|
19080
|
+
TRIGGER_TYPES = TriggerTypeSchema.options;
|
|
19081
|
+
EXECUTION_TYPES = ExecutionTypeSchema.options;
|
|
19082
|
+
});
|
|
19083
|
+
|
|
19084
|
+
// ../types/src/processor/configs/classify.ts
|
|
19085
|
+
var ClassifyInputSchema, ClassifyLabelSchema, ClassifyConfigSchema, ClassifyOutputSchema;
|
|
19086
|
+
var init_classify = __esm(() => {
|
|
19087
|
+
init_zod();
|
|
19088
|
+
ClassifyInputSchema = exports_external.object({
|
|
19089
|
+
content: exports_external.string().optional().describe("Text content to classify"),
|
|
19090
|
+
text: exports_external.string().optional().describe("Text content (alternative to content)")
|
|
19091
|
+
}).refine((data) => !!(data.content || data.text), {
|
|
19092
|
+
message: "Either content or text must be provided"
|
|
19093
|
+
});
|
|
19094
|
+
ClassifyLabelSchema = exports_external.object({
|
|
19095
|
+
name: exports_external.string().min(1).describe("Label value returned in output.label"),
|
|
19096
|
+
description: exports_external.string().optional().describe("What documents fall into this label. Fed to the LLM as guidance.")
|
|
19097
|
+
});
|
|
19098
|
+
ClassifyConfigSchema = exports_external.object({
|
|
19099
|
+
labels: exports_external.array(ClassifyLabelSchema).min(2).describe("Allowed labels. The LLM is constrained to pick exactly one of these names."),
|
|
19100
|
+
prompt: exports_external.string().optional().describe("Optional classification instructions appended to the system prompt. Use to clarify edge cases or emphasize evidence the model should weigh."),
|
|
19101
|
+
provider: exports_external.string().optional().describe('Provider ID (e.g., "openai-gpt4o-mini")'),
|
|
19102
|
+
model: exports_external.string().optional().describe("Model override"),
|
|
19103
|
+
maxInputTokens: exports_external.number().int().optional().describe("Max input tokens. Truncates input text when exceeded. Omit for no limit.")
|
|
19104
|
+
});
|
|
19105
|
+
ClassifyOutputSchema = exports_external.object({
|
|
19106
|
+
label: exports_external.string().describe("The selected label name"),
|
|
19107
|
+
confidence: exports_external.enum(["low", "medium", "high"]).describe("Coarse confidence in the classification"),
|
|
19108
|
+
reason: exports_external.string().describe("Short justification for the chosen label")
|
|
19109
|
+
});
|
|
19110
|
+
});
|
|
19111
|
+
|
|
19112
|
+
// ../types/src/parser/parser.ts
|
|
19113
|
+
function resolveEffectiveMimeType(filename, declaredMimeType) {
|
|
19114
|
+
const ext = filename.split(".").pop()?.toLowerCase();
|
|
19115
|
+
if (!ext)
|
|
19116
|
+
return declaredMimeType;
|
|
19117
|
+
const extensionMime = EXTENSION_TO_MIME[ext];
|
|
19118
|
+
return extensionMime ?? declaredMimeType;
|
|
19119
|
+
}
|
|
19120
|
+
function mimeTypeForExtension(extension) {
|
|
19121
|
+
return EXTENSION_TO_MIME[extension.replace(/^\./, "").toLowerCase()];
|
|
19122
|
+
}
|
|
19123
|
+
function extensionForMimeType(mimeType) {
|
|
19124
|
+
const base = mimeType.split(";")[0]?.trim().toLowerCase();
|
|
19125
|
+
return base ? MIME_TO_EXTENSION[base] : undefined;
|
|
19126
|
+
}
|
|
19127
|
+
function getParserCategory(mimeType) {
|
|
19128
|
+
const normalized = mimeType.toLowerCase().trim();
|
|
19129
|
+
if (ParserCategory.PLAINTEXT.includes(normalized)) {
|
|
19130
|
+
return "plaintext";
|
|
19131
|
+
}
|
|
19132
|
+
if (ParserCategory.OFFICE.includes(normalized)) {
|
|
19133
|
+
return "office";
|
|
19134
|
+
}
|
|
19135
|
+
if (ParserCategory.DOCUMENT.includes(normalized)) {
|
|
19136
|
+
return "document";
|
|
19137
|
+
}
|
|
19138
|
+
return null;
|
|
19139
|
+
}
|
|
19140
|
+
function requiresSpecializedParser(mimeType) {
|
|
19141
|
+
return getParserCategory(mimeType) === "document";
|
|
19142
|
+
}
|
|
19143
|
+
function getAllSupportedMimeTypes() {
|
|
19144
|
+
return [...ParserCategory.PLAINTEXT, ...ParserCategory.OFFICE, ...ParserCategory.DOCUMENT];
|
|
19145
|
+
}
|
|
19146
|
+
function getSupportedFormatsLabel() {
|
|
19147
|
+
const allMimes = getAllSupportedMimeTypes();
|
|
19148
|
+
const labels = [...new Set(allMimes.map((m) => MIME_TO_LABEL[m] ?? m))];
|
|
19149
|
+
return labels.join(", ");
|
|
19150
|
+
}
|
|
19151
|
+
var OFFICE_MIME_TYPES, ParserCategory, ParserTypeSchema, DocumentMetadataSchema, ParseUsageSchema, CoordinateUnitSchema, PointSchema, BoundingRegionSchema, PositionedTextSchema, TableCellSchema, ExtractedTableSchema, LayoutElementTypeSchema, LayoutElementSchema, PageResultSchema, ParseResultSchema, ParseOptionsSchema, ParserInputSchema, EXTENSION_TO_MIME, MIME_TO_EXTENSION, MIME_TO_LABEL;
|
|
19152
|
+
var init_parser = __esm(() => {
|
|
19153
|
+
init_zod();
|
|
19154
|
+
OFFICE_MIME_TYPES = [
|
|
19155
|
+
"application/vnd.openxmlformats-officedocument.wordprocessingml.document",
|
|
19156
|
+
"application/msword",
|
|
19157
|
+
"application/vnd.oasis.opendocument.text",
|
|
19158
|
+
"application/rtf",
|
|
19159
|
+
"text/rtf",
|
|
19160
|
+
"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
|
19161
|
+
"application/vnd.ms-excel",
|
|
19162
|
+
"application/vnd.ms-excel.sheet.macroenabled.12",
|
|
19163
|
+
"application/vnd.ms-excel.sheet.binary.macroenabled.12",
|
|
19164
|
+
"application/vnd.oasis.opendocument.spreadsheet",
|
|
19165
|
+
"application/vnd.openxmlformats-officedocument.presentationml.presentation",
|
|
19166
|
+
"application/vnd.openxmlformats-officedocument.presentationml.slideshow",
|
|
19167
|
+
"application/vnd.ms-powerpoint.presentation.macroenabled.12",
|
|
19168
|
+
"application/vnd.ms-powerpoint",
|
|
19169
|
+
"application/vnd.oasis.opendocument.presentation",
|
|
19170
|
+
"message/rfc822",
|
|
19171
|
+
"application/vnd.ms-outlook",
|
|
19172
|
+
"application/epub+zip"
|
|
19173
|
+
];
|
|
19174
|
+
ParserCategory = {
|
|
19175
|
+
PLAINTEXT: [
|
|
19176
|
+
"text/plain",
|
|
19177
|
+
"text/markdown",
|
|
19178
|
+
"text/csv",
|
|
19179
|
+
"text/tab-separated-values",
|
|
19180
|
+
"text/html",
|
|
19181
|
+
"text/xml",
|
|
19182
|
+
"application/json",
|
|
19183
|
+
"application/x-yaml",
|
|
19184
|
+
"application/toml",
|
|
19185
|
+
"image/svg+xml",
|
|
19186
|
+
"text/x-rst",
|
|
19187
|
+
"text/x-org",
|
|
19188
|
+
"application/x-latex",
|
|
19189
|
+
"application/x-ipynb+json",
|
|
19190
|
+
"application/x-bibtex",
|
|
19191
|
+
"application/docbook+xml",
|
|
19192
|
+
"application/x-fictionbook+xml"
|
|
19193
|
+
],
|
|
19194
|
+
OFFICE: [...OFFICE_MIME_TYPES],
|
|
19195
|
+
DOCUMENT: [
|
|
19196
|
+
"application/pdf",
|
|
19197
|
+
"image/png",
|
|
19198
|
+
"image/jpeg",
|
|
19199
|
+
"image/webp",
|
|
19200
|
+
"image/tiff",
|
|
19201
|
+
"image/gif",
|
|
19202
|
+
"image/bmp"
|
|
19203
|
+
]
|
|
19204
|
+
};
|
|
19205
|
+
ParserTypeSchema = exports_external.enum([
|
|
19206
|
+
"plaintext",
|
|
19207
|
+
"office",
|
|
19208
|
+
"llm-vision",
|
|
19209
|
+
"ocr"
|
|
19210
|
+
]);
|
|
19211
|
+
DocumentMetadataSchema = exports_external.object({
|
|
19212
|
+
filename: exports_external.string(),
|
|
19213
|
+
mimeType: exports_external.string(),
|
|
19214
|
+
size: exports_external.number().describe("File size in bytes"),
|
|
19215
|
+
storageRef: exports_external.string().optional().describe("Storage reference for the original file")
|
|
19216
|
+
});
|
|
19217
|
+
ParseUsageSchema = exports_external.object({
|
|
19218
|
+
pageCount: exports_external.number(),
|
|
19219
|
+
processingTimeMs: exports_external.number().optional()
|
|
19220
|
+
});
|
|
19221
|
+
CoordinateUnitSchema = exports_external.enum(["pixel", "inch", "point", "normalized"]);
|
|
19222
|
+
PointSchema = exports_external.object({
|
|
19223
|
+
x: exports_external.number(),
|
|
19224
|
+
y: exports_external.number()
|
|
19225
|
+
});
|
|
19226
|
+
BoundingRegionSchema = exports_external.object({
|
|
19227
|
+
polygon: exports_external.array(PointSchema).min(3),
|
|
19228
|
+
unit: CoordinateUnitSchema,
|
|
19229
|
+
pageIndex: exports_external.number()
|
|
19230
|
+
});
|
|
19231
|
+
PositionedTextSchema = exports_external.object({
|
|
19232
|
+
text: exports_external.string(),
|
|
19233
|
+
confidence: exports_external.number().min(0).max(1).optional(),
|
|
19234
|
+
boundingRegion: BoundingRegionSchema.optional()
|
|
19235
|
+
});
|
|
19236
|
+
TableCellSchema = exports_external.object({
|
|
19237
|
+
content: exports_external.string(),
|
|
19238
|
+
rowIndex: exports_external.number(),
|
|
19239
|
+
columnIndex: exports_external.number(),
|
|
19240
|
+
rowSpan: exports_external.number().default(1),
|
|
19241
|
+
columnSpan: exports_external.number().default(1),
|
|
19242
|
+
boundingRegion: BoundingRegionSchema.optional()
|
|
19243
|
+
});
|
|
19244
|
+
ExtractedTableSchema = exports_external.object({
|
|
19245
|
+
cells: exports_external.array(TableCellSchema),
|
|
19246
|
+
rowCount: exports_external.number(),
|
|
19247
|
+
columnCount: exports_external.number(),
|
|
19248
|
+
boundingRegion: BoundingRegionSchema.optional()
|
|
19249
|
+
});
|
|
19250
|
+
LayoutElementTypeSchema = exports_external.enum([
|
|
19251
|
+
"paragraph",
|
|
19252
|
+
"title",
|
|
19253
|
+
"sectionHeading",
|
|
19254
|
+
"pageHeader",
|
|
19255
|
+
"pageFooter",
|
|
19256
|
+
"pageNumber",
|
|
19257
|
+
"footnote",
|
|
19258
|
+
"table",
|
|
19259
|
+
"figure",
|
|
19260
|
+
"formulaBlock"
|
|
19261
|
+
]);
|
|
19262
|
+
LayoutElementSchema = exports_external.object({
|
|
19263
|
+
type: LayoutElementTypeSchema,
|
|
19264
|
+
content: exports_external.string(),
|
|
19265
|
+
table: ExtractedTableSchema.optional(),
|
|
19266
|
+
caption: exports_external.string().optional(),
|
|
19267
|
+
figureId: exports_external.string().optional(),
|
|
19268
|
+
boundingRegion: BoundingRegionSchema.optional()
|
|
19269
|
+
});
|
|
19270
|
+
PageResultSchema = exports_external.object({
|
|
19271
|
+
pageIndex: exports_external.number().describe("0-based page index"),
|
|
19272
|
+
text: exports_external.string().describe("Extracted text content (markdown/HTML)"),
|
|
19273
|
+
pageName: exports_external.string().optional().describe("Page/sheet name (e.g., Excel sheet name)"),
|
|
19274
|
+
layoutElements: exports_external.array(LayoutElementSchema).optional().describe("Semantic layout elements in reading order"),
|
|
19275
|
+
words: exports_external.array(PositionedTextSchema).optional().describe("Word-level positions"),
|
|
19276
|
+
lines: exports_external.array(PositionedTextSchema).optional().describe("Line-level positions"),
|
|
19277
|
+
tables: exports_external.array(ExtractedTableSchema).optional().describe("Extracted tables"),
|
|
19278
|
+
width: exports_external.number().optional().describe("Page width"),
|
|
19279
|
+
height: exports_external.number().optional().describe("Page height"),
|
|
19280
|
+
unit: CoordinateUnitSchema.optional().describe("Unit for width/height and bounding regions"),
|
|
19281
|
+
confidence: exports_external.number().min(0).max(1).optional().describe("Overall page confidence")
|
|
19282
|
+
});
|
|
19283
|
+
ParseResultSchema = exports_external.object({
|
|
19284
|
+
document: DocumentMetadataSchema,
|
|
19285
|
+
usage: ParseUsageSchema,
|
|
19286
|
+
pages: exports_external.array(PageResultSchema),
|
|
19287
|
+
text: exports_external.string().describe("Combined text from all pages"),
|
|
19288
|
+
parserType: ParserTypeSchema,
|
|
19289
|
+
parserVersion: exports_external.string().optional(),
|
|
19290
|
+
model: exports_external.string().optional().describe("Model used (for LLM/OCR parsers)"),
|
|
19291
|
+
rawResponse: exports_external.unknown().optional()
|
|
19292
|
+
});
|
|
19293
|
+
ParseOptionsSchema = exports_external.object({
|
|
19294
|
+
outputFormat: exports_external.enum(["plain", "markdown", "djot", "html"]).default("markdown"),
|
|
19295
|
+
ocrProvider: exports_external.string().optional().describe("OCR provider ID to use"),
|
|
19296
|
+
includeWordPositions: exports_external.boolean().default(false),
|
|
19297
|
+
includeLinePositions: exports_external.boolean().default(false),
|
|
19298
|
+
extractTables: exports_external.boolean().default(true),
|
|
19299
|
+
provider: exports_external.string().optional().describe("LLM provider ID to use"),
|
|
19300
|
+
model: exports_external.string().optional(),
|
|
19301
|
+
maxConcurrency: exports_external.number().min(1).max(30).default(3),
|
|
19302
|
+
pagesPerBatch: exports_external.number().min(1).max(20).default(5),
|
|
19303
|
+
prompt: exports_external.string().optional().describe("Custom prompt for LLM-based parsing"),
|
|
19304
|
+
languages: exports_external.array(exports_external.string()).optional().describe("OCR language hints"),
|
|
19305
|
+
tenantId: exports_external.string().optional()
|
|
19306
|
+
});
|
|
19307
|
+
ParserInputSchema = exports_external.object({
|
|
19308
|
+
data: exports_external.instanceof(Buffer).or(exports_external.instanceof(Uint8Array)),
|
|
19309
|
+
filename: exports_external.string(),
|
|
19310
|
+
mimeType: exports_external.string(),
|
|
19311
|
+
options: ParseOptionsSchema.optional()
|
|
19312
|
+
});
|
|
19313
|
+
EXTENSION_TO_MIME = {
|
|
19314
|
+
docx: "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
|
|
19315
|
+
doc: "application/msword",
|
|
19316
|
+
odt: "application/vnd.oasis.opendocument.text",
|
|
19317
|
+
rtf: "application/rtf",
|
|
19318
|
+
xlsx: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
|
19319
|
+
xls: "application/vnd.ms-excel",
|
|
19320
|
+
xlsm: "application/vnd.ms-excel.sheet.macroenabled.12",
|
|
19321
|
+
xlsb: "application/vnd.ms-excel.sheet.binary.macroenabled.12",
|
|
19322
|
+
ods: "application/vnd.oasis.opendocument.spreadsheet",
|
|
19323
|
+
pptx: "application/vnd.openxmlformats-officedocument.presentationml.presentation",
|
|
19324
|
+
ppsx: "application/vnd.openxmlformats-officedocument.presentationml.slideshow",
|
|
19325
|
+
pptm: "application/vnd.ms-powerpoint.presentation.macroenabled.12",
|
|
19326
|
+
ppt: "application/vnd.ms-powerpoint",
|
|
19327
|
+
odp: "application/vnd.oasis.opendocument.presentation",
|
|
19328
|
+
eml: "message/rfc822",
|
|
19329
|
+
msg: "application/vnd.ms-outlook",
|
|
19330
|
+
epub: "application/epub+zip",
|
|
19331
|
+
pdf: "application/pdf",
|
|
19332
|
+
png: "image/png",
|
|
19333
|
+
jpg: "image/jpeg",
|
|
19334
|
+
jpeg: "image/jpeg",
|
|
19335
|
+
webp: "image/webp",
|
|
19336
|
+
tiff: "image/tiff",
|
|
19337
|
+
tif: "image/tiff",
|
|
19338
|
+
gif: "image/gif",
|
|
19339
|
+
bmp: "image/bmp",
|
|
19340
|
+
svg: "image/svg+xml",
|
|
19341
|
+
txt: "text/plain",
|
|
19342
|
+
md: "text/markdown",
|
|
19343
|
+
markdown: "text/markdown",
|
|
19344
|
+
csv: "text/csv",
|
|
19345
|
+
tsv: "text/tab-separated-values",
|
|
19346
|
+
html: "text/html",
|
|
19347
|
+
htm: "text/html",
|
|
19348
|
+
xml: "text/xml",
|
|
19349
|
+
json: "application/json",
|
|
19350
|
+
yaml: "application/x-yaml",
|
|
19351
|
+
yml: "application/x-yaml",
|
|
19352
|
+
toml: "application/toml",
|
|
19353
|
+
rst: "text/x-rst",
|
|
19354
|
+
org: "text/x-org",
|
|
19355
|
+
tex: "application/x-latex",
|
|
19356
|
+
latex: "application/x-latex",
|
|
19357
|
+
ipynb: "application/x-ipynb+json",
|
|
19358
|
+
bib: "application/x-bibtex",
|
|
19359
|
+
dbk: "application/docbook+xml",
|
|
19360
|
+
docbook: "application/docbook+xml",
|
|
19361
|
+
fb2: "application/x-fictionbook+xml"
|
|
19362
|
+
};
|
|
19363
|
+
MIME_TO_EXTENSION = Object.entries(EXTENSION_TO_MIME).reduce((acc, [ext, mime]) => {
|
|
19364
|
+
if (!(mime in acc))
|
|
19365
|
+
acc[mime] = ext;
|
|
19366
|
+
return acc;
|
|
19367
|
+
}, {});
|
|
19368
|
+
MIME_TO_LABEL = {
|
|
19369
|
+
"application/vnd.openxmlformats-officedocument.wordprocessingml.document": "DOCX",
|
|
19370
|
+
"application/msword": "DOC",
|
|
19371
|
+
"application/vnd.oasis.opendocument.text": "ODT",
|
|
19372
|
+
"application/rtf": "RTF",
|
|
19373
|
+
"text/rtf": "RTF",
|
|
19374
|
+
"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": "XLSX",
|
|
19375
|
+
"application/vnd.ms-excel": "XLS",
|
|
19376
|
+
"application/vnd.ms-excel.sheet.macroenabled.12": "XLSM",
|
|
19377
|
+
"application/vnd.ms-excel.sheet.binary.macroenabled.12": "XLSB",
|
|
19378
|
+
"application/vnd.oasis.opendocument.spreadsheet": "ODS",
|
|
19379
|
+
"application/vnd.openxmlformats-officedocument.presentationml.presentation": "PPTX",
|
|
19380
|
+
"application/vnd.openxmlformats-officedocument.presentationml.slideshow": "PPSX",
|
|
19381
|
+
"application/vnd.ms-powerpoint.presentation.macroenabled.12": "PPTM",
|
|
19382
|
+
"application/vnd.ms-powerpoint": "PPT",
|
|
19383
|
+
"application/vnd.oasis.opendocument.presentation": "ODP",
|
|
19384
|
+
"message/rfc822": "EML",
|
|
19385
|
+
"application/vnd.ms-outlook": "MSG",
|
|
19386
|
+
"application/epub+zip": "EPUB",
|
|
19387
|
+
"application/pdf": "PDF",
|
|
19388
|
+
"image/png": "PNG",
|
|
19389
|
+
"image/jpeg": "JPEG",
|
|
19390
|
+
"image/webp": "WebP",
|
|
19391
|
+
"image/tiff": "TIFF",
|
|
19392
|
+
"image/gif": "GIF",
|
|
19393
|
+
"image/bmp": "BMP",
|
|
19394
|
+
"image/svg+xml": "SVG",
|
|
19395
|
+
"text/plain": "TXT",
|
|
19396
|
+
"text/markdown": "Markdown",
|
|
19397
|
+
"text/csv": "CSV",
|
|
19398
|
+
"text/tab-separated-values": "TSV",
|
|
19399
|
+
"text/html": "HTML",
|
|
19400
|
+
"text/xml": "XML",
|
|
19401
|
+
"application/json": "JSON",
|
|
19402
|
+
"application/x-yaml": "YAML",
|
|
19403
|
+
"application/toml": "TOML",
|
|
19404
|
+
"text/x-rst": "RST",
|
|
19405
|
+
"text/x-org": "Org",
|
|
19406
|
+
"application/x-latex": "LaTeX",
|
|
19407
|
+
"application/x-ipynb+json": "Jupyter",
|
|
19408
|
+
"application/x-bibtex": "BibTeX",
|
|
19409
|
+
"application/docbook+xml": "DocBook",
|
|
19410
|
+
"application/x-fictionbook+xml": "FB2"
|
|
19411
|
+
};
|
|
19412
|
+
});
|
|
19413
|
+
|
|
19414
|
+
// ../types/src/processor/configs/document-parser.ts
|
|
19415
|
+
var DocumentParserInputSchema, DocumentParserOutputSchema, DocumentParserConfigSchema;
|
|
19416
|
+
var init_document_parser = __esm(() => {
|
|
19417
|
+
init_zod();
|
|
19418
|
+
init_runtime_file_ref();
|
|
19419
|
+
init_parser();
|
|
19420
|
+
DocumentParserInputSchema = ResolvedProcessorFileSchema;
|
|
19421
|
+
DocumentParserOutputSchema = ParseResultSchema;
|
|
19422
|
+
DocumentParserConfigSchema = exports_external.object({
|
|
19423
|
+
ocrModel: exports_external.string().optional().describe("OCR provider ID for PDF/image parsing"),
|
|
19424
|
+
llmModel: exports_external.string().optional().describe("LLM provider ID for vision-based parsing"),
|
|
19425
|
+
maxConcurrency: exports_external.number().min(1).max(10).default(3).describe("Max concurrent VLM batch requests"),
|
|
19426
|
+
pagesPerBatch: exports_external.number().min(1).max(20).default(5).describe("Number of page images per VLM request"),
|
|
19427
|
+
prompt: exports_external.string().optional().describe("Custom extraction prompt"),
|
|
19428
|
+
nativeText: exports_external.boolean().default(false).optional().describe("Use native text extraction for PDFs with embedded text (no OCR/VLM)"),
|
|
19429
|
+
languages: exports_external.array(exports_external.string()).optional().describe('OCR language hints (e.g., ["en", "de"])'),
|
|
19430
|
+
outputFormat: exports_external.enum(["plain", "markdown", "djot", "html"]).default("markdown").optional().describe("Format for extracted text. Only the native (Kreuzberg) parser uses this — OCR/VLM always emit markdown.")
|
|
19431
|
+
}).prefault({});
|
|
19432
|
+
});
|
|
19433
|
+
|
|
19434
|
+
// ../types/src/processor/configs/extract.ts
|
|
19435
|
+
var ExtractInputSchema, ExtractOutputSchema, ExtractConfigSchema;
|
|
19436
|
+
var init_extract = __esm(() => {
|
|
19437
|
+
init_zod();
|
|
19438
|
+
ExtractInputSchema = exports_external.object({
|
|
19439
|
+
content: exports_external.string().optional().describe("Text content to extract from"),
|
|
19440
|
+
text: exports_external.string().optional().describe("Text content (alternative to content, e.g., from document parser)"),
|
|
19441
|
+
contentType: exports_external.enum(["text", "image"]).default("text"),
|
|
19442
|
+
imageData: exports_external.string().optional(),
|
|
19443
|
+
imageMimeType: exports_external.string().optional()
|
|
19444
|
+
}).refine((data) => data.content || data.text, {
|
|
19445
|
+
message: "Either content or text must be provided"
|
|
19446
|
+
});
|
|
19447
|
+
ExtractOutputSchema = exports_external.record(exports_external.string(), exports_external.unknown()).describe("Extracted structured data matching the provided schema");
|
|
19448
|
+
ExtractConfigSchema = exports_external.object({
|
|
19449
|
+
schema: exports_external.record(exports_external.string(), exports_external.unknown()).describe("JSON Schema defining the structure to extract"),
|
|
19450
|
+
prompt: exports_external.string().optional().describe("Custom prompt template for extraction"),
|
|
19451
|
+
provider: exports_external.string().optional().describe('Provider ID to use (e.g., "openai-gpt4o", "anthropic-claude")'),
|
|
19452
|
+
model: exports_external.string().optional().describe("Model to use (overrides provider default)"),
|
|
19453
|
+
maxInputTokens: exports_external.number().int().optional().describe("Max input tokens. Truncates input text and logs a warning when exceeded. Omit for no limit.")
|
|
19454
|
+
});
|
|
19455
|
+
});
|
|
19456
|
+
|
|
19457
|
+
// ../types/src/processor/configs/merge.ts
|
|
19458
|
+
var MergeConfigSchema, MergeInputSchema, MergeOutputSchema;
|
|
19459
|
+
var init_merge = __esm(() => {
|
|
19460
|
+
init_zod();
|
|
19461
|
+
MergeConfigSchema = exports_external.object({
|
|
19462
|
+
preservePortNames: exports_external.boolean().default(true),
|
|
19463
|
+
outputKey: exports_external.string().optional()
|
|
19464
|
+
});
|
|
19465
|
+
MergeInputSchema = exports_external.record(exports_external.string(), exports_external.unknown());
|
|
19466
|
+
MergeOutputSchema = exports_external.object({
|
|
19467
|
+
items: exports_external.array(exports_external.unknown()),
|
|
19468
|
+
count: exports_external.number(),
|
|
19469
|
+
merged: exports_external.record(exports_external.string(), exports_external.unknown()).optional()
|
|
19470
|
+
});
|
|
19471
|
+
});
|
|
19472
|
+
|
|
19473
|
+
// ../types/src/processor/configs/pdf-embedder.ts
|
|
19474
|
+
var PdfEmbedderInputSchema, PdfEmbedderOutputSchema, PdfEmbedderConfigSchema;
|
|
19475
|
+
var init_pdf_embedder = __esm(() => {
|
|
19476
|
+
init_zod();
|
|
19477
|
+
init_runtime_file_ref();
|
|
19478
|
+
init_parser();
|
|
19479
|
+
PdfEmbedderInputSchema = exports_external.object({
|
|
19480
|
+
file: ResolvedProcessorFileSchema.describe("Resolved source file handle"),
|
|
19481
|
+
parseResult: exports_external.object({
|
|
19482
|
+
pages: exports_external.array(PageResultSchema),
|
|
19483
|
+
text: exports_external.string().optional()
|
|
19484
|
+
}).describe("Parse result from ai.parse step (must include word positions)")
|
|
19485
|
+
});
|
|
19486
|
+
PdfEmbedderOutputSchema = exports_external.object({
|
|
19487
|
+
fileId: exports_external.string().describe("File ID from files table"),
|
|
19488
|
+
pageCount: exports_external.number().describe("Number of pages in the output PDF"),
|
|
19489
|
+
wordCount: exports_external.number().describe("Number of words embedded"),
|
|
19490
|
+
text: exports_external.string().describe("Extracted text (from parse step)")
|
|
19491
|
+
});
|
|
19492
|
+
PdfEmbedderConfigSchema = exports_external.object({
|
|
19493
|
+
outputFilename: exports_external.string().optional().describe('Output filename - supports LiquidJS syntax e.g. "{{filename}}-searchable.pdf"'),
|
|
19494
|
+
confidenceThreshold: exports_external.number().min(0).max(1).default(0.7).describe("Minimum OCR confidence (0-1) to include a word. Lower = more words but more errors")
|
|
19495
|
+
}).prefault({});
|
|
19496
|
+
});
|
|
19497
|
+
|
|
19498
|
+
// ../types/src/processor/configs/split.ts
|
|
19499
|
+
var SplitInputSchema, SplitConfigSchema, ConfidenceLevelSchema, SplitOutputSchema;
|
|
19500
|
+
var init_split = __esm(() => {
|
|
19501
|
+
init_zod();
|
|
19502
|
+
SplitInputSchema = exports_external.object({
|
|
19503
|
+
pages: exports_external.array(exports_external.object({
|
|
19504
|
+
pageIndex: exports_external.number().describe("0-based page index"),
|
|
19505
|
+
text: exports_external.string().describe("Extracted text for this page"),
|
|
19506
|
+
pageName: exports_external.string().optional()
|
|
19507
|
+
})).min(1).describe("Per-page parsed content from a document parser")
|
|
19508
|
+
}).passthrough().describe("Document-parser-shaped input. Pass {{ steps.parse.output }} directly — extra fields like text/metadata are ignored.");
|
|
19509
|
+
SplitConfigSchema = exports_external.object({
|
|
19510
|
+
sections: exports_external.array(exports_external.object({
|
|
19511
|
+
name: exports_external.string().min(1).describe("Stable id for the section"),
|
|
19512
|
+
description: exports_external.string().min(1).describe("What this section looks like in the document. Use the document's own terminology (e.g. 'Príloha 2 / Anlage 2') and visual cues."),
|
|
19513
|
+
required: exports_external.boolean().optional().describe('If true, log a warn when this section is not found, and lean the LLM toward expecting it. Default: false (Reducto-style "may be absent").'),
|
|
19514
|
+
endHints: exports_external.array(exports_external.string()).optional().describe('Natural-language hints fed to the LLM about what marks the END of this section (e.g. ["PRÍPAD PORUŠENIA ZMLUVY", "*Koniec prílohy*", "the next chapter heading"]). The LLM uses these as guidance — not a regex match — so casing variants, missing diacritics, and multilingual phrasings still close the section correctly. The LLM emits a structured end_anchor per section it judges closed; deterministic merge applies it.')
|
|
19515
|
+
})).min(1),
|
|
19516
|
+
rules: exports_external.string().optional().describe("Optional natural-language rules appended to the system prompt"),
|
|
19517
|
+
provider: exports_external.string().optional().describe('Provider ID from eigenpal.config.yaml (e.g. "openai-gpt5.4-mini"). Falls back to the tenant default LLM provider when omitted.'),
|
|
19518
|
+
windowTokenBudget: exports_external.number().int().positive().optional().describe("Per-window token ceiling. Defaults to env SPLIT_WINDOW_TOKEN_BUDGET or 20000. Smaller windows give sharper anchors on contract-style documents (less competing context for the LLM to mis-anchor on); 50k–100k when sections routinely exceed per-window page count.")
|
|
19519
|
+
});
|
|
19520
|
+
ConfidenceLevelSchema = exports_external.enum(["low", "medium", "high"]).describe("LLM confidence as a coarse enum. Numeric (0..1) confidences cluster at 0.85–0.95 and gradations are noise; low/medium/high is reliable.");
|
|
19521
|
+
SplitOutputSchema = exports_external.object({
|
|
19522
|
+
splits: exports_external.array(exports_external.object({
|
|
19523
|
+
name: exports_external.string(),
|
|
19524
|
+
page_range: exports_external.tuple([exports_external.number().int(), exports_external.number().int()]),
|
|
19525
|
+
confidence: ConfidenceLevelSchema.describe("LLM confidence at the start anchor: low | medium | high."),
|
|
19526
|
+
notes: exports_external.string(),
|
|
19527
|
+
evidence: exports_external.object({
|
|
19528
|
+
start_heading_text: exports_external.string().nullable().optional().describe("Verbatim heading text the LLM cited as the section start"),
|
|
19529
|
+
start_page: exports_external.number().int().nullable().optional().describe("Page where start_heading_text appears")
|
|
19530
|
+
}).optional().describe("Structured start-anchor evidence the LLM cited — for downstream parsing without regex over `notes`."),
|
|
19531
|
+
end_evidence: exports_external.object({
|
|
19532
|
+
end_page: exports_external.number().int().describe("LAST page of the section (inclusive)"),
|
|
19533
|
+
confidence: ConfidenceLevelSchema,
|
|
19534
|
+
notes: exports_external.string().describe("LLM justification for the end. Pairs with start-anchor `notes` so a reconciliation pass can judge whether the section is correctly bounded.")
|
|
19535
|
+
}).optional().describe("Set when the LLM flagged a section close (matched against `endHints` or detected end-of-section markers). Absent when the section was closed by deterministic continuity-fill (next section start - 1)."),
|
|
19536
|
+
text: exports_external.string().describe("Joined per-page text for this section, ready for ai.extract"),
|
|
19537
|
+
pages: exports_external.array(exports_external.object({
|
|
19538
|
+
pageIndex: exports_external.number().int(),
|
|
19539
|
+
text: exports_external.string(),
|
|
19540
|
+
pageName: exports_external.string().optional(),
|
|
19541
|
+
source: exports_external.enum(["anchored", "inferred"]).describe("Whether this page was the LLM anchor (direct evidence) or filled in by continuity")
|
|
19542
|
+
})).describe("Raw per-page records covered by this split (in page order). Use when downstream needs to iterate page-by-page rather than treating the section as one blob."),
|
|
19543
|
+
pages_anchored: exports_external.array(exports_external.number().int()),
|
|
19544
|
+
pages_inferred: exports_external.array(exports_external.number().int())
|
|
19545
|
+
}))
|
|
19546
|
+
});
|
|
19547
|
+
});
|
|
19548
|
+
|
|
19549
|
+
// ../types/src/processor/configs/template.ts
|
|
19550
|
+
var TemplateInputSchema, TemplateOutputSchema, TemplateConfigSchema;
|
|
19551
|
+
var init_template = __esm(() => {
|
|
19552
|
+
init_zod();
|
|
19553
|
+
TemplateInputSchema = exports_external.object({
|
|
19554
|
+
data: exports_external.record(exports_external.string(), exports_external.unknown()).describe("Data to merge into the template")
|
|
19555
|
+
});
|
|
19556
|
+
TemplateOutputSchema = exports_external.object({
|
|
19557
|
+
fileId: exports_external.string().describe("File ID from files table")
|
|
19558
|
+
});
|
|
19559
|
+
TemplateConfigSchema = exports_external.object({
|
|
19560
|
+
templateId: exports_external.string().describe("ID of the template from templates table"),
|
|
19561
|
+
outputFilename: exports_external.string().optional().describe('Output filename - supports LiquidJS syntax e.g. "{{invoice_id}}-report.docx"'),
|
|
19562
|
+
highlightNotFound: exports_external.boolean().default(true).optional().describe("Highlight missing variables with red-colored text in the output document"),
|
|
19563
|
+
notFoundText: exports_external.string().default("NOT FOUND").optional().describe("Text to display for missing variables when highlightNotFound is enabled")
|
|
19564
|
+
});
|
|
19565
|
+
});
|
|
19566
|
+
|
|
19567
|
+
// ../types/src/processor/configs/xlsx-to-json.ts
|
|
19568
|
+
var XlsxToJsonInputSchema, XlsxToJsonOutputSchema, XlsxToJsonConfigSchema;
|
|
19569
|
+
var init_xlsx_to_json = __esm(() => {
|
|
19570
|
+
init_zod();
|
|
19571
|
+
init_runtime_file_ref();
|
|
19572
|
+
XlsxToJsonInputSchema = ResolvedProcessorFileSchema;
|
|
19573
|
+
XlsxToJsonOutputSchema = exports_external.object({
|
|
19574
|
+
rows: exports_external.array(exports_external.record(exports_external.string(), exports_external.unknown())).describe("Array of row objects (header row = keys)"),
|
|
19575
|
+
fileId: exports_external.string().optional().describe("File ID of stored CSV when outputCsv is true")
|
|
19576
|
+
});
|
|
19577
|
+
XlsxToJsonConfigSchema = exports_external.object({
|
|
19578
|
+
sheet: exports_external.union([exports_external.number().int().min(0), exports_external.string()]).optional().describe("Sheet to read: 0-based index or sheet name"),
|
|
19579
|
+
outputCsv: exports_external.boolean().default(false).optional(),
|
|
19580
|
+
outputFilename: exports_external.string().optional().describe("Output CSV filename when outputCsv is true")
|
|
19581
|
+
});
|
|
19582
|
+
});
|
|
19583
|
+
|
|
19584
|
+
// ../types/src/processor/configs/react-hook-form.ts
|
|
19585
|
+
function extractFieldMetadata(schema) {
|
|
19586
|
+
const fields = [];
|
|
19587
|
+
let inner = schema;
|
|
19588
|
+
while (inner instanceof exports_external.ZodDefault || inner instanceof exports_external.ZodPrefault) {
|
|
19589
|
+
inner = inner.unwrap();
|
|
19590
|
+
}
|
|
19591
|
+
if (inner instanceof exports_external.ZodObject) {
|
|
19592
|
+
for (const [name, fieldSchema] of Object.entries(inner.shape)) {
|
|
19593
|
+
fields.push(extractSingleFieldMetadata(name, fieldSchema));
|
|
19594
|
+
}
|
|
19595
|
+
}
|
|
19596
|
+
return fields;
|
|
19597
|
+
}
|
|
19598
|
+
function extractSingleFieldMetadata(name, schema) {
|
|
19599
|
+
let current = schema;
|
|
19600
|
+
let required2 = true;
|
|
19601
|
+
let defaultValue = undefined;
|
|
19602
|
+
let description = current.description;
|
|
19603
|
+
while (true) {
|
|
19604
|
+
if (current instanceof exports_external.ZodOptional) {
|
|
19605
|
+
required2 = false;
|
|
19606
|
+
current = current.unwrap();
|
|
19607
|
+
} else if (current instanceof exports_external.ZodDefault || current instanceof exports_external.ZodPrefault) {
|
|
19608
|
+
defaultValue = current._def.defaultValue;
|
|
19609
|
+
current = current.unwrap();
|
|
19610
|
+
} else {
|
|
19611
|
+
break;
|
|
19612
|
+
}
|
|
19613
|
+
description ??= current.description;
|
|
19614
|
+
}
|
|
19615
|
+
const base = { name, type: "unknown", required: required2, description, defaultValue };
|
|
19616
|
+
if (current instanceof exports_external.ZodString)
|
|
19617
|
+
return { ...base, type: "string" };
|
|
19618
|
+
if (current instanceof exports_external.ZodNumber) {
|
|
19619
|
+
let min;
|
|
19620
|
+
let max;
|
|
19621
|
+
for (const c of current._def.checks ?? []) {
|
|
19622
|
+
const def = c._zod.def;
|
|
19623
|
+
if (def.check === "greater_than")
|
|
19624
|
+
min = def.value;
|
|
19625
|
+
if (def.check === "less_than")
|
|
19626
|
+
max = def.value;
|
|
19627
|
+
}
|
|
19628
|
+
return { ...base, type: "number", min, max };
|
|
19629
|
+
}
|
|
19630
|
+
if (current instanceof exports_external.ZodBoolean)
|
|
19631
|
+
return { ...base, type: "boolean" };
|
|
19632
|
+
if (current instanceof exports_external.ZodEnum) {
|
|
19633
|
+
return { ...base, type: "enum", enumValues: current.options };
|
|
19634
|
+
}
|
|
19635
|
+
if (current instanceof exports_external.ZodArray)
|
|
19636
|
+
return { ...base, type: "array" };
|
|
19637
|
+
if (current instanceof exports_external.ZodObject || current instanceof exports_external.ZodRecord) {
|
|
19638
|
+
return { ...base, type: "object" };
|
|
19639
|
+
}
|
|
19640
|
+
return base;
|
|
19641
|
+
}
|
|
19642
|
+
function getConfigFieldMetadata(processorId) {
|
|
19643
|
+
const schema = getConfigSchema(processorId);
|
|
19644
|
+
if (!schema)
|
|
19645
|
+
return;
|
|
19646
|
+
return extractFieldMetadata(schema);
|
|
19647
|
+
}
|
|
19648
|
+
function getConfigDefaults(processorId) {
|
|
19649
|
+
const schema = PROCESSOR_SCHEMAS[processorId]?.configSchema;
|
|
19650
|
+
if (!schema)
|
|
19651
|
+
return {};
|
|
19652
|
+
try {
|
|
19653
|
+
const result = schema.safeParse({});
|
|
19654
|
+
if (result.success) {
|
|
19655
|
+
return result.data;
|
|
19656
|
+
}
|
|
19657
|
+
} catch {}
|
|
19658
|
+
const fields = extractFieldMetadata(schema);
|
|
19659
|
+
const defaults = {};
|
|
19660
|
+
for (const field of fields) {
|
|
19661
|
+
if (field.defaultValue !== undefined) {
|
|
19662
|
+
defaults[field.name] = field.defaultValue;
|
|
19663
|
+
}
|
|
19664
|
+
}
|
|
19665
|
+
return defaults;
|
|
19666
|
+
}
|
|
19667
|
+
function validateConfig(processorId, config2) {
|
|
19668
|
+
const schema = getConfigSchema(processorId);
|
|
19669
|
+
if (!schema) {
|
|
19670
|
+
return { valid: true, errors: {} };
|
|
19671
|
+
}
|
|
19672
|
+
const result = schema.safeParse(config2);
|
|
19673
|
+
if (result.success) {
|
|
19674
|
+
return { valid: true, errors: {} };
|
|
19675
|
+
}
|
|
19676
|
+
const errors3 = {};
|
|
19677
|
+
for (const issue2 of result.error.issues) {
|
|
19678
|
+
const path = issue2.path.join(".");
|
|
19679
|
+
errors3[path] = issue2.message;
|
|
19680
|
+
}
|
|
19681
|
+
return { valid: false, errors: errors3 };
|
|
19682
|
+
}
|
|
19683
|
+
var init_react_hook_form = __esm(() => {
|
|
19684
|
+
init_zod();
|
|
19685
|
+
init_configs();
|
|
19686
|
+
});
|
|
19687
|
+
|
|
19688
|
+
// ../types/src/processor/configs/index.ts
|
|
19689
|
+
function getProcessorSchemas(processorId) {
|
|
19690
|
+
return PROCESSOR_SCHEMAS[processorId];
|
|
19691
|
+
}
|
|
19692
|
+
function getConfigSchema(processorId) {
|
|
19693
|
+
return PROCESSOR_SCHEMAS[processorId]?.configSchema;
|
|
19694
|
+
}
|
|
19695
|
+
function getAllProcessorJsonSchemas() {
|
|
19696
|
+
return Object.values(PROCESSOR_SCHEMAS).map((p) => ({
|
|
19697
|
+
id: p.id,
|
|
19698
|
+
inputSchema: toJsonSchema(p.inputSchema),
|
|
19699
|
+
outputSchema: toJsonSchema(p.outputSchema),
|
|
19700
|
+
configSchema: toJsonSchema(p.configSchema)
|
|
19701
|
+
}));
|
|
19702
|
+
}
|
|
19703
|
+
function listProcessorIds() {
|
|
19704
|
+
return Object.keys(PROCESSOR_SCHEMAS);
|
|
19705
|
+
}
|
|
19706
|
+
var PROCESSOR_SCHEMAS;
|
|
19707
|
+
var init_configs = __esm(() => {
|
|
19708
|
+
init_common();
|
|
19709
|
+
init_ids();
|
|
19710
|
+
init_classify();
|
|
19711
|
+
init_document_parser();
|
|
19712
|
+
init_extract();
|
|
19713
|
+
init_merge();
|
|
19714
|
+
init_pdf_embedder();
|
|
19715
|
+
init_split();
|
|
19716
|
+
init_template();
|
|
19717
|
+
init_xlsx_to_json();
|
|
19718
|
+
init_react_hook_form();
|
|
19719
|
+
init_classify();
|
|
19720
|
+
init_document_parser();
|
|
19721
|
+
init_extract();
|
|
19722
|
+
init_merge();
|
|
19723
|
+
init_pdf_embedder();
|
|
19724
|
+
init_split();
|
|
19725
|
+
init_template();
|
|
19726
|
+
init_xlsx_to_json();
|
|
19727
|
+
PROCESSOR_SCHEMAS = {
|
|
19728
|
+
[PROCESSOR_IDS.EXTRACT]: {
|
|
19729
|
+
id: PROCESSOR_IDS.EXTRACT,
|
|
19730
|
+
inputSchema: ExtractInputSchema,
|
|
19731
|
+
outputSchema: ExtractOutputSchema,
|
|
19732
|
+
configSchema: ExtractConfigSchema
|
|
19733
|
+
},
|
|
19734
|
+
[PROCESSOR_IDS.DOCUMENT_PARSER]: {
|
|
19735
|
+
id: PROCESSOR_IDS.DOCUMENT_PARSER,
|
|
19736
|
+
inputSchema: DocumentParserInputSchema,
|
|
19737
|
+
outputSchema: DocumentParserOutputSchema,
|
|
19738
|
+
configSchema: DocumentParserConfigSchema
|
|
19739
|
+
},
|
|
19740
|
+
[PROCESSOR_IDS.MERGE]: {
|
|
19741
|
+
id: PROCESSOR_IDS.MERGE,
|
|
19742
|
+
inputSchema: MergeInputSchema,
|
|
19743
|
+
outputSchema: MergeOutputSchema,
|
|
19744
|
+
configSchema: MergeConfigSchema
|
|
19745
|
+
},
|
|
19746
|
+
[PROCESSOR_IDS.TEMPLATE]: {
|
|
19747
|
+
id: PROCESSOR_IDS.TEMPLATE,
|
|
19748
|
+
inputSchema: TemplateInputSchema,
|
|
19749
|
+
outputSchema: TemplateOutputSchema,
|
|
19750
|
+
configSchema: TemplateConfigSchema
|
|
19751
|
+
},
|
|
19752
|
+
[PROCESSOR_IDS.PDF_EMBEDDER]: {
|
|
19753
|
+
id: PROCESSOR_IDS.PDF_EMBEDDER,
|
|
19754
|
+
inputSchema: PdfEmbedderInputSchema,
|
|
19755
|
+
outputSchema: PdfEmbedderOutputSchema,
|
|
19756
|
+
configSchema: PdfEmbedderConfigSchema
|
|
19757
|
+
},
|
|
19758
|
+
[PROCESSOR_IDS.SPLIT]: {
|
|
19759
|
+
id: PROCESSOR_IDS.SPLIT,
|
|
19760
|
+
inputSchema: SplitInputSchema,
|
|
19761
|
+
outputSchema: SplitOutputSchema,
|
|
19762
|
+
configSchema: SplitConfigSchema
|
|
19763
|
+
},
|
|
19764
|
+
[PROCESSOR_IDS.CLASSIFY]: {
|
|
19765
|
+
id: PROCESSOR_IDS.CLASSIFY,
|
|
19766
|
+
inputSchema: ClassifyInputSchema,
|
|
19767
|
+
outputSchema: ClassifyOutputSchema,
|
|
19768
|
+
configSchema: ClassifyConfigSchema
|
|
19769
|
+
},
|
|
19770
|
+
[PROCESSOR_IDS.XLSX_TO_JSON]: {
|
|
19771
|
+
id: PROCESSOR_IDS.XLSX_TO_JSON,
|
|
19772
|
+
inputSchema: XlsxToJsonInputSchema,
|
|
19773
|
+
outputSchema: XlsxToJsonOutputSchema,
|
|
19774
|
+
configSchema: XlsxToJsonConfigSchema
|
|
19775
|
+
}
|
|
19776
|
+
};
|
|
19777
|
+
});
|
|
19778
|
+
|
|
17331
19779
|
// ../types/src/processor/index.ts
|
|
17332
|
-
var
|
|
19780
|
+
var init_processor2 = __esm(() => {
|
|
19781
|
+
init_processor();
|
|
19782
|
+
init_execution();
|
|
19783
|
+
init_configs();
|
|
19784
|
+
});
|
|
17333
19785
|
|
|
17334
19786
|
// ../types/src/parser/index.ts
|
|
17335
|
-
var
|
|
19787
|
+
var init_parser2 = __esm(() => {
|
|
19788
|
+
init_parser();
|
|
19789
|
+
});
|
|
17336
19790
|
|
|
17337
19791
|
// ../types/src/otel/semantic-conventions.ts
|
|
17338
19792
|
function mapLLMAttributes(attrs) {
|
|
@@ -20652,7 +23106,7 @@ var require_data = __commonJS((exports, module) => {
|
|
|
20652
23106
|
});
|
|
20653
23107
|
|
|
20654
23108
|
// ../../node_modules/fast-uri/lib/utils.js
|
|
20655
|
-
var
|
|
23109
|
+
var require_utils3 = __commonJS((exports, module) => {
|
|
20656
23110
|
var isUUID = RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu);
|
|
20657
23111
|
var isIPv4 = RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u);
|
|
20658
23112
|
function stringArrayToHexStripped(input) {
|
|
@@ -20908,7 +23362,7 @@ var require_utils = __commonJS((exports, module) => {
|
|
|
20908
23362
|
|
|
20909
23363
|
// ../../node_modules/fast-uri/lib/schemes.js
|
|
20910
23364
|
var require_schemes = __commonJS((exports, module) => {
|
|
20911
|
-
var { isUUID } =
|
|
23365
|
+
var { isUUID } = require_utils3();
|
|
20912
23366
|
var URN_REG = /([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu;
|
|
20913
23367
|
var supportedSchemeNames = [
|
|
20914
23368
|
"http",
|
|
@@ -21082,7 +23536,7 @@ var require_schemes = __commonJS((exports, module) => {
|
|
|
21082
23536
|
|
|
21083
23537
|
// ../../node_modules/fast-uri/index.js
|
|
21084
23538
|
var require_fast_uri = __commonJS((exports, module) => {
|
|
21085
|
-
var { normalizeIPv6, removeDotSegments, recomposeAuthority, normalizeComponentEncoding, isIPv4, nonSimpleDomain } =
|
|
23539
|
+
var { normalizeIPv6, removeDotSegments, recomposeAuthority, normalizeComponentEncoding, isIPv4, nonSimpleDomain } = require_utils3();
|
|
21086
23540
|
var { SCHEMES, getSchemeHandler } = require_schemes();
|
|
21087
23541
|
function normalize(uri, options) {
|
|
21088
23542
|
if (typeof uri === "string") {
|
|
@@ -23492,7 +25946,7 @@ var require_draft7 = __commonJS((exports) => {
|
|
|
23492
25946
|
});
|
|
23493
25947
|
|
|
23494
25948
|
// ../../node_modules/ajv/dist/vocabularies/discriminator/types.js
|
|
23495
|
-
var
|
|
25949
|
+
var require_types2 = __commonJS((exports) => {
|
|
23496
25950
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23497
25951
|
exports.DiscrError = undefined;
|
|
23498
25952
|
var DiscrError;
|
|
@@ -23506,7 +25960,7 @@ var require_types = __commonJS((exports) => {
|
|
|
23506
25960
|
var require_discriminator = __commonJS((exports) => {
|
|
23507
25961
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23508
25962
|
var codegen_1 = require_codegen();
|
|
23509
|
-
var types_1 =
|
|
25963
|
+
var types_1 = require_types2();
|
|
23510
25964
|
var compile_1 = require_compile();
|
|
23511
25965
|
var ref_error_1 = require_ref_error();
|
|
23512
25966
|
var util_1 = require_util();
|
|
@@ -24434,24 +26888,6 @@ var init_validation = __esm(() => {
|
|
|
24434
26888
|
init_workspace_schema();
|
|
24435
26889
|
});
|
|
24436
26890
|
|
|
24437
|
-
// ../types/src/core/common.ts
|
|
24438
|
-
function toJsonSchema2(schema) {
|
|
24439
|
-
return exports_external.toJSONSchema(schema, { target: "draft-7" });
|
|
24440
|
-
}
|
|
24441
|
-
var TimestampSchema2, JsonSchemaSchema2, BaseEntitySchema2;
|
|
24442
|
-
var init_common = __esm(() => {
|
|
24443
|
-
init_zod();
|
|
24444
|
-
TimestampSchema2 = exports_external.union([exports_external.date(), exports_external.string().datetime()]).transform((val) => {
|
|
24445
|
-
return typeof val === "string" ? new Date(val) : val;
|
|
24446
|
-
});
|
|
24447
|
-
JsonSchemaSchema2 = exports_external.record(exports_external.string(), exports_external.unknown());
|
|
24448
|
-
BaseEntitySchema2 = exports_external.object({
|
|
24449
|
-
id: exports_external.string(),
|
|
24450
|
-
createdAt: TimestampSchema2.optional(),
|
|
24451
|
-
updatedAt: TimestampSchema2.optional()
|
|
24452
|
-
});
|
|
24453
|
-
});
|
|
24454
|
-
|
|
24455
26891
|
// ../../node_modules/@babel/parser/lib/index.js
|
|
24456
26892
|
var require_lib = __commonJS((exports) => {
|
|
24457
26893
|
Object.defineProperty(exports, "__esModule", {
|
|
@@ -24865,12 +27301,12 @@ var require_lib = __commonJS((exports) => {
|
|
|
24865
27301
|
}
|
|
24866
27302
|
const ParseErrorConstructors = {};
|
|
24867
27303
|
for (const reasonCode of Object.keys(argument)) {
|
|
24868
|
-
const
|
|
24869
|
-
const _ref = typeof
|
|
24870
|
-
message: () =>
|
|
24871
|
-
} : typeof
|
|
24872
|
-
message:
|
|
24873
|
-
} :
|
|
27304
|
+
const template2 = argument[reasonCode];
|
|
27305
|
+
const _ref = typeof template2 === "string" ? {
|
|
27306
|
+
message: () => template2
|
|
27307
|
+
} : typeof template2 === "function" ? {
|
|
27308
|
+
message: template2
|
|
27309
|
+
} : template2, {
|
|
24874
27310
|
message
|
|
24875
27311
|
} = _ref, rest = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
24876
27312
|
const toMessage = typeof message === "string" ? () => message : message;
|
|
@@ -39343,7 +41779,7 @@ var require_keywords = __commonJS((exports) => {
|
|
|
39343
41779
|
});
|
|
39344
41780
|
|
|
39345
41781
|
// ../../node_modules/sucrase/dist/parser/tokenizer/types.js
|
|
39346
|
-
var
|
|
41782
|
+
var require_types3 = __commonJS((exports) => {
|
|
39347
41783
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39348
41784
|
var TokenType;
|
|
39349
41785
|
(function(TokenType2) {
|
|
@@ -39407,8 +41843,8 @@ var require_types2 = __commonJS((exports) => {
|
|
|
39407
41843
|
TokenType2[TokenType2["questionDot"] = questionDot] = "questionDot";
|
|
39408
41844
|
const arrow = 22528;
|
|
39409
41845
|
TokenType2[TokenType2["arrow"] = arrow] = "arrow";
|
|
39410
|
-
const
|
|
39411
|
-
TokenType2[TokenType2["template"] =
|
|
41846
|
+
const template2 = 23552;
|
|
41847
|
+
TokenType2[TokenType2["template"] = template2] = "template";
|
|
39412
41848
|
const ellipsis = 24576;
|
|
39413
41849
|
TokenType2[TokenType2["ellipsis"] = ellipsis] = "ellipsis";
|
|
39414
41850
|
const backQuote = 25600;
|
|
@@ -39827,7 +42263,7 @@ var require_types2 = __commonJS((exports) => {
|
|
|
39827
42263
|
var require_state = __commonJS((exports) => {
|
|
39828
42264
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39829
42265
|
var _keywords = require_keywords();
|
|
39830
|
-
var _types =
|
|
42266
|
+
var _types = require_types3();
|
|
39831
42267
|
|
|
39832
42268
|
class Scope {
|
|
39833
42269
|
constructor(startTokenIndex, endTokenIndex, isFunctionScope) {
|
|
@@ -40213,7 +42649,7 @@ var require_base = __commonJS((exports) => {
|
|
|
40213
42649
|
var require_util2 = __commonJS((exports) => {
|
|
40214
42650
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
40215
42651
|
var _index = require_tokenizer();
|
|
40216
|
-
var _types =
|
|
42652
|
+
var _types = require_types3();
|
|
40217
42653
|
var _charcodes = require_charcodes();
|
|
40218
42654
|
var _base = require_base();
|
|
40219
42655
|
function isContextual(contextualKeyword) {
|
|
@@ -40375,7 +42811,7 @@ var require_identifier = __commonJS((exports) => {
|
|
|
40375
42811
|
var require_readWordTree = __commonJS((exports) => {
|
|
40376
42812
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
40377
42813
|
var _keywords = require_keywords();
|
|
40378
|
-
var _types =
|
|
42814
|
+
var _types = require_types3();
|
|
40379
42815
|
var READ_WORD_TREE = new Int32Array([
|
|
40380
42816
|
-1,
|
|
40381
42817
|
27,
|
|
@@ -49353,7 +51789,7 @@ var require_readWord = __commonJS((exports) => {
|
|
|
49353
51789
|
var _identifier = require_identifier();
|
|
49354
51790
|
var _index = require_tokenizer();
|
|
49355
51791
|
var _readWordTree = require_readWordTree();
|
|
49356
|
-
var _types =
|
|
51792
|
+
var _types = require_types3();
|
|
49357
51793
|
function readWord() {
|
|
49358
51794
|
let treePos = 0;
|
|
49359
51795
|
let code = 0;
|
|
@@ -49419,7 +51855,7 @@ var require_tokenizer = __commonJS((exports) => {
|
|
|
49419
51855
|
var _keywords = require_keywords();
|
|
49420
51856
|
var _readWord = require_readWord();
|
|
49421
51857
|
var _readWord2 = _interopRequireDefault(_readWord);
|
|
49422
|
-
var _types =
|
|
51858
|
+
var _types = require_types3();
|
|
49423
51859
|
var IdentifierRole;
|
|
49424
51860
|
(function(IdentifierRole2) {
|
|
49425
51861
|
const Access = 0;
|
|
@@ -50136,7 +52572,7 @@ var require_tokenizer = __commonJS((exports) => {
|
|
|
50136
52572
|
// ../../node_modules/sucrase/dist/util/getImportExportSpecifierInfo.js
|
|
50137
52573
|
var require_getImportExportSpecifierInfo = __commonJS((exports) => {
|
|
50138
52574
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
50139
|
-
var _types =
|
|
52575
|
+
var _types = require_types3();
|
|
50140
52576
|
function getImportExportSpecifierInfo(tokens, index = tokens.currentIndex()) {
|
|
50141
52577
|
let endIndex = index + 1;
|
|
50142
52578
|
if (isSpecifierEnd(tokens, endIndex)) {
|
|
@@ -50489,7 +52925,7 @@ var require_JSXTransformer = __commonJS((exports) => {
|
|
|
50489
52925
|
var _xhtml = require_xhtml();
|
|
50490
52926
|
var _xhtml2 = _interopRequireDefault(_xhtml);
|
|
50491
52927
|
var _tokenizer = require_tokenizer();
|
|
50492
|
-
var _types =
|
|
52928
|
+
var _types = require_types3();
|
|
50493
52929
|
var _charcodes = require_charcodes();
|
|
50494
52930
|
var _getJSXPragmaInfo = require_getJSXPragmaInfo();
|
|
50495
52931
|
var _getJSXPragmaInfo2 = _interopRequireDefault(_getJSXPragmaInfo);
|
|
@@ -50993,7 +53429,7 @@ var require_getNonTypeIdentifiers = __commonJS((exports) => {
|
|
|
50993
53429
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
50994
53430
|
}
|
|
50995
53431
|
var _tokenizer = require_tokenizer();
|
|
50996
|
-
var _types =
|
|
53432
|
+
var _types = require_types3();
|
|
50997
53433
|
var _JSXTransformer = require_JSXTransformer();
|
|
50998
53434
|
var _getJSXPragmaInfo = require_getJSXPragmaInfo();
|
|
50999
53435
|
var _getJSXPragmaInfo2 = _interopRequireDefault(_getJSXPragmaInfo);
|
|
@@ -51032,7 +53468,7 @@ var require_CJSImportProcessor = __commonJS((exports) => {
|
|
|
51032
53468
|
}
|
|
51033
53469
|
var _tokenizer = require_tokenizer();
|
|
51034
53470
|
var _keywords = require_keywords();
|
|
51035
|
-
var _types =
|
|
53471
|
+
var _types = require_types3();
|
|
51036
53472
|
var _getImportExportSpecifierInfo = require_getImportExportSpecifierInfo();
|
|
51037
53473
|
var _getImportExportSpecifierInfo2 = _interopRequireDefault(_getImportExportSpecifierInfo);
|
|
51038
53474
|
var _getNonTypeIdentifiers = require_getNonTypeIdentifiers();
|
|
@@ -53067,7 +55503,7 @@ var require_HelperManager = __commonJS((exports) => {
|
|
|
53067
55503
|
var require_identifyShadowedGlobals = __commonJS((exports) => {
|
|
53068
55504
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
53069
55505
|
var _tokenizer = require_tokenizer();
|
|
53070
|
-
var _types =
|
|
55506
|
+
var _types = require_types3();
|
|
53071
55507
|
function identifyShadowedGlobals(tokens, scopes, globalNames) {
|
|
53072
55508
|
if (!hasShadowedGlobals(tokens, globalNames)) {
|
|
53073
55509
|
return;
|
|
@@ -53132,7 +55568,7 @@ var require_identifyShadowedGlobals = __commonJS((exports) => {
|
|
|
53132
55568
|
// ../../node_modules/sucrase/dist/util/getIdentifierNames.js
|
|
53133
55569
|
var require_getIdentifierNames = __commonJS((exports) => {
|
|
53134
55570
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
53135
|
-
var _types =
|
|
55571
|
+
var _types = require_types3();
|
|
53136
55572
|
function getIdentifierNames(code, tokens) {
|
|
53137
55573
|
const names = [];
|
|
53138
55574
|
for (const token of tokens) {
|
|
@@ -53308,7 +55744,7 @@ var require_util3 = __commonJS((exports) => {
|
|
|
53308
55744
|
});
|
|
53309
55745
|
|
|
53310
55746
|
// ../../node_modules/ts-interface-checker/dist/types.js
|
|
53311
|
-
var
|
|
55747
|
+
var require_types4 = __commonJS((exports) => {
|
|
53312
55748
|
var __extends = exports && exports.__extends || function() {
|
|
53313
55749
|
var extendStatics = function(d, b) {
|
|
53314
55750
|
extendStatics = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(d2, b2) {
|
|
@@ -53908,9 +56344,9 @@ var require_dist2 = __commonJS((exports) => {
|
|
|
53908
56344
|
};
|
|
53909
56345
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
53910
56346
|
exports.Checker = exports.createCheckers = undefined;
|
|
53911
|
-
var types_1 =
|
|
56347
|
+
var types_1 = require_types4();
|
|
53912
56348
|
var util_1 = require_util3();
|
|
53913
|
-
var types_2 =
|
|
56349
|
+
var types_2 = require_types4();
|
|
53914
56350
|
Object.defineProperty(exports, "TArray", { enumerable: true, get: function() {
|
|
53915
56351
|
return types_2.TArray;
|
|
53916
56352
|
} });
|
|
@@ -54192,7 +56628,7 @@ var require_lval = __commonJS((exports) => {
|
|
|
54192
56628
|
var _typescript = require_typescript();
|
|
54193
56629
|
var _index = require_tokenizer();
|
|
54194
56630
|
var _keywords = require_keywords();
|
|
54195
|
-
var _types =
|
|
56631
|
+
var _types = require_types3();
|
|
54196
56632
|
var _base = require_base();
|
|
54197
56633
|
var _expression = require_expression();
|
|
54198
56634
|
var _util = require_util2();
|
|
@@ -54324,7 +56760,7 @@ var require_typescript = __commonJS((exports) => {
|
|
|
54324
56760
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
54325
56761
|
var _index = require_tokenizer();
|
|
54326
56762
|
var _keywords = require_keywords();
|
|
54327
|
-
var _types =
|
|
56763
|
+
var _types = require_types3();
|
|
54328
56764
|
var _base = require_base();
|
|
54329
56765
|
var _expression = require_expression();
|
|
54330
56766
|
var _lval = require_lval();
|
|
@@ -55586,7 +58022,7 @@ var require_typescript = __commonJS((exports) => {
|
|
|
55586
58022
|
var require_jsx = __commonJS((exports) => {
|
|
55587
58023
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
55588
58024
|
var _index = require_tokenizer();
|
|
55589
|
-
var _types =
|
|
58025
|
+
var _types = require_types3();
|
|
55590
58026
|
var _base = require_base();
|
|
55591
58027
|
var _expression = require_expression();
|
|
55592
58028
|
var _util = require_util2();
|
|
@@ -55849,10 +58285,10 @@ var require_jsx = __commonJS((exports) => {
|
|
|
55849
58285
|
});
|
|
55850
58286
|
|
|
55851
58287
|
// ../../node_modules/sucrase/dist/parser/plugins/types.js
|
|
55852
|
-
var
|
|
58288
|
+
var require_types5 = __commonJS((exports) => {
|
|
55853
58289
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
55854
58290
|
var _index = require_tokenizer();
|
|
55855
|
-
var _types =
|
|
58291
|
+
var _types = require_types3();
|
|
55856
58292
|
var _base = require_base();
|
|
55857
58293
|
var _expression = require_expression();
|
|
55858
58294
|
var _flow = require_flow();
|
|
@@ -55885,12 +58321,12 @@ var require_expression = __commonJS((exports) => {
|
|
|
55885
58321
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
55886
58322
|
var _flow = require_flow();
|
|
55887
58323
|
var _index = require_jsx();
|
|
55888
|
-
var _types =
|
|
58324
|
+
var _types = require_types5();
|
|
55889
58325
|
var _typescript = require_typescript();
|
|
55890
58326
|
var _index3 = require_tokenizer();
|
|
55891
58327
|
var _keywords = require_keywords();
|
|
55892
58328
|
var _state = require_state();
|
|
55893
|
-
var _types3 =
|
|
58329
|
+
var _types3 = require_types3();
|
|
55894
58330
|
var _charcodes = require_charcodes();
|
|
55895
58331
|
var _identifier = require_identifier();
|
|
55896
58332
|
var _base = require_base();
|
|
@@ -56606,7 +59042,7 @@ var require_flow = __commonJS((exports) => {
|
|
|
56606
59042
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
56607
59043
|
var _index = require_tokenizer();
|
|
56608
59044
|
var _keywords = require_keywords();
|
|
56609
|
-
var _types =
|
|
59045
|
+
var _types = require_types3();
|
|
56610
59046
|
var _base = require_base();
|
|
56611
59047
|
var _expression = require_expression();
|
|
56612
59048
|
var _statement = require_statement();
|
|
@@ -57481,7 +59917,7 @@ var require_statement = __commonJS((exports) => {
|
|
|
57481
59917
|
var _tokenizer = require_tokenizer();
|
|
57482
59918
|
var _keywords = require_keywords();
|
|
57483
59919
|
var _state = require_state();
|
|
57484
|
-
var _types =
|
|
59920
|
+
var _types = require_types3();
|
|
57485
59921
|
var _charcodes = require_charcodes();
|
|
57486
59922
|
var _base = require_base();
|
|
57487
59923
|
var _expression = require_expression();
|
|
@@ -58516,7 +60952,7 @@ var require_TokenProcessor = __commonJS((exports) => {
|
|
|
58516
60952
|
function _interopRequireDefault(obj) {
|
|
58517
60953
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
58518
60954
|
}
|
|
58519
|
-
var _types =
|
|
60955
|
+
var _types = require_types3();
|
|
58520
60956
|
var _isAsyncOperation = require_isAsyncOperation();
|
|
58521
60957
|
var _isAsyncOperation2 = _interopRequireDefault(_isAsyncOperation);
|
|
58522
60958
|
|
|
@@ -58774,7 +61210,7 @@ var require_TokenProcessor = __commonJS((exports) => {
|
|
|
58774
61210
|
var require_getClassInfo = __commonJS((exports) => {
|
|
58775
61211
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
58776
61212
|
var _keywords = require_keywords();
|
|
58777
|
-
var _types =
|
|
61213
|
+
var _types = require_types3();
|
|
58778
61214
|
function getClassInfo(rootTransformer, tokens, nameManager, disableESTransforms) {
|
|
58779
61215
|
const snapshot = tokens.snapshot();
|
|
58780
61216
|
const headerInfo = processClassHeader(tokens);
|
|
@@ -59012,7 +61448,7 @@ var require_getClassInfo = __commonJS((exports) => {
|
|
|
59012
61448
|
// ../../node_modules/sucrase/dist/util/elideImportEquals.js
|
|
59013
61449
|
var require_elideImportEquals = __commonJS((exports) => {
|
|
59014
61450
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
59015
|
-
var _types =
|
|
61451
|
+
var _types = require_types3();
|
|
59016
61452
|
function elideImportEquals(tokens) {
|
|
59017
61453
|
tokens.removeInitialToken();
|
|
59018
61454
|
tokens.removeToken();
|
|
@@ -59036,7 +61472,7 @@ var require_elideImportEquals = __commonJS((exports) => {
|
|
|
59036
61472
|
var require_getDeclarationInfo = __commonJS((exports) => {
|
|
59037
61473
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
59038
61474
|
var _tokenizer = require_tokenizer();
|
|
59039
|
-
var _types =
|
|
61475
|
+
var _types = require_types3();
|
|
59040
61476
|
var EMPTY_DECLARATION_INFO = {
|
|
59041
61477
|
typeDeclarations: new Set,
|
|
59042
61478
|
valueDeclarations: new Set
|
|
@@ -59064,7 +61500,7 @@ var require_getDeclarationInfo = __commonJS((exports) => {
|
|
|
59064
61500
|
var require_isExportFrom = __commonJS((exports) => {
|
|
59065
61501
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
59066
61502
|
var _keywords = require_keywords();
|
|
59067
|
-
var _types =
|
|
61503
|
+
var _types = require_types3();
|
|
59068
61504
|
function isExportFrom(tokens) {
|
|
59069
61505
|
let closeBraceIndex = tokens.currentIndex();
|
|
59070
61506
|
while (!tokens.matches1AtIndex(closeBraceIndex, _types.TokenType.braceR)) {
|
|
@@ -59079,7 +61515,7 @@ var require_isExportFrom = __commonJS((exports) => {
|
|
|
59079
61515
|
var require_removeMaybeImportAttributes = __commonJS((exports) => {
|
|
59080
61516
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
59081
61517
|
var _keywords = require_keywords();
|
|
59082
|
-
var _types =
|
|
61518
|
+
var _types = require_types3();
|
|
59083
61519
|
function removeMaybeImportAttributes(tokens) {
|
|
59084
61520
|
if (tokens.matches2(_types.TokenType._with, _types.TokenType.braceL) || tokens.matches2(_types.TokenType.name, _types.TokenType.braceL) && tokens.matchesContextual(_keywords.ContextualKeyword._assert)) {
|
|
59085
61521
|
tokens.removeToken();
|
|
@@ -59094,7 +61530,7 @@ var require_removeMaybeImportAttributes = __commonJS((exports) => {
|
|
|
59094
61530
|
// ../../node_modules/sucrase/dist/util/shouldElideDefaultExport.js
|
|
59095
61531
|
var require_shouldElideDefaultExport = __commonJS((exports) => {
|
|
59096
61532
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
59097
|
-
var _types =
|
|
61533
|
+
var _types = require_types3();
|
|
59098
61534
|
function shouldElideDefaultExport(isTypeScriptTransformEnabled, keepUnusedImports, tokens, declarationInfo) {
|
|
59099
61535
|
if (!isTypeScriptTransformEnabled || keepUnusedImports) {
|
|
59100
61536
|
return false;
|
|
@@ -59125,7 +61561,7 @@ var require_CJSImportTransformer = __commonJS((exports) => {
|
|
|
59125
61561
|
}
|
|
59126
61562
|
var _tokenizer = require_tokenizer();
|
|
59127
61563
|
var _keywords = require_keywords();
|
|
59128
|
-
var _types =
|
|
61564
|
+
var _types = require_types3();
|
|
59129
61565
|
var _elideImportEquals = require_elideImportEquals();
|
|
59130
61566
|
var _elideImportEquals2 = _interopRequireDefault(_elideImportEquals);
|
|
59131
61567
|
var _getDeclarationInfo = require_getDeclarationInfo();
|
|
@@ -59767,7 +62203,7 @@ var require_ESMImportTransformer = __commonJS((exports) => {
|
|
|
59767
62203
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
59768
62204
|
}
|
|
59769
62205
|
var _keywords = require_keywords();
|
|
59770
|
-
var _types =
|
|
62206
|
+
var _types = require_types3();
|
|
59771
62207
|
var _elideImportEquals = require_elideImportEquals();
|
|
59772
62208
|
var _elideImportEquals2 = _interopRequireDefault(_elideImportEquals);
|
|
59773
62209
|
var _getDeclarationInfo = require_getDeclarationInfo();
|
|
@@ -60037,7 +62473,7 @@ var require_FlowTransformer = __commonJS((exports) => {
|
|
|
60037
62473
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
60038
62474
|
}
|
|
60039
62475
|
var _keywords = require_keywords();
|
|
60040
|
-
var _types =
|
|
62476
|
+
var _types = require_types3();
|
|
60041
62477
|
var _Transformer = require_Transformer();
|
|
60042
62478
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
60043
62479
|
|
|
@@ -60157,7 +62593,7 @@ var require_JestHoistTransformer = __commonJS((exports) => {
|
|
|
60157
62593
|
}
|
|
60158
62594
|
return value;
|
|
60159
62595
|
}
|
|
60160
|
-
var _types =
|
|
62596
|
+
var _types = require_types3();
|
|
60161
62597
|
var _Transformer = require_Transformer();
|
|
60162
62598
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
60163
62599
|
var JEST_GLOBAL_NAME = "jest";
|
|
@@ -60231,7 +62667,7 @@ var require_NumericSeparatorTransformer = __commonJS((exports) => {
|
|
|
60231
62667
|
function _interopRequireDefault(obj) {
|
|
60232
62668
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
60233
62669
|
}
|
|
60234
|
-
var _types =
|
|
62670
|
+
var _types = require_types3();
|
|
60235
62671
|
var _Transformer = require_Transformer();
|
|
60236
62672
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
60237
62673
|
|
|
@@ -60260,7 +62696,7 @@ var require_OptionalCatchBindingTransformer = __commonJS((exports) => {
|
|
|
60260
62696
|
function _interopRequireDefault(obj) {
|
|
60261
62697
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
60262
62698
|
}
|
|
60263
|
-
var _types =
|
|
62699
|
+
var _types = require_types3();
|
|
60264
62700
|
var _Transformer = require_Transformer();
|
|
60265
62701
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
60266
62702
|
|
|
@@ -60288,7 +62724,7 @@ var require_OptionalChainingNullishTransformer = __commonJS((exports) => {
|
|
|
60288
62724
|
function _interopRequireDefault(obj) {
|
|
60289
62725
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
60290
62726
|
}
|
|
60291
|
-
var _types =
|
|
62727
|
+
var _types = require_types3();
|
|
60292
62728
|
var _Transformer = require_Transformer();
|
|
60293
62729
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
60294
62730
|
|
|
@@ -60404,7 +62840,7 @@ var require_ReactDisplayNameTransformer = __commonJS((exports) => {
|
|
|
60404
62840
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
60405
62841
|
}
|
|
60406
62842
|
var _tokenizer = require_tokenizer();
|
|
60407
|
-
var _types =
|
|
62843
|
+
var _types = require_types3();
|
|
60408
62844
|
var _Transformer = require_Transformer();
|
|
60409
62845
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
60410
62846
|
|
|
@@ -60655,7 +63091,7 @@ var require_TypeScriptTransformer = __commonJS((exports) => {
|
|
|
60655
63091
|
function _interopRequireDefault(obj) {
|
|
60656
63092
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
60657
63093
|
}
|
|
60658
|
-
var _types =
|
|
63094
|
+
var _types = require_types3();
|
|
60659
63095
|
var _isIdentifier = require_isIdentifier();
|
|
60660
63096
|
var _isIdentifier2 = _interopRequireDefault(_isIdentifier);
|
|
60661
63097
|
var _Transformer = require_Transformer();
|
|
@@ -60801,7 +63237,7 @@ var require_RootTransformer = __commonJS((exports) => {
|
|
|
60801
63237
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
60802
63238
|
}
|
|
60803
63239
|
var _keywords = require_keywords();
|
|
60804
|
-
var _types =
|
|
63240
|
+
var _types = require_types3();
|
|
60805
63241
|
var _getClassInfo = require_getClassInfo();
|
|
60806
63242
|
var _getClassInfo2 = _interopRequireDefault(_getClassInfo);
|
|
60807
63243
|
var _CJSImportTransformer = require_CJSImportTransformer();
|
|
@@ -61200,7 +63636,7 @@ var require_formatTokens = __commonJS((exports) => {
|
|
|
61200
63636
|
}
|
|
61201
63637
|
var _linesandcolumns = require_build();
|
|
61202
63638
|
var _linesandcolumns2 = _interopRequireDefault(_linesandcolumns);
|
|
61203
|
-
var _types =
|
|
63639
|
+
var _types = require_types3();
|
|
61204
63640
|
function formatTokens(code, tokens) {
|
|
61205
63641
|
if (tokens.length === 0) {
|
|
61206
63642
|
return "";
|
|
@@ -61265,7 +63701,7 @@ var require_getTSImportedNames = __commonJS((exports) => {
|
|
|
61265
63701
|
function _interopRequireDefault(obj) {
|
|
61266
63702
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
61267
63703
|
}
|
|
61268
|
-
var _types =
|
|
63704
|
+
var _types = require_types3();
|
|
61269
63705
|
var _getImportExportSpecifierInfo = require_getImportExportSpecifierInfo();
|
|
61270
63706
|
var _getImportExportSpecifierInfo2 = _interopRequireDefault(_getImportExportSpecifierInfo);
|
|
61271
63707
|
function getTSImportedNames(tokens) {
|
|
@@ -61650,7 +64086,7 @@ function describeUnsupportedType(nodeType) {
|
|
|
61650
64086
|
function compileTypedScript(opts) {
|
|
61651
64087
|
let ast;
|
|
61652
64088
|
try {
|
|
61653
|
-
ast =
|
|
64089
|
+
ast = import_parser4.parse(opts.source, {
|
|
61654
64090
|
sourceType: "script",
|
|
61655
64091
|
plugins: ["typescript"],
|
|
61656
64092
|
ranges: true
|
|
@@ -61902,9 +64338,9 @@ function stripCommentsAndStrings(s) {
|
|
|
61902
64338
|
out = out.replace(/`(\\.|[^`\\])*`/g, "``");
|
|
61903
64339
|
return out;
|
|
61904
64340
|
}
|
|
61905
|
-
var
|
|
64341
|
+
var import_parser4, import_sucrase, EVALUATOR_FN_NAME = "scoreScript", EVALUATOR_PARAM_NAMES, TRANSFORM_FN_NAME = "script";
|
|
61906
64342
|
var init_compile = __esm(() => {
|
|
61907
|
-
|
|
64343
|
+
import_parser4 = __toESM(require_lib(), 1);
|
|
61908
64344
|
import_sucrase = __toESM(require_dist3(), 1);
|
|
61909
64345
|
EVALUATOR_PARAM_NAMES = ["expected", "actual"];
|
|
61910
64346
|
});
|
|
@@ -62118,8 +64554,8 @@ function getAllStepJsonSchemas() {
|
|
|
62118
64554
|
category: def.category,
|
|
62119
64555
|
name: def.name,
|
|
62120
64556
|
description: def.description,
|
|
62121
|
-
configSchema:
|
|
62122
|
-
outputSchema:
|
|
64557
|
+
configSchema: toJsonSchema(def.configSchema),
|
|
64558
|
+
outputSchema: toJsonSchema(def.outputSchema),
|
|
62123
64559
|
configInWith: def.configInWith
|
|
62124
64560
|
}));
|
|
62125
64561
|
}
|
|
@@ -62765,81 +65201,6 @@ var init_actions = __esm(() => {
|
|
|
62765
65201
|
ACTION_TYPES = ActionTypeSchema.options;
|
|
62766
65202
|
});
|
|
62767
65203
|
|
|
62768
|
-
// ../types/src/processor/execution.ts
|
|
62769
|
-
function asTuple(values) {
|
|
62770
|
-
return values;
|
|
62771
|
-
}
|
|
62772
|
-
var WorkflowExecutionStatusValue2, WorkflowExecutionStatusSchema2, StepExecutionStatusValue2, StepExecutionStatusSchema2, TriggerTypeValue2, TriggerTypeSchema2, ExecutionTypeValue2, ExecutionTypeSchema2, WORKFLOW_EXECUTION_STATUSES2, STEP_EXECUTION_STATUSES2, TRIGGER_TYPES2, EXECUTION_TYPES2;
|
|
62773
|
-
var init_execution = __esm(() => {
|
|
62774
|
-
init_zod();
|
|
62775
|
-
WorkflowExecutionStatusValue2 = {
|
|
62776
|
-
CREATED: "created",
|
|
62777
|
-
PENDING: "pending",
|
|
62778
|
-
RUNNING: "running",
|
|
62779
|
-
WAITING: "waiting",
|
|
62780
|
-
COMPLETED: "completed",
|
|
62781
|
-
FAILED: "failed",
|
|
62782
|
-
CANCELLED: "cancelled"
|
|
62783
|
-
};
|
|
62784
|
-
WorkflowExecutionStatusSchema2 = exports_external.enum([
|
|
62785
|
-
WorkflowExecutionStatusValue2.CREATED,
|
|
62786
|
-
WorkflowExecutionStatusValue2.PENDING,
|
|
62787
|
-
WorkflowExecutionStatusValue2.RUNNING,
|
|
62788
|
-
WorkflowExecutionStatusValue2.WAITING,
|
|
62789
|
-
WorkflowExecutionStatusValue2.COMPLETED,
|
|
62790
|
-
WorkflowExecutionStatusValue2.FAILED,
|
|
62791
|
-
WorkflowExecutionStatusValue2.CANCELLED
|
|
62792
|
-
]);
|
|
62793
|
-
StepExecutionStatusValue2 = {
|
|
62794
|
-
PENDING: "pending",
|
|
62795
|
-
RUNNING: "running",
|
|
62796
|
-
SUCCESS: "success",
|
|
62797
|
-
FAILURE: "failure",
|
|
62798
|
-
WAITING: "waiting",
|
|
62799
|
-
SKIPPED: "skipped"
|
|
62800
|
-
};
|
|
62801
|
-
StepExecutionStatusSchema2 = exports_external.enum([
|
|
62802
|
-
StepExecutionStatusValue2.PENDING,
|
|
62803
|
-
StepExecutionStatusValue2.RUNNING,
|
|
62804
|
-
StepExecutionStatusValue2.SUCCESS,
|
|
62805
|
-
StepExecutionStatusValue2.FAILURE,
|
|
62806
|
-
StepExecutionStatusValue2.WAITING,
|
|
62807
|
-
StepExecutionStatusValue2.SKIPPED
|
|
62808
|
-
]);
|
|
62809
|
-
TriggerTypeValue2 = {
|
|
62810
|
-
MANUAL: "manual",
|
|
62811
|
-
API: "api",
|
|
62812
|
-
WEBHOOK: "webhook",
|
|
62813
|
-
SCHEDULE: "schedule",
|
|
62814
|
-
EMAIL: "email",
|
|
62815
|
-
EVAL: "eval",
|
|
62816
|
-
CLI: "cli"
|
|
62817
|
-
};
|
|
62818
|
-
TriggerTypeSchema2 = exports_external.enum([
|
|
62819
|
-
TriggerTypeValue2.MANUAL,
|
|
62820
|
-
TriggerTypeValue2.API,
|
|
62821
|
-
TriggerTypeValue2.WEBHOOK,
|
|
62822
|
-
TriggerTypeValue2.SCHEDULE,
|
|
62823
|
-
TriggerTypeValue2.EMAIL,
|
|
62824
|
-
TriggerTypeValue2.EVAL,
|
|
62825
|
-
TriggerTypeValue2.CLI
|
|
62826
|
-
]);
|
|
62827
|
-
ExecutionTypeValue2 = {
|
|
62828
|
-
PROD: "prod",
|
|
62829
|
-
EVAL: "eval",
|
|
62830
|
-
PLAYGROUND: "playground"
|
|
62831
|
-
};
|
|
62832
|
-
ExecutionTypeSchema2 = exports_external.enum([
|
|
62833
|
-
ExecutionTypeValue2.PROD,
|
|
62834
|
-
ExecutionTypeValue2.EVAL,
|
|
62835
|
-
ExecutionTypeValue2.PLAYGROUND
|
|
62836
|
-
]);
|
|
62837
|
-
WORKFLOW_EXECUTION_STATUSES2 = asTuple(WorkflowExecutionStatusSchema2.options);
|
|
62838
|
-
STEP_EXECUTION_STATUSES2 = asTuple(StepExecutionStatusSchema2.options);
|
|
62839
|
-
TRIGGER_TYPES2 = TriggerTypeSchema2.options;
|
|
62840
|
-
EXECUTION_TYPES2 = ExecutionTypeSchema2.options;
|
|
62841
|
-
});
|
|
62842
|
-
|
|
62843
65204
|
// ../types/src/workflow/workflow.ts
|
|
62844
65205
|
function suggestWorkflowName(raw) {
|
|
62845
65206
|
return raw.toLowerCase().replace(/[^a-z0-9_-]+/g, "-").replace(/^[_-]+|[_-]+$/g, "").slice(0, 64);
|
|
@@ -62920,11 +65281,11 @@ var init_workflow = __esm(() => {
|
|
|
62920
65281
|
ManualTriggerMethodSchema = exports_external.object({
|
|
62921
65282
|
type: exports_external.literal("manual"),
|
|
62922
65283
|
enabled: exports_external.boolean().optional(),
|
|
62923
|
-
inputSchema:
|
|
65284
|
+
inputSchema: JsonSchemaSchema.optional()
|
|
62924
65285
|
});
|
|
62925
65286
|
ApiTriggerMethodSchema = exports_external.object({
|
|
62926
65287
|
type: exports_external.literal("api"),
|
|
62927
|
-
inputSchema:
|
|
65288
|
+
inputSchema: JsonSchemaSchema.optional()
|
|
62928
65289
|
});
|
|
62929
65290
|
EmailTriggerMethodSchema = exports_external.object({
|
|
62930
65291
|
type: exports_external.literal("email"),
|
|
@@ -62963,8 +65324,8 @@ var init_workflow = __esm(() => {
|
|
|
62963
65324
|
yamlContent: exports_external.string(),
|
|
62964
65325
|
definition: WorkflowDefinitionSchema,
|
|
62965
65326
|
isCurrent: exports_external.boolean().default(true),
|
|
62966
|
-
createdAt:
|
|
62967
|
-
updatedAt:
|
|
65327
|
+
createdAt: TimestampSchema,
|
|
65328
|
+
updatedAt: TimestampSchema.optional(),
|
|
62968
65329
|
createdBy: exports_external.string()
|
|
62969
65330
|
});
|
|
62970
65331
|
CreateWorkflowDefinitionSchema = exports_external.object({
|
|
@@ -63146,14 +65507,14 @@ function isFileOutput(value) {
|
|
|
63146
65507
|
function isWorkflowResult(value) {
|
|
63147
65508
|
return value != null && typeof value === "object" && "files" in value && Array.isArray(value.files);
|
|
63148
65509
|
}
|
|
63149
|
-
var
|
|
65510
|
+
var WorkflowExecutionStatusSchema2, StepExecutionStatusSchema2, ScopeEntryTypeSchema, ScopeEntrySchema, ScopeStackSchema, StepResultSchema, ExecutionContextSchema, StepInputReferenceSchema, WorkflowExecutionSchema, StepExecutionSchema, ConnectorSchema, WorkflowFileOutputSchema, WorkflowResultSchema;
|
|
63150
65511
|
var init_execution2 = __esm(() => {
|
|
63151
65512
|
init_zod();
|
|
63152
65513
|
init_common();
|
|
63153
65514
|
init_execution();
|
|
63154
65515
|
init_workflow();
|
|
63155
|
-
|
|
63156
|
-
|
|
65516
|
+
WorkflowExecutionStatusSchema2 = WorkflowExecutionStatusSchema;
|
|
65517
|
+
StepExecutionStatusSchema2 = StepExecutionStatusSchema;
|
|
63157
65518
|
ScopeEntryTypeSchema = exports_external.enum([
|
|
63158
65519
|
"root",
|
|
63159
65520
|
"if-then",
|
|
@@ -63175,7 +65536,7 @@ var init_execution2 = __esm(() => {
|
|
|
63175
65536
|
ScopeStackSchema = exports_external.array(ScopeEntrySchema);
|
|
63176
65537
|
StepResultSchema = exports_external.object({
|
|
63177
65538
|
output: exports_external.unknown(),
|
|
63178
|
-
status:
|
|
65539
|
+
status: StepExecutionStatusSchema2
|
|
63179
65540
|
});
|
|
63180
65541
|
ExecutionContextSchema = exports_external.object({
|
|
63181
65542
|
input: exports_external.record(exports_external.string(), exports_external.unknown()),
|
|
@@ -63203,7 +65564,7 @@ var init_execution2 = __esm(() => {
|
|
|
63203
65564
|
triggerType: exports_external.string(),
|
|
63204
65565
|
triggerInput: exports_external.record(exports_external.string(), exports_external.unknown()).nullable(),
|
|
63205
65566
|
overrides: exports_external.object({ steps: exports_external.record(exports_external.string(), exports_external.record(exports_external.string(), exports_external.unknown())).optional() }).nullable().optional(),
|
|
63206
|
-
status:
|
|
65567
|
+
status: WorkflowExecutionStatusSchema2,
|
|
63207
65568
|
scopeStack: ScopeStackSchema,
|
|
63208
65569
|
currentStepIndex: exports_external.number(),
|
|
63209
65570
|
stepResults: exports_external.record(exports_external.string(), StepResultSchema).optional(),
|
|
@@ -63211,15 +65572,15 @@ var init_execution2 = __esm(() => {
|
|
|
63211
65572
|
error: exports_external.string().nullable(),
|
|
63212
65573
|
priority: exports_external.number().default(50),
|
|
63213
65574
|
leaseId: exports_external.string().nullable(),
|
|
63214
|
-
leaseExpiresAt:
|
|
65575
|
+
leaseExpiresAt: TimestampSchema.nullable(),
|
|
63215
65576
|
workerId: exports_external.string().nullable(),
|
|
63216
65577
|
maxRetries: exports_external.number().default(0),
|
|
63217
65578
|
originalExecutionId: exports_external.string().nullable().optional(),
|
|
63218
65579
|
previousExecutionId: exports_external.string().nullable().optional(),
|
|
63219
65580
|
retryNumber: exports_external.number().default(0),
|
|
63220
|
-
createdAt:
|
|
63221
|
-
startedAt:
|
|
63222
|
-
completedAt:
|
|
65581
|
+
createdAt: TimestampSchema,
|
|
65582
|
+
startedAt: TimestampSchema.nullable(),
|
|
65583
|
+
completedAt: TimestampSchema.nullable(),
|
|
63223
65584
|
createdBy: exports_external.string().nullable()
|
|
63224
65585
|
});
|
|
63225
65586
|
StepExecutionSchema = exports_external.object({
|
|
@@ -63236,12 +65597,12 @@ var init_execution2 = __esm(() => {
|
|
|
63236
65597
|
stepAttempt: exports_external.number().default(0),
|
|
63237
65598
|
inputData: exports_external.unknown().nullable(),
|
|
63238
65599
|
outputData: exports_external.unknown().nullable(),
|
|
63239
|
-
status:
|
|
65600
|
+
status: StepExecutionStatusSchema2,
|
|
63240
65601
|
error: exports_external.string().nullable(),
|
|
63241
65602
|
overrideMode: exports_external.enum(["skipped", "partial"]).nullable().optional(),
|
|
63242
65603
|
durationMs: exports_external.number().nullable(),
|
|
63243
|
-
startedAt:
|
|
63244
|
-
completedAt:
|
|
65604
|
+
startedAt: TimestampSchema.nullable(),
|
|
65605
|
+
completedAt: TimestampSchema.nullable()
|
|
63245
65606
|
});
|
|
63246
65607
|
ConnectorSchema = exports_external.object({
|
|
63247
65608
|
id: exports_external.string(),
|
|
@@ -63252,8 +65613,8 @@ var init_execution2 = __esm(() => {
|
|
|
63252
65613
|
config: exports_external.record(exports_external.string(), exports_external.unknown()),
|
|
63253
65614
|
inputSchema: exports_external.unknown().optional(),
|
|
63254
65615
|
outputSchema: exports_external.unknown().optional(),
|
|
63255
|
-
createdAt:
|
|
63256
|
-
updatedAt:
|
|
65616
|
+
createdAt: TimestampSchema,
|
|
65617
|
+
updatedAt: TimestampSchema.optional(),
|
|
63257
65618
|
createdBy: exports_external.string()
|
|
63258
65619
|
});
|
|
63259
65620
|
WorkflowFileOutputSchema = exports_external.object({
|
|
@@ -63286,7 +65647,9 @@ function inputToJsonSchema(input) {
|
|
|
63286
65647
|
if (itemType === "enum" && input.items?.values?.length) {
|
|
63287
65648
|
return { type: "array", items: { type: "string", enum: input.items.values } };
|
|
63288
65649
|
}
|
|
63289
|
-
|
|
65650
|
+
if (!itemType || itemType === "file")
|
|
65651
|
+
return { type: "array" };
|
|
65652
|
+
return { type: "array", items: { type: itemType } };
|
|
63290
65653
|
}
|
|
63291
65654
|
case "file":
|
|
63292
65655
|
return {};
|
|
@@ -65136,7 +67499,7 @@ function fromBig(n, le = false) {
|
|
|
65136
67499
|
return { h: Number(n & U32_MASK64), l: Number(n >> _32n & U32_MASK64) };
|
|
65137
67500
|
return { h: Number(n >> _32n & U32_MASK64) | 0, l: Number(n & U32_MASK64) | 0 };
|
|
65138
67501
|
}
|
|
65139
|
-
function
|
|
67502
|
+
function split2(lst, le = false) {
|
|
65140
67503
|
const len = lst.length;
|
|
65141
67504
|
let Ah = new Uint32Array(len);
|
|
65142
67505
|
let Al = new Uint32Array(len);
|
|
@@ -65316,7 +67679,7 @@ var init_sha2 = __esm(() => {
|
|
|
65316
67679
|
super(28);
|
|
65317
67680
|
}
|
|
65318
67681
|
};
|
|
65319
|
-
K512 = /* @__PURE__ */ (() =>
|
|
67682
|
+
K512 = /* @__PURE__ */ (() => split2([
|
|
65320
67683
|
"0x428a2f98d728ae22",
|
|
65321
67684
|
"0x7137449123ef65cd",
|
|
65322
67685
|
"0xb5c0fbcfec4d3b2f",
|
|
@@ -65705,11 +68068,11 @@ function walkGrammar(node, parts) {
|
|
|
65705
68068
|
}
|
|
65706
68069
|
return current;
|
|
65707
68070
|
}
|
|
65708
|
-
function normalizeTemplate(
|
|
65709
|
-
return
|
|
68071
|
+
function normalizeTemplate(template2) {
|
|
68072
|
+
return template2.endsWith("/") ? template2.slice(0, -1) : template2;
|
|
65710
68073
|
}
|
|
65711
|
-
function renderTemplate(
|
|
65712
|
-
return normalizeTemplate(
|
|
68074
|
+
function renderTemplate(template2, params) {
|
|
68075
|
+
return normalizeTemplate(template2).split("/").flatMap((part) => {
|
|
65713
68076
|
if (!part.startsWith(":")) {
|
|
65714
68077
|
return [part];
|
|
65715
68078
|
}
|
|
@@ -65724,31 +68087,31 @@ function renderTemplate(template, params) {
|
|
|
65724
68087
|
return [assertSegment(String(name), value)];
|
|
65725
68088
|
});
|
|
65726
68089
|
}
|
|
65727
|
-
function buildS3Path(tenantId,
|
|
68090
|
+
function buildS3Path(tenantId, template2, params) {
|
|
65728
68091
|
const tenant = assertSegment("tenantId", tenantId);
|
|
65729
|
-
const parts = renderTemplate(
|
|
68092
|
+
const parts = renderTemplate(template2, params);
|
|
65730
68093
|
const node = walkGrammar(S3_PATH_GRAMMAR, parts);
|
|
65731
|
-
if (
|
|
65732
|
-
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(
|
|
68094
|
+
if (template2.endsWith("/") && node === PATH_LEAF) {
|
|
68095
|
+
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(template2)}`);
|
|
65733
68096
|
}
|
|
65734
68097
|
const path = ["tenants", tenant, ...parts].join("/");
|
|
65735
|
-
return
|
|
68098
|
+
return template2.endsWith("/") ? `${path}/` : path;
|
|
65736
68099
|
}
|
|
65737
|
-
function buildS3PathSuffix(
|
|
65738
|
-
const parts = renderTemplate(
|
|
68100
|
+
function buildS3PathSuffix(template2, params) {
|
|
68101
|
+
const parts = renderTemplate(template2, params);
|
|
65739
68102
|
const node = walkGrammar(S3_PATH_GRAMMAR, parts);
|
|
65740
|
-
if (
|
|
65741
|
-
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(
|
|
68103
|
+
if (template2.endsWith("/") && node === PATH_LEAF) {
|
|
68104
|
+
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(template2)}`);
|
|
65742
68105
|
}
|
|
65743
68106
|
const path = parts.join("/");
|
|
65744
|
-
return
|
|
68107
|
+
return template2.endsWith("/") ? `${path}/` : path;
|
|
65745
68108
|
}
|
|
65746
68109
|
function stripTenantPrefix(key) {
|
|
65747
68110
|
return key.replace(TENANT_PREFIX_RX, "");
|
|
65748
68111
|
}
|
|
65749
|
-
function matchS3Path(
|
|
68112
|
+
function matchS3Path(template2, key) {
|
|
65750
68113
|
const keyParts = stripTenantPrefix(key).split("/");
|
|
65751
|
-
const templateParts = normalizeTemplate(
|
|
68114
|
+
const templateParts = normalizeTemplate(template2).split("/");
|
|
65752
68115
|
const params = {};
|
|
65753
68116
|
let keyIndex = 0;
|
|
65754
68117
|
for (let templateIndex = 0;templateIndex < templateParts.length; templateIndex += 1) {
|
|
@@ -65801,23 +68164,23 @@ function createBuilder(grammarNode, prefixSegments, boundTenantId) {
|
|
|
65801
68164
|
}
|
|
65802
68165
|
return assertSegment("tenantId", tenantId);
|
|
65803
68166
|
};
|
|
65804
|
-
const build = (
|
|
68167
|
+
const build = (template2, params) => {
|
|
65805
68168
|
const tenant = resolveTenantId(params);
|
|
65806
|
-
const parts = renderTemplate(
|
|
68169
|
+
const parts = renderTemplate(template2, params ?? {});
|
|
65807
68170
|
const node = walkGrammar(grammarNode, parts);
|
|
65808
|
-
if (
|
|
65809
|
-
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(
|
|
68171
|
+
if (template2.endsWith("/") && node === PATH_LEAF) {
|
|
68172
|
+
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(template2)}`);
|
|
65810
68173
|
}
|
|
65811
68174
|
const path = ["tenants", tenant, ...prefixSegments, ...parts].join("/");
|
|
65812
|
-
return
|
|
68175
|
+
return template2.endsWith("/") ? `${path}/` : path;
|
|
65813
68176
|
};
|
|
65814
68177
|
const builder = build;
|
|
65815
|
-
builder.at = (
|
|
68178
|
+
builder.at = (template2, params) => {
|
|
65816
68179
|
const tenant = resolveTenantId(params);
|
|
65817
|
-
const parts = renderTemplate(
|
|
68180
|
+
const parts = renderTemplate(template2, params ?? {});
|
|
65818
68181
|
const nextNode = walkGrammar(grammarNode, parts);
|
|
65819
|
-
if (
|
|
65820
|
-
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(
|
|
68182
|
+
if (template2.endsWith("/") && nextNode === PATH_LEAF) {
|
|
68183
|
+
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(template2)}`);
|
|
65821
68184
|
}
|
|
65822
68185
|
return createBuilder(nextNode, [...prefixSegments, ...parts], tenant);
|
|
65823
68186
|
};
|
|
@@ -66200,7 +68563,7 @@ __export(exports_src, {
|
|
|
66200
68563
|
SplitConfigSchema: () => SplitConfigSchema,
|
|
66201
68564
|
SpanTypes: () => SpanTypes,
|
|
66202
68565
|
SpanKindMap: () => SpanKindMap,
|
|
66203
|
-
SpanKind: () => SpanKind,
|
|
68566
|
+
SpanKind: () => import_api.SpanKind,
|
|
66204
68567
|
SourceVersionRefSchema: () => SourceVersionRefSchema,
|
|
66205
68568
|
SourceSecretsFileSchema: () => SourceSecretsFileSchema,
|
|
66206
68569
|
SourcePackageTypeSchema: () => SourcePackageTypeSchema,
|
|
@@ -66302,7 +68665,7 @@ __export(exports_src, {
|
|
|
66302
68665
|
GPFS_FILE_SOURCE_DESCRIPTOR: () => GPFS_FILE_SOURCE_DESCRIPTOR,
|
|
66303
68666
|
ForeachStepSchema: () => ForeachStepSchema,
|
|
66304
68667
|
FileReferenceSentinelSchema: () => FileReferenceSentinelSchema,
|
|
66305
|
-
FilePathDescriptorSchema: () =>
|
|
68668
|
+
FilePathDescriptorSchema: () => FilePathDescriptorSchema,
|
|
66306
68669
|
FileIngressRefSchema: () => FileIngressRefSchema,
|
|
66307
68670
|
FileIdIngressRefSchema: () => FileIdIngressRefSchema,
|
|
66308
68671
|
FailStepSchema: () => FailStepSchema,
|
|
@@ -66423,8 +68786,8 @@ var init_src = __esm(() => {
|
|
|
66423
68786
|
init_legacy_boundary();
|
|
66424
68787
|
init_runtime_file_ref();
|
|
66425
68788
|
init_scoped_file_ref();
|
|
66426
|
-
|
|
66427
|
-
|
|
68789
|
+
init_processor2();
|
|
68790
|
+
init_parser2();
|
|
66428
68791
|
init_otel();
|
|
66429
68792
|
init_execution_row();
|
|
66430
68793
|
init_run_expand();
|
|
@@ -67337,7 +69700,7 @@ var require_foldFlowLines = __commonJS((exports) => {
|
|
|
67337
69700
|
else
|
|
67338
69701
|
end = lineWidth - indentAtStart;
|
|
67339
69702
|
}
|
|
67340
|
-
let
|
|
69703
|
+
let split3 = undefined;
|
|
67341
69704
|
let prev = undefined;
|
|
67342
69705
|
let overflow = false;
|
|
67343
69706
|
let i = -1;
|
|
@@ -67371,20 +69734,20 @@ var require_foldFlowLines = __commonJS((exports) => {
|
|
|
67371
69734
|
if (mode === FOLD_BLOCK)
|
|
67372
69735
|
i = consumeMoreIndentedLines(text, i, indent.length);
|
|
67373
69736
|
end = i + indent.length + endStep;
|
|
67374
|
-
|
|
69737
|
+
split3 = undefined;
|
|
67375
69738
|
} else {
|
|
67376
69739
|
if (ch === " " && prev && prev !== " " && prev !== `
|
|
67377
69740
|
` && prev !== "\t") {
|
|
67378
69741
|
const next = text[i + 1];
|
|
67379
69742
|
if (next && next !== " " && next !== `
|
|
67380
69743
|
` && next !== "\t")
|
|
67381
|
-
|
|
69744
|
+
split3 = i;
|
|
67382
69745
|
}
|
|
67383
69746
|
if (i >= end) {
|
|
67384
|
-
if (
|
|
67385
|
-
folds.push(
|
|
67386
|
-
end =
|
|
67387
|
-
|
|
69747
|
+
if (split3) {
|
|
69748
|
+
folds.push(split3);
|
|
69749
|
+
end = split3 + endStep;
|
|
69750
|
+
split3 = undefined;
|
|
67388
69751
|
} else if (mode === FOLD_QUOTED) {
|
|
67389
69752
|
while (prev === " " || prev === "\t") {
|
|
67390
69753
|
prev = ch;
|
|
@@ -67397,7 +69760,7 @@ var require_foldFlowLines = __commonJS((exports) => {
|
|
|
67397
69760
|
folds.push(j);
|
|
67398
69761
|
escapedFolds[j] = true;
|
|
67399
69762
|
end = j + endStep;
|
|
67400
|
-
|
|
69763
|
+
split3 = undefined;
|
|
67401
69764
|
} else {
|
|
67402
69765
|
overflow = true;
|
|
67403
69766
|
}
|
|
@@ -68031,7 +70394,7 @@ var require_merge = __commonJS((exports) => {
|
|
|
68031
70394
|
var identity = require_identity();
|
|
68032
70395
|
var Scalar = require_Scalar();
|
|
68033
70396
|
var MERGE_KEY = "<<";
|
|
68034
|
-
var
|
|
70397
|
+
var merge3 = {
|
|
68035
70398
|
identify: (value) => value === MERGE_KEY || typeof value === "symbol" && value.description === MERGE_KEY,
|
|
68036
70399
|
default: "key",
|
|
68037
70400
|
tag: "tag:yaml.org,2002:merge",
|
|
@@ -68041,7 +70404,7 @@ var require_merge = __commonJS((exports) => {
|
|
|
68041
70404
|
}),
|
|
68042
70405
|
stringify: () => MERGE_KEY
|
|
68043
70406
|
};
|
|
68044
|
-
var isMergeKey = (ctx, key) => (
|
|
70407
|
+
var isMergeKey = (ctx, key) => (merge3.identify(key) || identity.isScalar(key) && (!key.type || key.type === Scalar.Scalar.PLAIN) && merge3.identify(key.value)) && ctx?.doc.schema.tags.some((tag) => tag.tag === merge3.tag && tag.default);
|
|
68045
70408
|
function addMergeToJSMap(ctx, map2, value) {
|
|
68046
70409
|
const source = resolveAliasValue(ctx, value);
|
|
68047
70410
|
if (identity.isSeq(source))
|
|
@@ -68080,21 +70443,21 @@ var require_merge = __commonJS((exports) => {
|
|
|
68080
70443
|
}
|
|
68081
70444
|
exports.addMergeToJSMap = addMergeToJSMap;
|
|
68082
70445
|
exports.isMergeKey = isMergeKey;
|
|
68083
|
-
exports.merge =
|
|
70446
|
+
exports.merge = merge3;
|
|
68084
70447
|
});
|
|
68085
70448
|
|
|
68086
70449
|
// node_modules/yaml/dist/nodes/addPairToJSMap.js
|
|
68087
70450
|
var require_addPairToJSMap = __commonJS((exports) => {
|
|
68088
70451
|
var log = require_log();
|
|
68089
|
-
var
|
|
70452
|
+
var merge3 = require_merge();
|
|
68090
70453
|
var stringify = require_stringify();
|
|
68091
70454
|
var identity = require_identity();
|
|
68092
70455
|
var toJS = require_toJS();
|
|
68093
70456
|
function addPairToJSMap(ctx, map2, { key, value }) {
|
|
68094
70457
|
if (identity.isNode(key) && key.addToJSMap)
|
|
68095
70458
|
key.addToJSMap(ctx, map2, value);
|
|
68096
|
-
else if (
|
|
68097
|
-
|
|
70459
|
+
else if (merge3.isMergeKey(ctx, key))
|
|
70460
|
+
merge3.addMergeToJSMap(ctx, map2, value);
|
|
68098
70461
|
else {
|
|
68099
70462
|
const jsKey = toJS.toJS(key, "", ctx);
|
|
68100
70463
|
if (map2 instanceof Map) {
|
|
@@ -69370,7 +71733,7 @@ var require_schema3 = __commonJS((exports) => {
|
|
|
69370
71733
|
var bool = require_bool2();
|
|
69371
71734
|
var float = require_float2();
|
|
69372
71735
|
var int2 = require_int2();
|
|
69373
|
-
var
|
|
71736
|
+
var merge3 = require_merge();
|
|
69374
71737
|
var omap = require_omap();
|
|
69375
71738
|
var pairs = require_pairs();
|
|
69376
71739
|
var set2 = require_set();
|
|
@@ -69390,7 +71753,7 @@ var require_schema3 = __commonJS((exports) => {
|
|
|
69390
71753
|
float.floatExp,
|
|
69391
71754
|
float.float,
|
|
69392
71755
|
binary.binary,
|
|
69393
|
-
|
|
71756
|
+
merge3.merge,
|
|
69394
71757
|
omap.omap,
|
|
69395
71758
|
pairs.pairs,
|
|
69396
71759
|
set2.set,
|
|
@@ -69413,7 +71776,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
69413
71776
|
var schema = require_schema();
|
|
69414
71777
|
var schema$1 = require_schema2();
|
|
69415
71778
|
var binary = require_binary();
|
|
69416
|
-
var
|
|
71779
|
+
var merge3 = require_merge();
|
|
69417
71780
|
var omap = require_omap();
|
|
69418
71781
|
var pairs = require_pairs();
|
|
69419
71782
|
var schema$2 = require_schema3();
|
|
@@ -69438,7 +71801,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
69438
71801
|
intOct: int2.intOct,
|
|
69439
71802
|
intTime: timestamp.intTime,
|
|
69440
71803
|
map: map2.map,
|
|
69441
|
-
merge:
|
|
71804
|
+
merge: merge3.merge,
|
|
69442
71805
|
null: _null4.nullTag,
|
|
69443
71806
|
omap: omap.omap,
|
|
69444
71807
|
pairs: pairs.pairs,
|
|
@@ -69448,7 +71811,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
69448
71811
|
};
|
|
69449
71812
|
var coreKnownTags = {
|
|
69450
71813
|
"tag:yaml.org,2002:binary": binary.binary,
|
|
69451
|
-
"tag:yaml.org,2002:merge":
|
|
71814
|
+
"tag:yaml.org,2002:merge": merge3.merge,
|
|
69452
71815
|
"tag:yaml.org,2002:omap": omap.omap,
|
|
69453
71816
|
"tag:yaml.org,2002:pairs": pairs.pairs,
|
|
69454
71817
|
"tag:yaml.org,2002:set": set2.set,
|
|
@@ -69457,7 +71820,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
69457
71820
|
function getTags(customTags, schemaName, addMergeTag) {
|
|
69458
71821
|
const schemaTags = schemas3.get(schemaName);
|
|
69459
71822
|
if (schemaTags && !customTags) {
|
|
69460
|
-
return addMergeTag && !schemaTags.includes(
|
|
71823
|
+
return addMergeTag && !schemaTags.includes(merge3.merge) ? schemaTags.concat(merge3.merge) : schemaTags.slice();
|
|
69461
71824
|
}
|
|
69462
71825
|
let tags = schemaTags;
|
|
69463
71826
|
if (!tags) {
|
|
@@ -69475,7 +71838,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
69475
71838
|
tags = customTags(tags.slice());
|
|
69476
71839
|
}
|
|
69477
71840
|
if (addMergeTag)
|
|
69478
|
-
tags = tags.concat(
|
|
71841
|
+
tags = tags.concat(merge3.merge);
|
|
69479
71842
|
return tags.reduce((tags2, tag) => {
|
|
69480
71843
|
const tagObj = typeof tag === "string" ? tagsByName[tag] : tag;
|
|
69481
71844
|
if (!tagObj) {
|
|
@@ -69502,11 +71865,11 @@ var require_Schema = __commonJS((exports) => {
|
|
|
69502
71865
|
var sortMapEntriesByKey = (a, b) => a.key < b.key ? -1 : a.key > b.key ? 1 : 0;
|
|
69503
71866
|
|
|
69504
71867
|
class Schema {
|
|
69505
|
-
constructor({ compat: compat2, customTags, merge:
|
|
71868
|
+
constructor({ compat: compat2, customTags, merge: merge3, resolveKnownTags, schema, sortMapEntries, toStringDefaults }) {
|
|
69506
71869
|
this.compat = Array.isArray(compat2) ? tags.getTags(compat2, "compat") : compat2 ? tags.getTags(null, compat2) : null;
|
|
69507
71870
|
this.name = typeof schema === "string" && schema || "core";
|
|
69508
71871
|
this.knownTags = resolveKnownTags ? tags.coreKnownTags : {};
|
|
69509
|
-
this.tags = tags.getTags(customTags, this.name,
|
|
71872
|
+
this.tags = tags.getTags(customTags, this.name, merge3);
|
|
69510
71873
|
this.toStringOptions = toStringDefaults ?? null;
|
|
69511
71874
|
Object.defineProperty(this, identity.MAP, { value: map2.map });
|
|
69512
71875
|
Object.defineProperty(this, identity.SCALAR, { value: string4.string });
|
|
@@ -70729,13 +73092,13 @@ var require_resolve_block_scalar = __commonJS((exports) => {
|
|
|
70729
73092
|
return { mode, indent, chomp, comment, length };
|
|
70730
73093
|
}
|
|
70731
73094
|
function splitLines(source) {
|
|
70732
|
-
const
|
|
70733
|
-
const first =
|
|
73095
|
+
const split3 = source.split(/\n( *)/);
|
|
73096
|
+
const first = split3[0];
|
|
70734
73097
|
const m = first.match(/^( *)/);
|
|
70735
73098
|
const line0 = m?.[1] ? [m[1], first.slice(m[1].length)] : ["", first];
|
|
70736
73099
|
const lines = [line0];
|
|
70737
|
-
for (let i = 1;i <
|
|
70738
|
-
lines.push([
|
|
73100
|
+
for (let i = 1;i < split3.length; i += 2)
|
|
73101
|
+
lines.push([split3[i], split3[i + 1]]);
|
|
70739
73102
|
return lines;
|
|
70740
73103
|
}
|
|
70741
73104
|
exports.resolveBlockScalar = resolveBlockScalar;
|
|
@@ -73749,7 +76112,7 @@ var init_main = __esm(() => {
|
|
|
73749
76112
|
});
|
|
73750
76113
|
|
|
73751
76114
|
// ../../node_modules/sisteransi/src/index.js
|
|
73752
|
-
var
|
|
76115
|
+
var require_src2 = __commonJS((exports, module) => {
|
|
73753
76116
|
var ESC2 = "\x1B";
|
|
73754
76117
|
var CSI2 = `${ESC2}[`;
|
|
73755
76118
|
var beep = "\x07";
|
|
@@ -74092,7 +76455,7 @@ var import_sisteransi, G, K, h, Y, k, A = (r) => ("columns" in r) && typeof r.co
|
|
|
74092
76455
|
}, Q, X, Z, et, it, rt, nt, ot, ut, at, ht;
|
|
74093
76456
|
var init_dist3 = __esm(() => {
|
|
74094
76457
|
init_main();
|
|
74095
|
-
import_sisteransi = __toESM(
|
|
76458
|
+
import_sisteransi = __toESM(require_src2(), 1);
|
|
74096
76459
|
G = ["up", "down", "left", "right", "space", "enter", "cancel"];
|
|
74097
76460
|
K = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
|
|
74098
76461
|
h = { actions: new Set(G), aliases: new Map([["k", "up"], ["j", "down"], ["h", "left"], ["l", "right"], ["\x03", "cancel"], ["escape", "cancel"]]), messages: { cancel: "Canceled", error: "Something went wrong" }, withGuide: true, date: { monthNames: [...K], messages: { required: "Please enter a valid date", invalidMonth: "There are only 12 months in a year", invalidDay: (r, t) => `There are only ${r} days in ${t}`, afterMin: (r) => `Date must be on or after ${r.toISOString().slice(0, 10)}`, beforeMax: (r) => `Date must be on or before ${r.toISOString().slice(0, 10)}` } } };
|
|
@@ -75435,7 +77798,7 @@ var init_dist4 = __esm(() => {
|
|
|
75435
77798
|
init_dist3();
|
|
75436
77799
|
init_main();
|
|
75437
77800
|
init_dist2();
|
|
75438
|
-
import_sisteransi2 = __toESM(
|
|
77801
|
+
import_sisteransi2 = __toESM(require_src2(), 1);
|
|
75439
77802
|
tt2 = te();
|
|
75440
77803
|
_t = w2("◆", "*");
|
|
75441
77804
|
ot2 = w2("■", "x");
|
|
@@ -168927,7 +171290,7 @@ var require3, __filename2, __dirname2, __create2, __defProp3, __getOwnPropDesc,
|
|
|
168927
171290
|
__defProp3(to5, key2, { get: () => from[key2], enumerable: !(desc = __getOwnPropDesc(from, key2)) || desc.enumerable });
|
|
168928
171291
|
}
|
|
168929
171292
|
return to5;
|
|
168930
|
-
}, __toESM2 = (mod, isNodeMode, target) => (target = mod != null ? __create2(__getProtoOf2(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp3(target, "default", { value: mod, enumerable: true }) : target, mod)), require_array, require_errno, require_fs, require_path, require_is_extglob, require_is_glob, require_glob_parent,
|
|
171293
|
+
}, __toESM2 = (mod, isNodeMode, target) => (target = mod != null ? __create2(__getProtoOf2(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp3(target, "default", { value: mod, enumerable: true }) : target, mod)), require_array, require_errno, require_fs, require_path, require_is_extglob, require_is_glob, require_glob_parent, require_utils4, require_stringify2, require_is_number, require_to_regex_range, require_fill_range, require_compile2, require_expand, require_constants, require_parse, require_braces, require_constants2, require_utils22, require_scan, require_parse2, require_picomatch, require_picomatch2, require_micromatch, require_pattern2, require_merge2, require_stream, require_string2, require_utils32, require_tasks, require_async, require_sync, require_fs2, require_settings, require_out, require_queue_microtask, require_run_parallel, require_constants3, require_fs3, require_utils42, require_common, require_async2, require_sync2, require_fs4, require_settings2, require_out2, require_reusify, require_queue, require_common2, require_reader, require_async3, require_async4, require_stream2, require_sync3, require_sync4, require_settings3, require_out3, require_reader2, require_stream3, require_async5, require_matcher, require_partial, require_deep, require_entry, require_error2, require_entry2, require_provider, require_async6, require_stream4, require_sync5, require_sync6, require_settings4, require_out4, require_picocolors2, require_debug, require_constants4, require_re, require_parse_options, require_identifiers, require_semver2, require_compare, require_gte, require_pseudomap, require_map2, require_yallist, require_lru_cache, require_sigmund, require_fnmatch, require_ini, require_package, require_src3, require_js_tokens, require_readlines, require_ignore, index_exports, Diff = class {
|
|
168931
171294
|
diff(oldStr, newStr, options8 = {}) {
|
|
168932
171295
|
let callback;
|
|
168933
171296
|
if (typeof options8 === "function") {
|
|
@@ -169949,7 +172312,7 @@ var init_prettier = __esm(() => {
|
|
|
169949
172312
|
};
|
|
169950
172313
|
}
|
|
169951
172314
|
});
|
|
169952
|
-
|
|
172315
|
+
require_utils4 = __commonJS2({
|
|
169953
172316
|
"node_modules/braces/lib/utils.js"(exports) {
|
|
169954
172317
|
exports.isInteger = (num) => {
|
|
169955
172318
|
if (typeof num === "number") {
|
|
@@ -170038,7 +172401,7 @@ var init_prettier = __esm(() => {
|
|
|
170038
172401
|
});
|
|
170039
172402
|
require_stringify2 = __commonJS2({
|
|
170040
172403
|
"node_modules/braces/lib/stringify.js"(exports, module) {
|
|
170041
|
-
var utils2 =
|
|
172404
|
+
var utils2 = require_utils4();
|
|
170042
172405
|
module.exports = (ast, options8 = {}) => {
|
|
170043
172406
|
const stringify2 = (node, parent = {}) => {
|
|
170044
172407
|
const invalidBlock = options8.escapeInvalid && utils2.isInvalidBrace(parent);
|
|
@@ -170492,7 +172855,7 @@ var init_prettier = __esm(() => {
|
|
|
170492
172855
|
require_compile2 = __commonJS2({
|
|
170493
172856
|
"node_modules/braces/lib/compile.js"(exports, module) {
|
|
170494
172857
|
var fill2 = require_fill_range();
|
|
170495
|
-
var utils2 =
|
|
172858
|
+
var utils2 = require_utils4();
|
|
170496
172859
|
var compile = (ast, options8 = {}) => {
|
|
170497
172860
|
const walk2 = (node, parent = {}) => {
|
|
170498
172861
|
const invalidBlock = utils2.isInvalidBrace(parent);
|
|
@@ -170542,7 +172905,7 @@ var init_prettier = __esm(() => {
|
|
|
170542
172905
|
"node_modules/braces/lib/expand.js"(exports, module) {
|
|
170543
172906
|
var fill2 = require_fill_range();
|
|
170544
172907
|
var stringify2 = require_stringify2();
|
|
170545
|
-
var utils2 =
|
|
172908
|
+
var utils2 = require_utils4();
|
|
170546
172909
|
var append = (queue = "", stash = "", enclose = false) => {
|
|
170547
172910
|
const result = [];
|
|
170548
172911
|
queue = [].concat(queue);
|
|
@@ -172741,8 +175104,8 @@ var init_prettier = __esm(() => {
|
|
|
172741
175104
|
var Stream = __require2("stream");
|
|
172742
175105
|
var PassThrough = Stream.PassThrough;
|
|
172743
175106
|
var slice = Array.prototype.slice;
|
|
172744
|
-
module.exports =
|
|
172745
|
-
function
|
|
175107
|
+
module.exports = merge22;
|
|
175108
|
+
function merge22() {
|
|
172746
175109
|
const streamsQueue = [];
|
|
172747
175110
|
const args = slice.call(arguments);
|
|
172748
175111
|
let merging = false;
|
|
@@ -172856,9 +175219,9 @@ var init_prettier = __esm(() => {
|
|
|
172856
175219
|
"node_modules/fast-glob/out/utils/stream.js"(exports) {
|
|
172857
175220
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
172858
175221
|
exports.merge = undefined;
|
|
172859
|
-
var
|
|
175222
|
+
var merge22 = require_merge2();
|
|
172860
175223
|
function merge3(streams) {
|
|
172861
|
-
const mergedStream =
|
|
175224
|
+
const mergedStream = merge22(streams);
|
|
172862
175225
|
streams.forEach((stream) => {
|
|
172863
175226
|
stream.once("error", (error52) => mergedStream.emit("error", error52));
|
|
172864
175227
|
});
|
|
@@ -172886,7 +175249,7 @@ var init_prettier = __esm(() => {
|
|
|
172886
175249
|
exports.isEmpty = isEmpty;
|
|
172887
175250
|
}
|
|
172888
175251
|
});
|
|
172889
|
-
|
|
175252
|
+
require_utils32 = __commonJS2({
|
|
172890
175253
|
"node_modules/fast-glob/out/utils/index.js"(exports) {
|
|
172891
175254
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
172892
175255
|
exports.string = exports.stream = exports.pattern = exports.path = exports.fs = exports.errno = exports.array = undefined;
|
|
@@ -172910,7 +175273,7 @@ var init_prettier = __esm(() => {
|
|
|
172910
175273
|
"node_modules/fast-glob/out/managers/tasks.js"(exports) {
|
|
172911
175274
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
172912
175275
|
exports.convertPatternGroupToTask = exports.convertPatternGroupsToTasks = exports.groupPatternsByBaseDirectory = exports.getNegativePatternsAsPositive = exports.getPositivePatterns = exports.convertPatternsToTasks = exports.generate = undefined;
|
|
172913
|
-
var utils2 =
|
|
175276
|
+
var utils2 = require_utils32();
|
|
172914
175277
|
function generate(input, settings) {
|
|
172915
175278
|
const patterns = processPatterns(input, settings);
|
|
172916
175279
|
const ignore = processPatterns(settings.ignore, settings);
|
|
@@ -173219,7 +175582,7 @@ var init_prettier = __esm(() => {
|
|
|
173219
175582
|
exports.createDirentFromStats = createDirentFromStats;
|
|
173220
175583
|
}
|
|
173221
175584
|
});
|
|
173222
|
-
|
|
175585
|
+
require_utils42 = __commonJS2({
|
|
173223
175586
|
"node_modules/@nodelib/fs.scandir/out/utils/index.js"(exports) {
|
|
173224
175587
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
173225
175588
|
exports.fs = undefined;
|
|
@@ -173247,7 +175610,7 @@ var init_prettier = __esm(() => {
|
|
|
173247
175610
|
var fsStat = require_out();
|
|
173248
175611
|
var rpl = require_run_parallel();
|
|
173249
175612
|
var constants_1 = require_constants3();
|
|
173250
|
-
var utils2 =
|
|
175613
|
+
var utils2 = require_utils42();
|
|
173251
175614
|
var common = require_common();
|
|
173252
175615
|
function read3(directory, settings, callback) {
|
|
173253
175616
|
if (!settings.stats && constants_1.IS_SUPPORT_READDIR_WITH_FILE_TYPES) {
|
|
@@ -173353,7 +175716,7 @@ var init_prettier = __esm(() => {
|
|
|
173353
175716
|
exports.readdir = exports.readdirWithFileTypes = exports.read = undefined;
|
|
173354
175717
|
var fsStat = require_out();
|
|
173355
175718
|
var constants_1 = require_constants3();
|
|
173356
|
-
var utils2 =
|
|
175719
|
+
var utils2 = require_utils42();
|
|
173357
175720
|
var common = require_common();
|
|
173358
175721
|
function read3(directory, settings) {
|
|
173359
175722
|
if (!settings.stats && constants_1.IS_SUPPORT_READDIR_WITH_FILE_TYPES) {
|
|
@@ -174133,7 +176496,7 @@ var init_prettier = __esm(() => {
|
|
|
174133
176496
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
174134
176497
|
var path15 = __require2("path");
|
|
174135
176498
|
var fsStat = require_out();
|
|
174136
|
-
var utils2 =
|
|
176499
|
+
var utils2 = require_utils32();
|
|
174137
176500
|
var Reader = class {
|
|
174138
176501
|
constructor(_settings) {
|
|
174139
176502
|
this._settings = _settings;
|
|
@@ -174257,7 +176620,7 @@ var init_prettier = __esm(() => {
|
|
|
174257
176620
|
require_matcher = __commonJS2({
|
|
174258
176621
|
"node_modules/fast-glob/out/providers/matchers/matcher.js"(exports) {
|
|
174259
176622
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
174260
|
-
var utils2 =
|
|
176623
|
+
var utils2 = require_utils32();
|
|
174261
176624
|
var Matcher = class {
|
|
174262
176625
|
constructor(_patterns, _settings, _micromatchOptions) {
|
|
174263
176626
|
this._patterns = _patterns;
|
|
@@ -174339,7 +176702,7 @@ var init_prettier = __esm(() => {
|
|
|
174339
176702
|
require_deep = __commonJS2({
|
|
174340
176703
|
"node_modules/fast-glob/out/providers/filters/deep.js"(exports) {
|
|
174341
176704
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
174342
|
-
var utils2 =
|
|
176705
|
+
var utils2 = require_utils32();
|
|
174343
176706
|
var partial_1 = require_partial();
|
|
174344
176707
|
var DeepFilter = class {
|
|
174345
176708
|
constructor(_settings, _micromatchOptions) {
|
|
@@ -174401,7 +176764,7 @@ var init_prettier = __esm(() => {
|
|
|
174401
176764
|
require_entry = __commonJS2({
|
|
174402
176765
|
"node_modules/fast-glob/out/providers/filters/entry.js"(exports) {
|
|
174403
176766
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
174404
|
-
var utils2 =
|
|
176767
|
+
var utils2 = require_utils32();
|
|
174405
176768
|
var EntryFilter = class {
|
|
174406
176769
|
constructor(_settings, _micromatchOptions) {
|
|
174407
176770
|
this._settings = _settings;
|
|
@@ -174486,7 +176849,7 @@ var init_prettier = __esm(() => {
|
|
|
174486
176849
|
require_error2 = __commonJS2({
|
|
174487
176850
|
"node_modules/fast-glob/out/providers/filters/error.js"(exports) {
|
|
174488
176851
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
174489
|
-
var utils2 =
|
|
176852
|
+
var utils2 = require_utils32();
|
|
174490
176853
|
var ErrorFilter = class {
|
|
174491
176854
|
constructor(_settings) {
|
|
174492
176855
|
this._settings = _settings;
|
|
@@ -174504,7 +176867,7 @@ var init_prettier = __esm(() => {
|
|
|
174504
176867
|
require_entry2 = __commonJS2({
|
|
174505
176868
|
"node_modules/fast-glob/out/providers/transformers/entry.js"(exports) {
|
|
174506
176869
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
174507
|
-
var utils2 =
|
|
176870
|
+
var utils2 = require_utils32();
|
|
174508
176871
|
var EntryTransformer = class {
|
|
174509
176872
|
constructor(_settings) {
|
|
174510
176873
|
this._settings = _settings;
|
|
@@ -174772,7 +177135,7 @@ var init_prettier = __esm(() => {
|
|
|
174772
177135
|
var stream_1 = require_stream4();
|
|
174773
177136
|
var sync_1 = require_sync6();
|
|
174774
177137
|
var settings_1 = require_settings4();
|
|
174775
|
-
var utils2 =
|
|
177138
|
+
var utils2 = require_utils32();
|
|
174776
177139
|
async function FastGlob(source2, options8) {
|
|
174777
177140
|
assertPatternsInput(source2);
|
|
174778
177141
|
const works = getWorks(source2, async_1.default, options8);
|
|
@@ -175090,7 +177453,7 @@ var init_prettier = __esm(() => {
|
|
|
175090
177453
|
};
|
|
175091
177454
|
}
|
|
175092
177455
|
});
|
|
175093
|
-
|
|
177456
|
+
require_semver2 = __commonJS2({
|
|
175094
177457
|
"node_modules/semver/classes/semver.js"(exports, module) {
|
|
175095
177458
|
var debug = require_debug();
|
|
175096
177459
|
var { MAX_LENGTH, MAX_SAFE_INTEGER } = require_constants4();
|
|
@@ -175360,7 +177723,7 @@ var init_prettier = __esm(() => {
|
|
|
175360
177723
|
});
|
|
175361
177724
|
require_compare = __commonJS2({
|
|
175362
177725
|
"node_modules/semver/functions/compare.js"(exports, module) {
|
|
175363
|
-
var SemVer =
|
|
177726
|
+
var SemVer = require_semver2();
|
|
175364
177727
|
var compare = (a5, b8, loose) => new SemVer(a5, loose).compare(new SemVer(b8, loose));
|
|
175365
177728
|
module.exports = compare;
|
|
175366
177729
|
}
|
|
@@ -177093,7 +179456,7 @@ globstar while`, file2, fr10, pattern, pr8, swallowee);
|
|
|
177093
179456
|
};
|
|
177094
179457
|
}
|
|
177095
179458
|
});
|
|
177096
|
-
|
|
179459
|
+
require_src3 = __commonJS2({
|
|
177097
179460
|
"node_modules/editorconfig/src/index.js"(exports) {
|
|
177098
179461
|
var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P9, generator) {
|
|
177099
179462
|
return new (P9 || (P9 = Promise))(function(resolve32, reject) {
|
|
@@ -178556,7 +180919,7 @@ globstar while`, file2, fr10, pattern, pr8, swallowee);
|
|
|
178556
180919
|
mockable_default = mockable.mocked;
|
|
178557
180920
|
import_micromatch = __toESM2(require_micromatch(), 1);
|
|
178558
180921
|
partition_default = partition2;
|
|
178559
|
-
import_editorconfig = __toESM2(
|
|
180922
|
+
import_editorconfig = __toESM2(require_src3(), 1);
|
|
178560
180923
|
iterate_directory_up_default = iterateDirectoryUp;
|
|
178561
180924
|
FileSearcher = class extends Searcher {
|
|
178562
180925
|
findInDirectory = findFile;
|
|
@@ -182027,7 +184390,7 @@ var require_foldFlowLines2 = __commonJS((exports) => {
|
|
|
182027
184390
|
else
|
|
182028
184391
|
end = lineWidth - indentAtStart;
|
|
182029
184392
|
}
|
|
182030
|
-
let
|
|
184393
|
+
let split3 = undefined;
|
|
182031
184394
|
let prev = undefined;
|
|
182032
184395
|
let overflow = false;
|
|
182033
184396
|
let i5 = -1;
|
|
@@ -182061,20 +184424,20 @@ var require_foldFlowLines2 = __commonJS((exports) => {
|
|
|
182061
184424
|
if (mode === FOLD_BLOCK)
|
|
182062
184425
|
i5 = consumeMoreIndentedLines(text, i5, indent3.length);
|
|
182063
184426
|
end = i5 + indent3.length + endStep;
|
|
182064
|
-
|
|
184427
|
+
split3 = undefined;
|
|
182065
184428
|
} else {
|
|
182066
184429
|
if (ch2 === " " && prev && prev !== " " && prev !== `
|
|
182067
184430
|
` && prev !== "\t") {
|
|
182068
184431
|
const next = text[i5 + 1];
|
|
182069
184432
|
if (next && next !== " " && next !== `
|
|
182070
184433
|
` && next !== "\t")
|
|
182071
|
-
|
|
184434
|
+
split3 = i5;
|
|
182072
184435
|
}
|
|
182073
184436
|
if (i5 >= end) {
|
|
182074
|
-
if (
|
|
182075
|
-
folds.push(
|
|
182076
|
-
end =
|
|
182077
|
-
|
|
184437
|
+
if (split3) {
|
|
184438
|
+
folds.push(split3);
|
|
184439
|
+
end = split3 + endStep;
|
|
184440
|
+
split3 = undefined;
|
|
182078
184441
|
} else if (mode === FOLD_QUOTED) {
|
|
182079
184442
|
while (prev === " " || prev === "\t") {
|
|
182080
184443
|
prev = ch2;
|
|
@@ -182087,7 +184450,7 @@ var require_foldFlowLines2 = __commonJS((exports) => {
|
|
|
182087
184450
|
folds.push(j11);
|
|
182088
184451
|
escapedFolds[j11] = true;
|
|
182089
184452
|
end = j11 + endStep;
|
|
182090
|
-
|
|
184453
|
+
split3 = undefined;
|
|
182091
184454
|
} else {
|
|
182092
184455
|
overflow = true;
|
|
182093
184456
|
}
|
|
@@ -182721,7 +185084,7 @@ var require_merge3 = __commonJS((exports) => {
|
|
|
182721
185084
|
var identity = require_identity2();
|
|
182722
185085
|
var Scalar = require_Scalar2();
|
|
182723
185086
|
var MERGE_KEY = "<<";
|
|
182724
|
-
var
|
|
185087
|
+
var merge3 = {
|
|
182725
185088
|
identify: (value) => value === MERGE_KEY || typeof value === "symbol" && value.description === MERGE_KEY,
|
|
182726
185089
|
default: "key",
|
|
182727
185090
|
tag: "tag:yaml.org,2002:merge",
|
|
@@ -182731,7 +185094,7 @@ var require_merge3 = __commonJS((exports) => {
|
|
|
182731
185094
|
}),
|
|
182732
185095
|
stringify: () => MERGE_KEY
|
|
182733
185096
|
};
|
|
182734
|
-
var isMergeKey = (ctx, key2) => (
|
|
185097
|
+
var isMergeKey = (ctx, key2) => (merge3.identify(key2) || identity.isScalar(key2) && (!key2.type || key2.type === Scalar.Scalar.PLAIN) && merge3.identify(key2.value)) && ctx?.doc.schema.tags.some((tag) => tag.tag === merge3.tag && tag.default);
|
|
182735
185098
|
function addMergeToJSMap(ctx, map2, value) {
|
|
182736
185099
|
const source2 = resolveAliasValue(ctx, value);
|
|
182737
185100
|
if (identity.isSeq(source2))
|
|
@@ -182770,21 +185133,21 @@ var require_merge3 = __commonJS((exports) => {
|
|
|
182770
185133
|
}
|
|
182771
185134
|
exports.addMergeToJSMap = addMergeToJSMap;
|
|
182772
185135
|
exports.isMergeKey = isMergeKey;
|
|
182773
|
-
exports.merge =
|
|
185136
|
+
exports.merge = merge3;
|
|
182774
185137
|
});
|
|
182775
185138
|
|
|
182776
185139
|
// ../workflow-yaml/node_modules/yaml/dist/nodes/addPairToJSMap.js
|
|
182777
185140
|
var require_addPairToJSMap2 = __commonJS((exports) => {
|
|
182778
185141
|
var log = require_log2();
|
|
182779
|
-
var
|
|
185142
|
+
var merge3 = require_merge3();
|
|
182780
185143
|
var stringify = require_stringify3();
|
|
182781
185144
|
var identity = require_identity2();
|
|
182782
185145
|
var toJS = require_toJS2();
|
|
182783
185146
|
function addPairToJSMap(ctx, map2, { key: key2, value }) {
|
|
182784
185147
|
if (identity.isNode(key2) && key2.addToJSMap)
|
|
182785
185148
|
key2.addToJSMap(ctx, map2, value);
|
|
182786
|
-
else if (
|
|
182787
|
-
|
|
185149
|
+
else if (merge3.isMergeKey(ctx, key2))
|
|
185150
|
+
merge3.addMergeToJSMap(ctx, map2, value);
|
|
182788
185151
|
else {
|
|
182789
185152
|
const jsKey = toJS.toJS(key2, "", ctx);
|
|
182790
185153
|
if (map2 instanceof Map) {
|
|
@@ -184060,7 +186423,7 @@ var require_schema6 = __commonJS((exports) => {
|
|
|
184060
186423
|
var bool = require_bool4();
|
|
184061
186424
|
var float = require_float4();
|
|
184062
186425
|
var int2 = require_int4();
|
|
184063
|
-
var
|
|
186426
|
+
var merge3 = require_merge3();
|
|
184064
186427
|
var omap = require_omap2();
|
|
184065
186428
|
var pairs = require_pairs2();
|
|
184066
186429
|
var set2 = require_set2();
|
|
@@ -184080,7 +186443,7 @@ var require_schema6 = __commonJS((exports) => {
|
|
|
184080
186443
|
float.floatExp,
|
|
184081
186444
|
float.float,
|
|
184082
186445
|
binary.binary,
|
|
184083
|
-
|
|
186446
|
+
merge3.merge,
|
|
184084
186447
|
omap.omap,
|
|
184085
186448
|
pairs.pairs,
|
|
184086
186449
|
set2.set,
|
|
@@ -184103,7 +186466,7 @@ var require_tags2 = __commonJS((exports) => {
|
|
|
184103
186466
|
var schema = require_schema4();
|
|
184104
186467
|
var schema$1 = require_schema5();
|
|
184105
186468
|
var binary = require_binary2();
|
|
184106
|
-
var
|
|
186469
|
+
var merge3 = require_merge3();
|
|
184107
186470
|
var omap = require_omap2();
|
|
184108
186471
|
var pairs = require_pairs2();
|
|
184109
186472
|
var schema$2 = require_schema6();
|
|
@@ -184128,7 +186491,7 @@ var require_tags2 = __commonJS((exports) => {
|
|
|
184128
186491
|
intOct: int2.intOct,
|
|
184129
186492
|
intTime: timestamp.intTime,
|
|
184130
186493
|
map: map2.map,
|
|
184131
|
-
merge:
|
|
186494
|
+
merge: merge3.merge,
|
|
184132
186495
|
null: _null4.nullTag,
|
|
184133
186496
|
omap: omap.omap,
|
|
184134
186497
|
pairs: pairs.pairs,
|
|
@@ -184138,7 +186501,7 @@ var require_tags2 = __commonJS((exports) => {
|
|
|
184138
186501
|
};
|
|
184139
186502
|
var coreKnownTags = {
|
|
184140
186503
|
"tag:yaml.org,2002:binary": binary.binary,
|
|
184141
|
-
"tag:yaml.org,2002:merge":
|
|
186504
|
+
"tag:yaml.org,2002:merge": merge3.merge,
|
|
184142
186505
|
"tag:yaml.org,2002:omap": omap.omap,
|
|
184143
186506
|
"tag:yaml.org,2002:pairs": pairs.pairs,
|
|
184144
186507
|
"tag:yaml.org,2002:set": set2.set,
|
|
@@ -184147,7 +186510,7 @@ var require_tags2 = __commonJS((exports) => {
|
|
|
184147
186510
|
function getTags(customTags, schemaName, addMergeTag) {
|
|
184148
186511
|
const schemaTags = schemas3.get(schemaName);
|
|
184149
186512
|
if (schemaTags && !customTags) {
|
|
184150
|
-
return addMergeTag && !schemaTags.includes(
|
|
186513
|
+
return addMergeTag && !schemaTags.includes(merge3.merge) ? schemaTags.concat(merge3.merge) : schemaTags.slice();
|
|
184151
186514
|
}
|
|
184152
186515
|
let tags = schemaTags;
|
|
184153
186516
|
if (!tags) {
|
|
@@ -184165,7 +186528,7 @@ var require_tags2 = __commonJS((exports) => {
|
|
|
184165
186528
|
tags = customTags(tags.slice());
|
|
184166
186529
|
}
|
|
184167
186530
|
if (addMergeTag)
|
|
184168
|
-
tags = tags.concat(
|
|
186531
|
+
tags = tags.concat(merge3.merge);
|
|
184169
186532
|
return tags.reduce((tags2, tag) => {
|
|
184170
186533
|
const tagObj = typeof tag === "string" ? tagsByName[tag] : tag;
|
|
184171
186534
|
if (!tagObj) {
|
|
@@ -184192,11 +186555,11 @@ var require_Schema2 = __commonJS((exports) => {
|
|
|
184192
186555
|
var sortMapEntriesByKey = (a5, b8) => a5.key < b8.key ? -1 : a5.key > b8.key ? 1 : 0;
|
|
184193
186556
|
|
|
184194
186557
|
class Schema2 {
|
|
184195
|
-
constructor({ compat: compat2, customTags, merge:
|
|
186558
|
+
constructor({ compat: compat2, customTags, merge: merge3, resolveKnownTags, schema, sortMapEntries, toStringDefaults }) {
|
|
184196
186559
|
this.compat = Array.isArray(compat2) ? tags.getTags(compat2, "compat") : compat2 ? tags.getTags(null, compat2) : null;
|
|
184197
186560
|
this.name = typeof schema === "string" && schema || "core";
|
|
184198
186561
|
this.knownTags = resolveKnownTags ? tags.coreKnownTags : {};
|
|
184199
|
-
this.tags = tags.getTags(customTags, this.name,
|
|
186562
|
+
this.tags = tags.getTags(customTags, this.name, merge3);
|
|
184200
186563
|
this.toStringOptions = toStringDefaults ?? null;
|
|
184201
186564
|
Object.defineProperty(this, identity.MAP, { value: map2.map });
|
|
184202
186565
|
Object.defineProperty(this, identity.SCALAR, { value: string4.string });
|
|
@@ -185419,13 +187782,13 @@ var require_resolve_block_scalar2 = __commonJS((exports) => {
|
|
|
185419
187782
|
return { mode, indent: indent3, chomp, comment, length };
|
|
185420
187783
|
}
|
|
185421
187784
|
function splitLines2(source2) {
|
|
185422
|
-
const
|
|
185423
|
-
const first =
|
|
187785
|
+
const split3 = source2.split(/\n( *)/);
|
|
187786
|
+
const first = split3[0];
|
|
185424
187787
|
const m7 = first.match(/^( *)/);
|
|
185425
187788
|
const line0 = m7?.[1] ? [m7[1], first.slice(m7[1].length)] : ["", first];
|
|
185426
187789
|
const lines = [line0];
|
|
185427
|
-
for (let i5 = 1;i5 <
|
|
185428
|
-
lines.push([
|
|
187790
|
+
for (let i5 = 1;i5 < split3.length; i5 += 2)
|
|
187791
|
+
lines.push([split3[i5], split3[i5 + 1]]);
|
|
185429
187792
|
return lines;
|
|
185430
187793
|
}
|
|
185431
187794
|
exports.resolveBlockScalar = resolveBlockScalar;
|
|
@@ -188073,7 +190436,7 @@ import { fileURLToPath as fileURLToPath8 } from "url";
|
|
|
188073
190436
|
// package.json
|
|
188074
190437
|
var package_default = {
|
|
188075
190438
|
name: "@eigenpal/cli",
|
|
188076
|
-
version: "0.10.
|
|
190439
|
+
version: "0.10.7",
|
|
188077
190440
|
description: "Eigenpal CLI — author and run document workflows from your terminal. Agent-ready.",
|
|
188078
190441
|
keywords: [
|
|
188079
190442
|
"eigenpal",
|
|
@@ -189590,7 +191953,7 @@ async function pushCurrentBranch(input) {
|
|
|
189590
191953
|
function slugifyPackageSegment(value) {
|
|
189591
191954
|
return value.trim().toLowerCase().replace(/[^a-z0-9_-]+/g, "-").replace(/^-+|-+$/g, "");
|
|
189592
191955
|
}
|
|
189593
|
-
function packagePathForTemplate(
|
|
191956
|
+
function packagePathForTemplate(template2, name) {
|
|
189594
191957
|
const slug = slugifyPackageSegment(name);
|
|
189595
191958
|
if (!slug)
|
|
189596
191959
|
throw new Error("Package name must include at least one letter or number.");
|
|
@@ -189602,7 +191965,7 @@ function packagePathForTemplate(template, name) {
|
|
|
189602
191965
|
knowledge: "resources/knowledge",
|
|
189603
191966
|
evaluator: "evaluators"
|
|
189604
191967
|
};
|
|
189605
|
-
const root = rootByTemplate[
|
|
191968
|
+
const root = rootByTemplate[template2];
|
|
189606
191969
|
if (!root)
|
|
189607
191970
|
throw new Error("Template must be agent, workflow, skill, rule, knowledge, or evaluator.");
|
|
189608
191971
|
return SourcePackagePathSchema.parse(`${root}/${slug}`);
|
|
@@ -190011,12 +192374,12 @@ function archivePackage(input) {
|
|
|
190011
192374
|
runGit(["archive", "--format=tar", `--output=${tarPath}`, input.ref, input.packagePath], {
|
|
190012
192375
|
cwd: input.gitRoot
|
|
190013
192376
|
});
|
|
190014
|
-
const
|
|
192377
|
+
const extract2 = spawnSync3("tar", ["-xf", tarPath, "--strip-components", String(input.packagePath.split("/").length)], {
|
|
190015
192378
|
cwd: input.outDir,
|
|
190016
192379
|
encoding: "utf8"
|
|
190017
192380
|
});
|
|
190018
|
-
if (
|
|
190019
|
-
throw new Error(
|
|
192381
|
+
if (extract2.status !== 0)
|
|
192382
|
+
throw new Error(extract2.stderr.trim() || "tar extraction failed");
|
|
190020
192383
|
} finally {
|
|
190021
192384
|
rmSync(path5.dirname(tarPath), { recursive: true, force: true });
|
|
190022
192385
|
}
|
|
@@ -190045,12 +192408,12 @@ async function tryHostedArchive(input) {
|
|
|
190045
192408
|
const tarPath = path5.join(mkdtempSyncCompat("eigenpal-hosted-source-"), "package.tar");
|
|
190046
192409
|
try {
|
|
190047
192410
|
writeFileSync4(tarPath, Buffer.from(await response.arrayBuffer()));
|
|
190048
|
-
const
|
|
192411
|
+
const extract2 = spawnSync3("tar", ["-xf", tarPath, "--strip-components", String(input.packagePath.split("/").length)], {
|
|
190049
192412
|
cwd: input.outDir,
|
|
190050
192413
|
encoding: "utf8"
|
|
190051
192414
|
});
|
|
190052
|
-
if (
|
|
190053
|
-
throw new Error(
|
|
192415
|
+
if (extract2.status !== 0)
|
|
192416
|
+
throw new Error(extract2.stderr.trim() || "tar extraction failed");
|
|
190054
192417
|
return true;
|
|
190055
192418
|
} finally {
|
|
190056
192419
|
rmSync(path5.dirname(tarPath), { recursive: true, force: true });
|
|
@@ -194405,18 +196768,18 @@ async function init(name, opts) {
|
|
|
194405
196768
|
if (existsSync11(target) && readdirSync2(target).length > 0) {
|
|
194406
196769
|
throw new Error(`Target directory ${relative(process.cwd(), target)} exists and is not empty.`);
|
|
194407
196770
|
}
|
|
194408
|
-
let
|
|
196771
|
+
let template2;
|
|
194409
196772
|
if (opts.template) {
|
|
194410
196773
|
if (!isTemplateName(opts.template)) {
|
|
194411
196774
|
throw new Error(`Unknown template "${opts.template}". Available: ${TEMPLATE_NAMES.join(", ")}.`);
|
|
194412
196775
|
}
|
|
194413
|
-
|
|
196776
|
+
template2 = opts.template;
|
|
194414
196777
|
} else if (opts.yes || !process.stdin.isTTY) {
|
|
194415
|
-
|
|
196778
|
+
template2 = "blank";
|
|
194416
196779
|
} else {
|
|
194417
|
-
|
|
196780
|
+
template2 = await promptForTemplate();
|
|
194418
196781
|
}
|
|
194419
|
-
const sourceRoot = join2(resolveTemplatesRoot(),
|
|
196782
|
+
const sourceRoot = join2(resolveTemplatesRoot(), template2);
|
|
194420
196783
|
if (!existsSync11(sourceRoot)) {
|
|
194421
196784
|
throw new Error(`Template directory missing on disk: ${sourceRoot}`);
|
|
194422
196785
|
}
|
|
@@ -198219,14 +200582,19 @@ var HELP_GROUPS = [
|
|
|
198219
200582
|
},
|
|
198220
200583
|
{
|
|
198221
200584
|
title: "Workflows",
|
|
198222
|
-
description: "Definition, evaluators, dataset, experiments, and
|
|
200585
|
+
description: "Definition, evaluators, dataset, experiments, and versions",
|
|
198223
200586
|
commands: ["workflow"]
|
|
198224
200587
|
},
|
|
198225
200588
|
{
|
|
198226
200589
|
title: "Agents",
|
|
198227
|
-
description: "Git-backed source (clone, save, release, sync),
|
|
200590
|
+
description: "Git-backed source (clone, save, release, sync), datasets, sessions. `git` passthrough adds org remote auth.",
|
|
198228
200591
|
commands: ["agents", "git"]
|
|
198229
200592
|
},
|
|
200593
|
+
{
|
|
200594
|
+
title: "Run",
|
|
200595
|
+
description: "Start runs, then watch them, read their output, and download artifacts.",
|
|
200596
|
+
commands: ["run", "rerun", "runs"]
|
|
200597
|
+
},
|
|
198230
200598
|
{
|
|
198231
200599
|
title: "Tooling",
|
|
198232
200600
|
description: "Install the Eigenpal skill into your agent tools (Claude Code, Cursor, …)",
|