@eigenpal/cli 0.10.38 → 0.10.40
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +314 -2862
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -17245,149 +17245,8 @@ var init_provider_logo_data_generated = __esm(() => {
|
|
|
17245
17245
|
};
|
|
17246
17246
|
});
|
|
17247
17247
|
|
|
17248
|
-
// ../../node_modules/nanoid/url-alphabet/index.js
|
|
17249
|
-
var urlAlphabet = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
|
|
17250
|
-
|
|
17251
|
-
// ../../node_modules/nanoid/index.js
|
|
17252
|
-
import { webcrypto as crypto } from "node:crypto";
|
|
17253
|
-
function fillPool(bytes) {
|
|
17254
|
-
if (!pool || pool.length < bytes) {
|
|
17255
|
-
pool = Buffer.allocUnsafe(bytes * POOL_SIZE_MULTIPLIER);
|
|
17256
|
-
crypto.getRandomValues(pool);
|
|
17257
|
-
poolOffset = 0;
|
|
17258
|
-
} else if (poolOffset + bytes > pool.length) {
|
|
17259
|
-
crypto.getRandomValues(pool);
|
|
17260
|
-
poolOffset = 0;
|
|
17261
|
-
}
|
|
17262
|
-
poolOffset += bytes;
|
|
17263
|
-
}
|
|
17264
|
-
function nanoid3(size = 21) {
|
|
17265
|
-
fillPool(size |= 0);
|
|
17266
|
-
let id = "";
|
|
17267
|
-
for (let i = poolOffset - size;i < poolOffset; i++) {
|
|
17268
|
-
id += urlAlphabet[pool[i] & 63];
|
|
17269
|
-
}
|
|
17270
|
-
return id;
|
|
17271
|
-
}
|
|
17272
|
-
var POOL_SIZE_MULTIPLIER = 128, pool, poolOffset;
|
|
17273
|
-
var init_nanoid = () => {};
|
|
17274
|
-
|
|
17275
|
-
// ../types/src/core/common.ts
|
|
17276
|
-
function generateId(prefix) {
|
|
17277
|
-
const id = nanoid3();
|
|
17278
|
-
return prefix ? `${prefix}_${id}` : id;
|
|
17279
|
-
}
|
|
17280
|
-
function toJsonSchema(schema) {
|
|
17281
|
-
return exports_external.toJSONSchema(schema, { target: "draft-7" });
|
|
17282
|
-
}
|
|
17283
|
-
var ID_PREFIXES, TimestampSchema, JsonSchemaSchema, BaseEntitySchema;
|
|
17284
|
-
var init_common = __esm(() => {
|
|
17285
|
-
init_nanoid();
|
|
17286
|
-
init_zod();
|
|
17287
|
-
ID_PREFIXES = {
|
|
17288
|
-
WORKFLOW: "wf",
|
|
17289
|
-
WORKFLOW_VERSION: "wfv",
|
|
17290
|
-
WORKFLOW_HISTORY: "wfh",
|
|
17291
|
-
JOB: "job",
|
|
17292
|
-
EXECUTION: "exec",
|
|
17293
|
-
STEP_EXECUTION: "step",
|
|
17294
|
-
FILE: "file",
|
|
17295
|
-
TEMPLATE: "tmpl",
|
|
17296
|
-
USER: "user",
|
|
17297
|
-
TENANT: "org",
|
|
17298
|
-
TENANT_INVITE: "inv",
|
|
17299
|
-
API_KEY: "eig",
|
|
17300
|
-
PROCESSOR: "proc",
|
|
17301
|
-
AI_PROVIDER: "aip",
|
|
17302
|
-
ACCOUNT: "acct",
|
|
17303
|
-
SESSION: "sess",
|
|
17304
|
-
VERIFICATION: "vrf",
|
|
17305
|
-
DATASET: "ds",
|
|
17306
|
-
DATASET_EXAMPLE: "dex",
|
|
17307
|
-
EXPERIMENT: "exp",
|
|
17308
|
-
EXPERIMENT_RUN: "exr",
|
|
17309
|
-
EXPERIMENT_EVALUATION: "evl",
|
|
17310
|
-
EVAL_EXAMPLE: "evx",
|
|
17311
|
-
EVAL_RESULT: "evr",
|
|
17312
|
-
EVAL_BATCH: "evb",
|
|
17313
|
-
RUN_REVIEW: "rev",
|
|
17314
|
-
RUN_REVIEW_CORRECTION: "rvc",
|
|
17315
|
-
TABLE_ROW: "row",
|
|
17316
|
-
FOLDER: "fldr",
|
|
17317
|
-
AGENT_WORKFLOW: "awf",
|
|
17318
|
-
AGENT_EXECUTION: "aex",
|
|
17319
|
-
AGENT_EXAMPLE: "aeg",
|
|
17320
|
-
AGENT_VERSION: "avr",
|
|
17321
|
-
AGENT_TRAINING_SESSION: "ats",
|
|
17322
|
-
AGENT_EXPERIMENT: "aexp",
|
|
17323
|
-
AGENT_EMAIL_ALIAS: "aea",
|
|
17324
|
-
AGENT_EMAIL_INVOCATION: "aei",
|
|
17325
|
-
AUTOMATION_TRIGGER: "atr",
|
|
17326
|
-
FILE_SOURCE_CONFIG: "fsc",
|
|
17327
|
-
WEBHOOK_ENDPOINT: "whep",
|
|
17328
|
-
WEBHOOK_EVENT: "whev",
|
|
17329
|
-
WEBHOOK_DELIVERY: "whdl",
|
|
17330
|
-
WEBHOOK_ATTEMPT: "what",
|
|
17331
|
-
PAID_ALLOWANCE_GRANT: "pag",
|
|
17332
|
-
PAID_ALLOWANCE_ADJUSTMENT: "paa",
|
|
17333
|
-
OCR_EXTRACTION_PIPELINE: "oppl",
|
|
17334
|
-
OCR_JOB: "opj",
|
|
17335
|
-
SANDBOX_WS_TOKEN: "sws"
|
|
17336
|
-
};
|
|
17337
|
-
TimestampSchema = exports_external.union([exports_external.date(), exports_external.string().datetime()]).transform((val) => {
|
|
17338
|
-
return typeof val === "string" ? new Date(val) : val;
|
|
17339
|
-
});
|
|
17340
|
-
JsonSchemaSchema = exports_external.record(exports_external.string(), exports_external.unknown());
|
|
17341
|
-
BaseEntitySchema = exports_external.object({
|
|
17342
|
-
id: exports_external.string(),
|
|
17343
|
-
createdAt: TimestampSchema.optional(),
|
|
17344
|
-
updatedAt: TimestampSchema.optional()
|
|
17345
|
-
});
|
|
17346
|
-
});
|
|
17347
|
-
|
|
17348
|
-
// ../types/src/core/ids.ts
|
|
17349
|
-
var PROCESSOR_IDS, PARSER_IDS, INPUT_KINDS;
|
|
17350
|
-
var init_ids = __esm(() => {
|
|
17351
|
-
PROCESSOR_IDS = {
|
|
17352
|
-
MERGE: "builtin/merge",
|
|
17353
|
-
DOCUMENT_PARSER: "builtin/parser",
|
|
17354
|
-
EXTRACT: "builtin/extract",
|
|
17355
|
-
SPLIT: "builtin/split",
|
|
17356
|
-
SEGMENT: "builtin/segment",
|
|
17357
|
-
CLASSIFY: "builtin/classify",
|
|
17358
|
-
CLASSIFY_PAGES: "builtin/classify-pages",
|
|
17359
|
-
VISION: "builtin/vision",
|
|
17360
|
-
TEMPLATE: "builtin/template",
|
|
17361
|
-
PDF_EMBEDDER: "builtin/pdf-embedder",
|
|
17362
|
-
XLSX_TO_JSON: "builtin/xlsx-to-json"
|
|
17363
|
-
};
|
|
17364
|
-
PARSER_IDS = {
|
|
17365
|
-
KREUZBERG: "builtin/kreuzberg",
|
|
17366
|
-
OCR: "builtin/ocr",
|
|
17367
|
-
LLM_VISION: "builtin/llm-vision"
|
|
17368
|
-
};
|
|
17369
|
-
INPUT_KINDS = {
|
|
17370
|
-
DOCUMENT: "document",
|
|
17371
|
-
PAYLOAD: "payload"
|
|
17372
|
-
};
|
|
17373
|
-
});
|
|
17374
|
-
|
|
17375
|
-
// ../types/src/core/pagination.ts
|
|
17376
|
-
var PaginationParamsSchema, DEFAULT_PAGE_SIZE = 50, MAX_PAGE_SIZE = 100;
|
|
17377
|
-
var init_pagination = __esm(() => {
|
|
17378
|
-
init_zod();
|
|
17379
|
-
PaginationParamsSchema = exports_external.object({
|
|
17380
|
-
limit: exports_external.coerce.number().int().min(1).max(100).default(50),
|
|
17381
|
-
offset: exports_external.coerce.number().int().min(0).default(0)
|
|
17382
|
-
});
|
|
17383
|
-
});
|
|
17384
|
-
|
|
17385
17248
|
// ../types/src/core/index.ts
|
|
17386
|
-
var init_core3 =
|
|
17387
|
-
init_common();
|
|
17388
|
-
init_ids();
|
|
17389
|
-
init_pagination();
|
|
17390
|
-
});
|
|
17249
|
+
var init_core3 = () => {};
|
|
17391
17250
|
|
|
17392
17251
|
// ../types/src/files/legacy-boundary.ts
|
|
17393
17252
|
var LEGACY_FILE_REF_COMPATIBILITY;
|
|
@@ -17412,9 +17271,6 @@ var init_legacy_boundary = __esm(() => {
|
|
|
17412
17271
|
function isRuntimeFileRef(input) {
|
|
17413
17272
|
return RuntimeFileRefSchema.safeParse(input).success;
|
|
17414
17273
|
}
|
|
17415
|
-
function isFilePathDescriptor(input) {
|
|
17416
|
-
return FilePathDescriptorSchema.safeParse(input).success;
|
|
17417
|
-
}
|
|
17418
17274
|
function isResolvedProcessorFile(input) {
|
|
17419
17275
|
return ResolvedProcessorFileSchema.safeParse(input).success;
|
|
17420
17276
|
}
|
|
@@ -17637,2508 +17493,11 @@ var init_scoped_file_ref = __esm(() => {
|
|
|
17637
17493
|
]);
|
|
17638
17494
|
});
|
|
17639
17495
|
|
|
17640
|
-
// ../../node_modules/@opentelemetry/api/build/src/version.js
|
|
17641
|
-
var require_version = __commonJS((exports) => {
|
|
17642
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17643
|
-
exports.VERSION = undefined;
|
|
17644
|
-
exports.VERSION = "1.9.1";
|
|
17645
|
-
});
|
|
17646
|
-
|
|
17647
|
-
// ../../node_modules/@opentelemetry/api/build/src/internal/semver.js
|
|
17648
|
-
var require_semver = __commonJS((exports) => {
|
|
17649
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17650
|
-
exports.isCompatible = exports._makeCompatibilityCheck = undefined;
|
|
17651
|
-
var version_1 = require_version();
|
|
17652
|
-
var re = /^(\d+)\.(\d+)\.(\d+)(-(.+))?$/;
|
|
17653
|
-
function _makeCompatibilityCheck(ownVersion) {
|
|
17654
|
-
const acceptedVersions = new Set([ownVersion]);
|
|
17655
|
-
const rejectedVersions = new Set;
|
|
17656
|
-
const myVersionMatch = ownVersion.match(re);
|
|
17657
|
-
if (!myVersionMatch) {
|
|
17658
|
-
return () => false;
|
|
17659
|
-
}
|
|
17660
|
-
const ownVersionParsed = {
|
|
17661
|
-
major: +myVersionMatch[1],
|
|
17662
|
-
minor: +myVersionMatch[2],
|
|
17663
|
-
patch: +myVersionMatch[3],
|
|
17664
|
-
prerelease: myVersionMatch[4]
|
|
17665
|
-
};
|
|
17666
|
-
if (ownVersionParsed.prerelease != null) {
|
|
17667
|
-
return function isExactmatch(globalVersion) {
|
|
17668
|
-
return globalVersion === ownVersion;
|
|
17669
|
-
};
|
|
17670
|
-
}
|
|
17671
|
-
function _reject(v) {
|
|
17672
|
-
rejectedVersions.add(v);
|
|
17673
|
-
return false;
|
|
17674
|
-
}
|
|
17675
|
-
function _accept(v) {
|
|
17676
|
-
acceptedVersions.add(v);
|
|
17677
|
-
return true;
|
|
17678
|
-
}
|
|
17679
|
-
return function isCompatible(globalVersion) {
|
|
17680
|
-
if (acceptedVersions.has(globalVersion)) {
|
|
17681
|
-
return true;
|
|
17682
|
-
}
|
|
17683
|
-
if (rejectedVersions.has(globalVersion)) {
|
|
17684
|
-
return false;
|
|
17685
|
-
}
|
|
17686
|
-
const globalVersionMatch = globalVersion.match(re);
|
|
17687
|
-
if (!globalVersionMatch) {
|
|
17688
|
-
return _reject(globalVersion);
|
|
17689
|
-
}
|
|
17690
|
-
const globalVersionParsed = {
|
|
17691
|
-
major: +globalVersionMatch[1],
|
|
17692
|
-
minor: +globalVersionMatch[2],
|
|
17693
|
-
patch: +globalVersionMatch[3],
|
|
17694
|
-
prerelease: globalVersionMatch[4]
|
|
17695
|
-
};
|
|
17696
|
-
if (globalVersionParsed.prerelease != null) {
|
|
17697
|
-
return _reject(globalVersion);
|
|
17698
|
-
}
|
|
17699
|
-
if (ownVersionParsed.major !== globalVersionParsed.major) {
|
|
17700
|
-
return _reject(globalVersion);
|
|
17701
|
-
}
|
|
17702
|
-
if (ownVersionParsed.major === 0) {
|
|
17703
|
-
if (ownVersionParsed.minor === globalVersionParsed.minor && ownVersionParsed.patch <= globalVersionParsed.patch) {
|
|
17704
|
-
return _accept(globalVersion);
|
|
17705
|
-
}
|
|
17706
|
-
return _reject(globalVersion);
|
|
17707
|
-
}
|
|
17708
|
-
if (ownVersionParsed.minor <= globalVersionParsed.minor) {
|
|
17709
|
-
return _accept(globalVersion);
|
|
17710
|
-
}
|
|
17711
|
-
return _reject(globalVersion);
|
|
17712
|
-
};
|
|
17713
|
-
}
|
|
17714
|
-
exports._makeCompatibilityCheck = _makeCompatibilityCheck;
|
|
17715
|
-
exports.isCompatible = _makeCompatibilityCheck(version_1.VERSION);
|
|
17716
|
-
});
|
|
17717
|
-
|
|
17718
|
-
// ../../node_modules/@opentelemetry/api/build/src/internal/global-utils.js
|
|
17719
|
-
var require_global_utils = __commonJS((exports) => {
|
|
17720
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17721
|
-
exports.unregisterGlobal = exports.getGlobal = exports.registerGlobal = undefined;
|
|
17722
|
-
var version_1 = require_version();
|
|
17723
|
-
var semver_1 = require_semver();
|
|
17724
|
-
var major = version_1.VERSION.split(".")[0];
|
|
17725
|
-
var GLOBAL_OPENTELEMETRY_API_KEY = Symbol.for(`opentelemetry.js.api.${major}`);
|
|
17726
|
-
var _global = typeof globalThis === "object" ? globalThis : typeof self === "object" ? self : typeof window === "object" ? window : typeof global === "object" ? global : {};
|
|
17727
|
-
function registerGlobal(type, instance, diag, allowOverride = false) {
|
|
17728
|
-
var _a3;
|
|
17729
|
-
const api2 = _global[GLOBAL_OPENTELEMETRY_API_KEY] = (_a3 = _global[GLOBAL_OPENTELEMETRY_API_KEY]) !== null && _a3 !== undefined ? _a3 : {
|
|
17730
|
-
version: version_1.VERSION
|
|
17731
|
-
};
|
|
17732
|
-
if (!allowOverride && api2[type]) {
|
|
17733
|
-
const err = new Error(`@opentelemetry/api: Attempted duplicate registration of API: ${type}`);
|
|
17734
|
-
diag.error(err.stack || err.message);
|
|
17735
|
-
return false;
|
|
17736
|
-
}
|
|
17737
|
-
if (api2.version !== version_1.VERSION) {
|
|
17738
|
-
const err = new Error(`@opentelemetry/api: Registration of version v${api2.version} for ${type} does not match previously registered API v${version_1.VERSION}`);
|
|
17739
|
-
diag.error(err.stack || err.message);
|
|
17740
|
-
return false;
|
|
17741
|
-
}
|
|
17742
|
-
api2[type] = instance;
|
|
17743
|
-
diag.debug(`@opentelemetry/api: Registered a global for ${type} v${version_1.VERSION}.`);
|
|
17744
|
-
return true;
|
|
17745
|
-
}
|
|
17746
|
-
exports.registerGlobal = registerGlobal;
|
|
17747
|
-
function getGlobal(type) {
|
|
17748
|
-
var _a3, _b;
|
|
17749
|
-
const globalVersion = (_a3 = _global[GLOBAL_OPENTELEMETRY_API_KEY]) === null || _a3 === undefined ? undefined : _a3.version;
|
|
17750
|
-
if (!globalVersion || !(0, semver_1.isCompatible)(globalVersion)) {
|
|
17751
|
-
return;
|
|
17752
|
-
}
|
|
17753
|
-
return (_b = _global[GLOBAL_OPENTELEMETRY_API_KEY]) === null || _b === undefined ? undefined : _b[type];
|
|
17754
|
-
}
|
|
17755
|
-
exports.getGlobal = getGlobal;
|
|
17756
|
-
function unregisterGlobal(type, diag) {
|
|
17757
|
-
diag.debug(`@opentelemetry/api: Unregistering a global for ${type} v${version_1.VERSION}.`);
|
|
17758
|
-
const api2 = _global[GLOBAL_OPENTELEMETRY_API_KEY];
|
|
17759
|
-
if (api2) {
|
|
17760
|
-
delete api2[type];
|
|
17761
|
-
}
|
|
17762
|
-
}
|
|
17763
|
-
exports.unregisterGlobal = unregisterGlobal;
|
|
17764
|
-
});
|
|
17765
|
-
|
|
17766
|
-
// ../../node_modules/@opentelemetry/api/build/src/diag/ComponentLogger.js
|
|
17767
|
-
var require_ComponentLogger = __commonJS((exports) => {
|
|
17768
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17769
|
-
exports.DiagComponentLogger = undefined;
|
|
17770
|
-
var global_utils_1 = require_global_utils();
|
|
17771
|
-
|
|
17772
|
-
class DiagComponentLogger {
|
|
17773
|
-
constructor(props) {
|
|
17774
|
-
this._namespace = props.namespace || "DiagComponentLogger";
|
|
17775
|
-
}
|
|
17776
|
-
debug(...args) {
|
|
17777
|
-
return logProxy("debug", this._namespace, args);
|
|
17778
|
-
}
|
|
17779
|
-
error(...args) {
|
|
17780
|
-
return logProxy("error", this._namespace, args);
|
|
17781
|
-
}
|
|
17782
|
-
info(...args) {
|
|
17783
|
-
return logProxy("info", this._namespace, args);
|
|
17784
|
-
}
|
|
17785
|
-
warn(...args) {
|
|
17786
|
-
return logProxy("warn", this._namespace, args);
|
|
17787
|
-
}
|
|
17788
|
-
verbose(...args) {
|
|
17789
|
-
return logProxy("verbose", this._namespace, args);
|
|
17790
|
-
}
|
|
17791
|
-
}
|
|
17792
|
-
exports.DiagComponentLogger = DiagComponentLogger;
|
|
17793
|
-
function logProxy(funcName, namespace, args) {
|
|
17794
|
-
const logger = (0, global_utils_1.getGlobal)("diag");
|
|
17795
|
-
if (!logger) {
|
|
17796
|
-
return;
|
|
17797
|
-
}
|
|
17798
|
-
return logger[funcName](namespace, ...args);
|
|
17799
|
-
}
|
|
17800
|
-
});
|
|
17801
|
-
|
|
17802
|
-
// ../../node_modules/@opentelemetry/api/build/src/diag/types.js
|
|
17803
|
-
var require_types = __commonJS((exports) => {
|
|
17804
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17805
|
-
exports.DiagLogLevel = undefined;
|
|
17806
|
-
var DiagLogLevel;
|
|
17807
|
-
(function(DiagLogLevel2) {
|
|
17808
|
-
DiagLogLevel2[DiagLogLevel2["NONE"] = 0] = "NONE";
|
|
17809
|
-
DiagLogLevel2[DiagLogLevel2["ERROR"] = 30] = "ERROR";
|
|
17810
|
-
DiagLogLevel2[DiagLogLevel2["WARN"] = 50] = "WARN";
|
|
17811
|
-
DiagLogLevel2[DiagLogLevel2["INFO"] = 60] = "INFO";
|
|
17812
|
-
DiagLogLevel2[DiagLogLevel2["DEBUG"] = 70] = "DEBUG";
|
|
17813
|
-
DiagLogLevel2[DiagLogLevel2["VERBOSE"] = 80] = "VERBOSE";
|
|
17814
|
-
DiagLogLevel2[DiagLogLevel2["ALL"] = 9999] = "ALL";
|
|
17815
|
-
})(DiagLogLevel = exports.DiagLogLevel || (exports.DiagLogLevel = {}));
|
|
17816
|
-
});
|
|
17817
|
-
|
|
17818
|
-
// ../../node_modules/@opentelemetry/api/build/src/diag/internal/logLevelLogger.js
|
|
17819
|
-
var require_logLevelLogger = __commonJS((exports) => {
|
|
17820
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17821
|
-
exports.createLogLevelDiagLogger = undefined;
|
|
17822
|
-
var types_1 = require_types();
|
|
17823
|
-
function createLogLevelDiagLogger(maxLevel, logger) {
|
|
17824
|
-
if (maxLevel < types_1.DiagLogLevel.NONE) {
|
|
17825
|
-
maxLevel = types_1.DiagLogLevel.NONE;
|
|
17826
|
-
} else if (maxLevel > types_1.DiagLogLevel.ALL) {
|
|
17827
|
-
maxLevel = types_1.DiagLogLevel.ALL;
|
|
17828
|
-
}
|
|
17829
|
-
logger = logger || {};
|
|
17830
|
-
function _filterFunc(funcName, theLevel) {
|
|
17831
|
-
const theFunc = logger[funcName];
|
|
17832
|
-
if (typeof theFunc === "function" && maxLevel >= theLevel) {
|
|
17833
|
-
return theFunc.bind(logger);
|
|
17834
|
-
}
|
|
17835
|
-
return function() {};
|
|
17836
|
-
}
|
|
17837
|
-
return {
|
|
17838
|
-
error: _filterFunc("error", types_1.DiagLogLevel.ERROR),
|
|
17839
|
-
warn: _filterFunc("warn", types_1.DiagLogLevel.WARN),
|
|
17840
|
-
info: _filterFunc("info", types_1.DiagLogLevel.INFO),
|
|
17841
|
-
debug: _filterFunc("debug", types_1.DiagLogLevel.DEBUG),
|
|
17842
|
-
verbose: _filterFunc("verbose", types_1.DiagLogLevel.VERBOSE)
|
|
17843
|
-
};
|
|
17844
|
-
}
|
|
17845
|
-
exports.createLogLevelDiagLogger = createLogLevelDiagLogger;
|
|
17846
|
-
});
|
|
17847
|
-
|
|
17848
|
-
// ../../node_modules/@opentelemetry/api/build/src/api/diag.js
|
|
17849
|
-
var require_diag = __commonJS((exports) => {
|
|
17850
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17851
|
-
exports.DiagAPI = undefined;
|
|
17852
|
-
var ComponentLogger_1 = require_ComponentLogger();
|
|
17853
|
-
var logLevelLogger_1 = require_logLevelLogger();
|
|
17854
|
-
var types_1 = require_types();
|
|
17855
|
-
var global_utils_1 = require_global_utils();
|
|
17856
|
-
var API_NAME = "diag";
|
|
17857
|
-
|
|
17858
|
-
class DiagAPI {
|
|
17859
|
-
static instance() {
|
|
17860
|
-
if (!this._instance) {
|
|
17861
|
-
this._instance = new DiagAPI;
|
|
17862
|
-
}
|
|
17863
|
-
return this._instance;
|
|
17864
|
-
}
|
|
17865
|
-
constructor() {
|
|
17866
|
-
function _logProxy(funcName) {
|
|
17867
|
-
return function(...args) {
|
|
17868
|
-
const logger = (0, global_utils_1.getGlobal)("diag");
|
|
17869
|
-
if (!logger)
|
|
17870
|
-
return;
|
|
17871
|
-
return logger[funcName](...args);
|
|
17872
|
-
};
|
|
17873
|
-
}
|
|
17874
|
-
const self2 = this;
|
|
17875
|
-
const setLogger = (logger, optionsOrLogLevel = { logLevel: types_1.DiagLogLevel.INFO }) => {
|
|
17876
|
-
var _a3, _b, _c;
|
|
17877
|
-
if (logger === self2) {
|
|
17878
|
-
const err = new Error("Cannot use diag as the logger for itself. Please use a DiagLogger implementation like ConsoleDiagLogger or a custom implementation");
|
|
17879
|
-
self2.error((_a3 = err.stack) !== null && _a3 !== undefined ? _a3 : err.message);
|
|
17880
|
-
return false;
|
|
17881
|
-
}
|
|
17882
|
-
if (typeof optionsOrLogLevel === "number") {
|
|
17883
|
-
optionsOrLogLevel = {
|
|
17884
|
-
logLevel: optionsOrLogLevel
|
|
17885
|
-
};
|
|
17886
|
-
}
|
|
17887
|
-
const oldLogger = (0, global_utils_1.getGlobal)("diag");
|
|
17888
|
-
const newLogger = (0, logLevelLogger_1.createLogLevelDiagLogger)((_b = optionsOrLogLevel.logLevel) !== null && _b !== undefined ? _b : types_1.DiagLogLevel.INFO, logger);
|
|
17889
|
-
if (oldLogger && !optionsOrLogLevel.suppressOverrideMessage) {
|
|
17890
|
-
const stack = (_c = new Error().stack) !== null && _c !== undefined ? _c : "<failed to generate stacktrace>";
|
|
17891
|
-
oldLogger.warn(`Current logger will be overwritten from ${stack}`);
|
|
17892
|
-
newLogger.warn(`Current logger will overwrite one already registered from ${stack}`);
|
|
17893
|
-
}
|
|
17894
|
-
return (0, global_utils_1.registerGlobal)("diag", newLogger, self2, true);
|
|
17895
|
-
};
|
|
17896
|
-
self2.setLogger = setLogger;
|
|
17897
|
-
self2.disable = () => {
|
|
17898
|
-
(0, global_utils_1.unregisterGlobal)(API_NAME, self2);
|
|
17899
|
-
};
|
|
17900
|
-
self2.createComponentLogger = (options) => {
|
|
17901
|
-
return new ComponentLogger_1.DiagComponentLogger(options);
|
|
17902
|
-
};
|
|
17903
|
-
self2.verbose = _logProxy("verbose");
|
|
17904
|
-
self2.debug = _logProxy("debug");
|
|
17905
|
-
self2.info = _logProxy("info");
|
|
17906
|
-
self2.warn = _logProxy("warn");
|
|
17907
|
-
self2.error = _logProxy("error");
|
|
17908
|
-
}
|
|
17909
|
-
}
|
|
17910
|
-
exports.DiagAPI = DiagAPI;
|
|
17911
|
-
});
|
|
17912
|
-
|
|
17913
|
-
// ../../node_modules/@opentelemetry/api/build/src/baggage/internal/baggage-impl.js
|
|
17914
|
-
var require_baggage_impl = __commonJS((exports) => {
|
|
17915
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17916
|
-
exports.BaggageImpl = undefined;
|
|
17917
|
-
|
|
17918
|
-
class BaggageImpl {
|
|
17919
|
-
constructor(entries) {
|
|
17920
|
-
this._entries = entries ? new Map(entries) : new Map;
|
|
17921
|
-
}
|
|
17922
|
-
getEntry(key) {
|
|
17923
|
-
const entry = this._entries.get(key);
|
|
17924
|
-
if (!entry) {
|
|
17925
|
-
return;
|
|
17926
|
-
}
|
|
17927
|
-
return Object.assign({}, entry);
|
|
17928
|
-
}
|
|
17929
|
-
getAllEntries() {
|
|
17930
|
-
return Array.from(this._entries.entries());
|
|
17931
|
-
}
|
|
17932
|
-
setEntry(key, entry) {
|
|
17933
|
-
const newBaggage = new BaggageImpl(this._entries);
|
|
17934
|
-
newBaggage._entries.set(key, entry);
|
|
17935
|
-
return newBaggage;
|
|
17936
|
-
}
|
|
17937
|
-
removeEntry(key) {
|
|
17938
|
-
const newBaggage = new BaggageImpl(this._entries);
|
|
17939
|
-
newBaggage._entries.delete(key);
|
|
17940
|
-
return newBaggage;
|
|
17941
|
-
}
|
|
17942
|
-
removeEntries(...keys) {
|
|
17943
|
-
const newBaggage = new BaggageImpl(this._entries);
|
|
17944
|
-
for (const key of keys) {
|
|
17945
|
-
newBaggage._entries.delete(key);
|
|
17946
|
-
}
|
|
17947
|
-
return newBaggage;
|
|
17948
|
-
}
|
|
17949
|
-
clear() {
|
|
17950
|
-
return new BaggageImpl;
|
|
17951
|
-
}
|
|
17952
|
-
}
|
|
17953
|
-
exports.BaggageImpl = BaggageImpl;
|
|
17954
|
-
});
|
|
17955
|
-
|
|
17956
|
-
// ../../node_modules/@opentelemetry/api/build/src/baggage/internal/symbol.js
|
|
17957
|
-
var require_symbol = __commonJS((exports) => {
|
|
17958
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17959
|
-
exports.baggageEntryMetadataSymbol = undefined;
|
|
17960
|
-
exports.baggageEntryMetadataSymbol = Symbol("BaggageEntryMetadata");
|
|
17961
|
-
});
|
|
17962
|
-
|
|
17963
|
-
// ../../node_modules/@opentelemetry/api/build/src/baggage/utils.js
|
|
17964
|
-
var require_utils = __commonJS((exports) => {
|
|
17965
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17966
|
-
exports.baggageEntryMetadataFromString = exports.createBaggage = undefined;
|
|
17967
|
-
var diag_1 = require_diag();
|
|
17968
|
-
var baggage_impl_1 = require_baggage_impl();
|
|
17969
|
-
var symbol_1 = require_symbol();
|
|
17970
|
-
var diag = diag_1.DiagAPI.instance();
|
|
17971
|
-
function createBaggage(entries = {}) {
|
|
17972
|
-
return new baggage_impl_1.BaggageImpl(new Map(Object.entries(entries)));
|
|
17973
|
-
}
|
|
17974
|
-
exports.createBaggage = createBaggage;
|
|
17975
|
-
function baggageEntryMetadataFromString(str) {
|
|
17976
|
-
if (typeof str !== "string") {
|
|
17977
|
-
diag.error(`Cannot create baggage metadata from unknown type: ${typeof str}`);
|
|
17978
|
-
str = "";
|
|
17979
|
-
}
|
|
17980
|
-
return {
|
|
17981
|
-
__TYPE__: symbol_1.baggageEntryMetadataSymbol,
|
|
17982
|
-
toString() {
|
|
17983
|
-
return str;
|
|
17984
|
-
}
|
|
17985
|
-
};
|
|
17986
|
-
}
|
|
17987
|
-
exports.baggageEntryMetadataFromString = baggageEntryMetadataFromString;
|
|
17988
|
-
});
|
|
17989
|
-
|
|
17990
|
-
// ../../node_modules/@opentelemetry/api/build/src/context/context.js
|
|
17991
|
-
var require_context = __commonJS((exports) => {
|
|
17992
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17993
|
-
exports.ROOT_CONTEXT = exports.createContextKey = undefined;
|
|
17994
|
-
function createContextKey(description) {
|
|
17995
|
-
return Symbol.for(description);
|
|
17996
|
-
}
|
|
17997
|
-
exports.createContextKey = createContextKey;
|
|
17998
|
-
|
|
17999
|
-
class BaseContext {
|
|
18000
|
-
constructor(parentContext) {
|
|
18001
|
-
const self2 = this;
|
|
18002
|
-
self2._currentContext = parentContext ? new Map(parentContext) : new Map;
|
|
18003
|
-
self2.getValue = (key) => self2._currentContext.get(key);
|
|
18004
|
-
self2.setValue = (key, value) => {
|
|
18005
|
-
const context = new BaseContext(self2._currentContext);
|
|
18006
|
-
context._currentContext.set(key, value);
|
|
18007
|
-
return context;
|
|
18008
|
-
};
|
|
18009
|
-
self2.deleteValue = (key) => {
|
|
18010
|
-
const context = new BaseContext(self2._currentContext);
|
|
18011
|
-
context._currentContext.delete(key);
|
|
18012
|
-
return context;
|
|
18013
|
-
};
|
|
18014
|
-
}
|
|
18015
|
-
}
|
|
18016
|
-
exports.ROOT_CONTEXT = new BaseContext;
|
|
18017
|
-
});
|
|
18018
|
-
|
|
18019
|
-
// ../../node_modules/@opentelemetry/api/build/src/diag/consoleLogger.js
|
|
18020
|
-
var require_consoleLogger = __commonJS((exports) => {
|
|
18021
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18022
|
-
exports.DiagConsoleLogger = exports._originalConsoleMethods = undefined;
|
|
18023
|
-
var consoleMap = [
|
|
18024
|
-
{ n: "error", c: "error" },
|
|
18025
|
-
{ n: "warn", c: "warn" },
|
|
18026
|
-
{ n: "info", c: "info" },
|
|
18027
|
-
{ n: "debug", c: "debug" },
|
|
18028
|
-
{ n: "verbose", c: "trace" }
|
|
18029
|
-
];
|
|
18030
|
-
exports._originalConsoleMethods = {};
|
|
18031
|
-
if (typeof console !== "undefined") {
|
|
18032
|
-
const keys = [
|
|
18033
|
-
"error",
|
|
18034
|
-
"warn",
|
|
18035
|
-
"info",
|
|
18036
|
-
"debug",
|
|
18037
|
-
"trace",
|
|
18038
|
-
"log"
|
|
18039
|
-
];
|
|
18040
|
-
for (const key of keys) {
|
|
18041
|
-
if (typeof console[key] === "function") {
|
|
18042
|
-
exports._originalConsoleMethods[key] = console[key];
|
|
18043
|
-
}
|
|
18044
|
-
}
|
|
18045
|
-
}
|
|
18046
|
-
|
|
18047
|
-
class DiagConsoleLogger {
|
|
18048
|
-
constructor() {
|
|
18049
|
-
function _consoleFunc(funcName) {
|
|
18050
|
-
return function(...args) {
|
|
18051
|
-
let theFunc = exports._originalConsoleMethods[funcName];
|
|
18052
|
-
if (typeof theFunc !== "function") {
|
|
18053
|
-
theFunc = exports._originalConsoleMethods["log"];
|
|
18054
|
-
}
|
|
18055
|
-
if (typeof theFunc !== "function" && console) {
|
|
18056
|
-
theFunc = console[funcName];
|
|
18057
|
-
if (typeof theFunc !== "function") {
|
|
18058
|
-
theFunc = console.log;
|
|
18059
|
-
}
|
|
18060
|
-
}
|
|
18061
|
-
if (typeof theFunc === "function") {
|
|
18062
|
-
return theFunc.apply(console, args);
|
|
18063
|
-
}
|
|
18064
|
-
};
|
|
18065
|
-
}
|
|
18066
|
-
for (let i = 0;i < consoleMap.length; i++) {
|
|
18067
|
-
this[consoleMap[i].n] = _consoleFunc(consoleMap[i].c);
|
|
18068
|
-
}
|
|
18069
|
-
}
|
|
18070
|
-
}
|
|
18071
|
-
exports.DiagConsoleLogger = DiagConsoleLogger;
|
|
18072
|
-
});
|
|
18073
|
-
|
|
18074
|
-
// ../../node_modules/@opentelemetry/api/build/src/metrics/NoopMeter.js
|
|
18075
|
-
var require_NoopMeter = __commonJS((exports) => {
|
|
18076
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18077
|
-
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;
|
|
18078
|
-
|
|
18079
|
-
class NoopMeter {
|
|
18080
|
-
constructor() {}
|
|
18081
|
-
createGauge(_name, _options) {
|
|
18082
|
-
return exports.NOOP_GAUGE_METRIC;
|
|
18083
|
-
}
|
|
18084
|
-
createHistogram(_name, _options) {
|
|
18085
|
-
return exports.NOOP_HISTOGRAM_METRIC;
|
|
18086
|
-
}
|
|
18087
|
-
createCounter(_name, _options) {
|
|
18088
|
-
return exports.NOOP_COUNTER_METRIC;
|
|
18089
|
-
}
|
|
18090
|
-
createUpDownCounter(_name, _options) {
|
|
18091
|
-
return exports.NOOP_UP_DOWN_COUNTER_METRIC;
|
|
18092
|
-
}
|
|
18093
|
-
createObservableGauge(_name, _options) {
|
|
18094
|
-
return exports.NOOP_OBSERVABLE_GAUGE_METRIC;
|
|
18095
|
-
}
|
|
18096
|
-
createObservableCounter(_name, _options) {
|
|
18097
|
-
return exports.NOOP_OBSERVABLE_COUNTER_METRIC;
|
|
18098
|
-
}
|
|
18099
|
-
createObservableUpDownCounter(_name, _options) {
|
|
18100
|
-
return exports.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC;
|
|
18101
|
-
}
|
|
18102
|
-
addBatchObservableCallback(_callback, _observables) {}
|
|
18103
|
-
removeBatchObservableCallback(_callback) {}
|
|
18104
|
-
}
|
|
18105
|
-
exports.NoopMeter = NoopMeter;
|
|
18106
|
-
|
|
18107
|
-
class NoopMetric {
|
|
18108
|
-
}
|
|
18109
|
-
exports.NoopMetric = NoopMetric;
|
|
18110
|
-
|
|
18111
|
-
class NoopCounterMetric extends NoopMetric {
|
|
18112
|
-
add(_value, _attributes) {}
|
|
18113
|
-
}
|
|
18114
|
-
exports.NoopCounterMetric = NoopCounterMetric;
|
|
18115
|
-
|
|
18116
|
-
class NoopUpDownCounterMetric extends NoopMetric {
|
|
18117
|
-
add(_value, _attributes) {}
|
|
18118
|
-
}
|
|
18119
|
-
exports.NoopUpDownCounterMetric = NoopUpDownCounterMetric;
|
|
18120
|
-
|
|
18121
|
-
class NoopGaugeMetric extends NoopMetric {
|
|
18122
|
-
record(_value, _attributes) {}
|
|
18123
|
-
}
|
|
18124
|
-
exports.NoopGaugeMetric = NoopGaugeMetric;
|
|
18125
|
-
|
|
18126
|
-
class NoopHistogramMetric extends NoopMetric {
|
|
18127
|
-
record(_value, _attributes) {}
|
|
18128
|
-
}
|
|
18129
|
-
exports.NoopHistogramMetric = NoopHistogramMetric;
|
|
18130
|
-
|
|
18131
|
-
class NoopObservableMetric {
|
|
18132
|
-
addCallback(_callback) {}
|
|
18133
|
-
removeCallback(_callback) {}
|
|
18134
|
-
}
|
|
18135
|
-
exports.NoopObservableMetric = NoopObservableMetric;
|
|
18136
|
-
|
|
18137
|
-
class NoopObservableCounterMetric extends NoopObservableMetric {
|
|
18138
|
-
}
|
|
18139
|
-
exports.NoopObservableCounterMetric = NoopObservableCounterMetric;
|
|
18140
|
-
|
|
18141
|
-
class NoopObservableGaugeMetric extends NoopObservableMetric {
|
|
18142
|
-
}
|
|
18143
|
-
exports.NoopObservableGaugeMetric = NoopObservableGaugeMetric;
|
|
18144
|
-
|
|
18145
|
-
class NoopObservableUpDownCounterMetric extends NoopObservableMetric {
|
|
18146
|
-
}
|
|
18147
|
-
exports.NoopObservableUpDownCounterMetric = NoopObservableUpDownCounterMetric;
|
|
18148
|
-
exports.NOOP_METER = new NoopMeter;
|
|
18149
|
-
exports.NOOP_COUNTER_METRIC = new NoopCounterMetric;
|
|
18150
|
-
exports.NOOP_GAUGE_METRIC = new NoopGaugeMetric;
|
|
18151
|
-
exports.NOOP_HISTOGRAM_METRIC = new NoopHistogramMetric;
|
|
18152
|
-
exports.NOOP_UP_DOWN_COUNTER_METRIC = new NoopUpDownCounterMetric;
|
|
18153
|
-
exports.NOOP_OBSERVABLE_COUNTER_METRIC = new NoopObservableCounterMetric;
|
|
18154
|
-
exports.NOOP_OBSERVABLE_GAUGE_METRIC = new NoopObservableGaugeMetric;
|
|
18155
|
-
exports.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC = new NoopObservableUpDownCounterMetric;
|
|
18156
|
-
function createNoopMeter() {
|
|
18157
|
-
return exports.NOOP_METER;
|
|
18158
|
-
}
|
|
18159
|
-
exports.createNoopMeter = createNoopMeter;
|
|
18160
|
-
});
|
|
18161
|
-
|
|
18162
|
-
// ../../node_modules/@opentelemetry/api/build/src/metrics/Metric.js
|
|
18163
|
-
var require_Metric = __commonJS((exports) => {
|
|
18164
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18165
|
-
exports.ValueType = undefined;
|
|
18166
|
-
var ValueType;
|
|
18167
|
-
(function(ValueType2) {
|
|
18168
|
-
ValueType2[ValueType2["INT"] = 0] = "INT";
|
|
18169
|
-
ValueType2[ValueType2["DOUBLE"] = 1] = "DOUBLE";
|
|
18170
|
-
})(ValueType = exports.ValueType || (exports.ValueType = {}));
|
|
18171
|
-
});
|
|
18172
|
-
|
|
18173
|
-
// ../../node_modules/@opentelemetry/api/build/src/propagation/TextMapPropagator.js
|
|
18174
|
-
var require_TextMapPropagator = __commonJS((exports) => {
|
|
18175
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18176
|
-
exports.defaultTextMapSetter = exports.defaultTextMapGetter = undefined;
|
|
18177
|
-
exports.defaultTextMapGetter = {
|
|
18178
|
-
get(carrier, key) {
|
|
18179
|
-
if (carrier == null) {
|
|
18180
|
-
return;
|
|
18181
|
-
}
|
|
18182
|
-
return carrier[key];
|
|
18183
|
-
},
|
|
18184
|
-
keys(carrier) {
|
|
18185
|
-
if (carrier == null) {
|
|
18186
|
-
return [];
|
|
18187
|
-
}
|
|
18188
|
-
return Object.keys(carrier);
|
|
18189
|
-
}
|
|
18190
|
-
};
|
|
18191
|
-
exports.defaultTextMapSetter = {
|
|
18192
|
-
set(carrier, key, value) {
|
|
18193
|
-
if (carrier == null) {
|
|
18194
|
-
return;
|
|
18195
|
-
}
|
|
18196
|
-
carrier[key] = value;
|
|
18197
|
-
}
|
|
18198
|
-
};
|
|
18199
|
-
});
|
|
18200
|
-
|
|
18201
|
-
// ../../node_modules/@opentelemetry/api/build/src/context/NoopContextManager.js
|
|
18202
|
-
var require_NoopContextManager = __commonJS((exports) => {
|
|
18203
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18204
|
-
exports.NoopContextManager = undefined;
|
|
18205
|
-
var context_1 = require_context();
|
|
18206
|
-
|
|
18207
|
-
class NoopContextManager {
|
|
18208
|
-
active() {
|
|
18209
|
-
return context_1.ROOT_CONTEXT;
|
|
18210
|
-
}
|
|
18211
|
-
with(_context, fn, thisArg, ...args) {
|
|
18212
|
-
return fn.call(thisArg, ...args);
|
|
18213
|
-
}
|
|
18214
|
-
bind(_context, target) {
|
|
18215
|
-
return target;
|
|
18216
|
-
}
|
|
18217
|
-
enable() {
|
|
18218
|
-
return this;
|
|
18219
|
-
}
|
|
18220
|
-
disable() {
|
|
18221
|
-
return this;
|
|
18222
|
-
}
|
|
18223
|
-
}
|
|
18224
|
-
exports.NoopContextManager = NoopContextManager;
|
|
18225
|
-
});
|
|
18226
|
-
|
|
18227
|
-
// ../../node_modules/@opentelemetry/api/build/src/api/context.js
|
|
18228
|
-
var require_context2 = __commonJS((exports) => {
|
|
18229
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18230
|
-
exports.ContextAPI = undefined;
|
|
18231
|
-
var NoopContextManager_1 = require_NoopContextManager();
|
|
18232
|
-
var global_utils_1 = require_global_utils();
|
|
18233
|
-
var diag_1 = require_diag();
|
|
18234
|
-
var API_NAME = "context";
|
|
18235
|
-
var NOOP_CONTEXT_MANAGER = new NoopContextManager_1.NoopContextManager;
|
|
18236
|
-
|
|
18237
|
-
class ContextAPI {
|
|
18238
|
-
constructor() {}
|
|
18239
|
-
static getInstance() {
|
|
18240
|
-
if (!this._instance) {
|
|
18241
|
-
this._instance = new ContextAPI;
|
|
18242
|
-
}
|
|
18243
|
-
return this._instance;
|
|
18244
|
-
}
|
|
18245
|
-
setGlobalContextManager(contextManager) {
|
|
18246
|
-
return (0, global_utils_1.registerGlobal)(API_NAME, contextManager, diag_1.DiagAPI.instance());
|
|
18247
|
-
}
|
|
18248
|
-
active() {
|
|
18249
|
-
return this._getContextManager().active();
|
|
18250
|
-
}
|
|
18251
|
-
with(context, fn, thisArg, ...args) {
|
|
18252
|
-
return this._getContextManager().with(context, fn, thisArg, ...args);
|
|
18253
|
-
}
|
|
18254
|
-
bind(context, target) {
|
|
18255
|
-
return this._getContextManager().bind(context, target);
|
|
18256
|
-
}
|
|
18257
|
-
_getContextManager() {
|
|
18258
|
-
return (0, global_utils_1.getGlobal)(API_NAME) || NOOP_CONTEXT_MANAGER;
|
|
18259
|
-
}
|
|
18260
|
-
disable() {
|
|
18261
|
-
this._getContextManager().disable();
|
|
18262
|
-
(0, global_utils_1.unregisterGlobal)(API_NAME, diag_1.DiagAPI.instance());
|
|
18263
|
-
}
|
|
18264
|
-
}
|
|
18265
|
-
exports.ContextAPI = ContextAPI;
|
|
18266
|
-
});
|
|
18267
|
-
|
|
18268
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/trace_flags.js
|
|
18269
|
-
var require_trace_flags = __commonJS((exports) => {
|
|
18270
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18271
|
-
exports.TraceFlags = undefined;
|
|
18272
|
-
var TraceFlags;
|
|
18273
|
-
(function(TraceFlags2) {
|
|
18274
|
-
TraceFlags2[TraceFlags2["NONE"] = 0] = "NONE";
|
|
18275
|
-
TraceFlags2[TraceFlags2["SAMPLED"] = 1] = "SAMPLED";
|
|
18276
|
-
})(TraceFlags = exports.TraceFlags || (exports.TraceFlags = {}));
|
|
18277
|
-
});
|
|
18278
|
-
|
|
18279
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/invalid-span-constants.js
|
|
18280
|
-
var require_invalid_span_constants = __commonJS((exports) => {
|
|
18281
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18282
|
-
exports.INVALID_SPAN_CONTEXT = exports.INVALID_TRACEID = exports.INVALID_SPANID = undefined;
|
|
18283
|
-
var trace_flags_1 = require_trace_flags();
|
|
18284
|
-
exports.INVALID_SPANID = "0000000000000000";
|
|
18285
|
-
exports.INVALID_TRACEID = "00000000000000000000000000000000";
|
|
18286
|
-
exports.INVALID_SPAN_CONTEXT = {
|
|
18287
|
-
traceId: exports.INVALID_TRACEID,
|
|
18288
|
-
spanId: exports.INVALID_SPANID,
|
|
18289
|
-
traceFlags: trace_flags_1.TraceFlags.NONE
|
|
18290
|
-
};
|
|
18291
|
-
});
|
|
18292
|
-
|
|
18293
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/NonRecordingSpan.js
|
|
18294
|
-
var require_NonRecordingSpan = __commonJS((exports) => {
|
|
18295
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18296
|
-
exports.NonRecordingSpan = undefined;
|
|
18297
|
-
var invalid_span_constants_1 = require_invalid_span_constants();
|
|
18298
|
-
|
|
18299
|
-
class NonRecordingSpan {
|
|
18300
|
-
constructor(spanContext = invalid_span_constants_1.INVALID_SPAN_CONTEXT) {
|
|
18301
|
-
this._spanContext = spanContext;
|
|
18302
|
-
}
|
|
18303
|
-
spanContext() {
|
|
18304
|
-
return this._spanContext;
|
|
18305
|
-
}
|
|
18306
|
-
setAttribute(_key, _value) {
|
|
18307
|
-
return this;
|
|
18308
|
-
}
|
|
18309
|
-
setAttributes(_attributes) {
|
|
18310
|
-
return this;
|
|
18311
|
-
}
|
|
18312
|
-
addEvent(_name, _attributes) {
|
|
18313
|
-
return this;
|
|
18314
|
-
}
|
|
18315
|
-
addLink(_link) {
|
|
18316
|
-
return this;
|
|
18317
|
-
}
|
|
18318
|
-
addLinks(_links) {
|
|
18319
|
-
return this;
|
|
18320
|
-
}
|
|
18321
|
-
setStatus(_status) {
|
|
18322
|
-
return this;
|
|
18323
|
-
}
|
|
18324
|
-
updateName(_name) {
|
|
18325
|
-
return this;
|
|
18326
|
-
}
|
|
18327
|
-
end(_endTime) {}
|
|
18328
|
-
isRecording() {
|
|
18329
|
-
return false;
|
|
18330
|
-
}
|
|
18331
|
-
recordException(_exception, _time) {}
|
|
18332
|
-
}
|
|
18333
|
-
exports.NonRecordingSpan = NonRecordingSpan;
|
|
18334
|
-
});
|
|
18335
|
-
|
|
18336
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/context-utils.js
|
|
18337
|
-
var require_context_utils = __commonJS((exports) => {
|
|
18338
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18339
|
-
exports.getSpanContext = exports.setSpanContext = exports.deleteSpan = exports.setSpan = exports.getActiveSpan = exports.getSpan = undefined;
|
|
18340
|
-
var context_1 = require_context();
|
|
18341
|
-
var NonRecordingSpan_1 = require_NonRecordingSpan();
|
|
18342
|
-
var context_2 = require_context2();
|
|
18343
|
-
var SPAN_KEY = (0, context_1.createContextKey)("OpenTelemetry Context Key SPAN");
|
|
18344
|
-
function getSpan(context) {
|
|
18345
|
-
return context.getValue(SPAN_KEY) || undefined;
|
|
18346
|
-
}
|
|
18347
|
-
exports.getSpan = getSpan;
|
|
18348
|
-
function getActiveSpan() {
|
|
18349
|
-
return getSpan(context_2.ContextAPI.getInstance().active());
|
|
18350
|
-
}
|
|
18351
|
-
exports.getActiveSpan = getActiveSpan;
|
|
18352
|
-
function setSpan(context, span) {
|
|
18353
|
-
return context.setValue(SPAN_KEY, span);
|
|
18354
|
-
}
|
|
18355
|
-
exports.setSpan = setSpan;
|
|
18356
|
-
function deleteSpan(context) {
|
|
18357
|
-
return context.deleteValue(SPAN_KEY);
|
|
18358
|
-
}
|
|
18359
|
-
exports.deleteSpan = deleteSpan;
|
|
18360
|
-
function setSpanContext(context, spanContext) {
|
|
18361
|
-
return setSpan(context, new NonRecordingSpan_1.NonRecordingSpan(spanContext));
|
|
18362
|
-
}
|
|
18363
|
-
exports.setSpanContext = setSpanContext;
|
|
18364
|
-
function getSpanContext(context) {
|
|
18365
|
-
var _a3;
|
|
18366
|
-
return (_a3 = getSpan(context)) === null || _a3 === undefined ? undefined : _a3.spanContext();
|
|
18367
|
-
}
|
|
18368
|
-
exports.getSpanContext = getSpanContext;
|
|
18369
|
-
});
|
|
18370
|
-
|
|
18371
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/spancontext-utils.js
|
|
18372
|
-
var require_spancontext_utils = __commonJS((exports) => {
|
|
18373
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18374
|
-
exports.wrapSpanContext = exports.isSpanContextValid = exports.isValidSpanId = exports.isValidTraceId = undefined;
|
|
18375
|
-
var invalid_span_constants_1 = require_invalid_span_constants();
|
|
18376
|
-
var NonRecordingSpan_1 = require_NonRecordingSpan();
|
|
18377
|
-
var isHex = new Uint8Array([
|
|
18378
|
-
0,
|
|
18379
|
-
0,
|
|
18380
|
-
0,
|
|
18381
|
-
0,
|
|
18382
|
-
0,
|
|
18383
|
-
0,
|
|
18384
|
-
0,
|
|
18385
|
-
0,
|
|
18386
|
-
0,
|
|
18387
|
-
0,
|
|
18388
|
-
0,
|
|
18389
|
-
0,
|
|
18390
|
-
0,
|
|
18391
|
-
0,
|
|
18392
|
-
0,
|
|
18393
|
-
0,
|
|
18394
|
-
0,
|
|
18395
|
-
0,
|
|
18396
|
-
0,
|
|
18397
|
-
0,
|
|
18398
|
-
0,
|
|
18399
|
-
0,
|
|
18400
|
-
0,
|
|
18401
|
-
0,
|
|
18402
|
-
0,
|
|
18403
|
-
0,
|
|
18404
|
-
0,
|
|
18405
|
-
0,
|
|
18406
|
-
0,
|
|
18407
|
-
0,
|
|
18408
|
-
0,
|
|
18409
|
-
0,
|
|
18410
|
-
0,
|
|
18411
|
-
0,
|
|
18412
|
-
0,
|
|
18413
|
-
0,
|
|
18414
|
-
0,
|
|
18415
|
-
0,
|
|
18416
|
-
0,
|
|
18417
|
-
0,
|
|
18418
|
-
0,
|
|
18419
|
-
0,
|
|
18420
|
-
0,
|
|
18421
|
-
0,
|
|
18422
|
-
0,
|
|
18423
|
-
0,
|
|
18424
|
-
0,
|
|
18425
|
-
0,
|
|
18426
|
-
1,
|
|
18427
|
-
1,
|
|
18428
|
-
1,
|
|
18429
|
-
1,
|
|
18430
|
-
1,
|
|
18431
|
-
1,
|
|
18432
|
-
1,
|
|
18433
|
-
1,
|
|
18434
|
-
1,
|
|
18435
|
-
1,
|
|
18436
|
-
0,
|
|
18437
|
-
0,
|
|
18438
|
-
0,
|
|
18439
|
-
0,
|
|
18440
|
-
0,
|
|
18441
|
-
0,
|
|
18442
|
-
0,
|
|
18443
|
-
1,
|
|
18444
|
-
1,
|
|
18445
|
-
1,
|
|
18446
|
-
1,
|
|
18447
|
-
1,
|
|
18448
|
-
1,
|
|
18449
|
-
0,
|
|
18450
|
-
0,
|
|
18451
|
-
0,
|
|
18452
|
-
0,
|
|
18453
|
-
0,
|
|
18454
|
-
0,
|
|
18455
|
-
0,
|
|
18456
|
-
0,
|
|
18457
|
-
0,
|
|
18458
|
-
0,
|
|
18459
|
-
0,
|
|
18460
|
-
0,
|
|
18461
|
-
0,
|
|
18462
|
-
0,
|
|
18463
|
-
0,
|
|
18464
|
-
0,
|
|
18465
|
-
0,
|
|
18466
|
-
0,
|
|
18467
|
-
0,
|
|
18468
|
-
0,
|
|
18469
|
-
0,
|
|
18470
|
-
0,
|
|
18471
|
-
0,
|
|
18472
|
-
0,
|
|
18473
|
-
0,
|
|
18474
|
-
0,
|
|
18475
|
-
1,
|
|
18476
|
-
1,
|
|
18477
|
-
1,
|
|
18478
|
-
1,
|
|
18479
|
-
1,
|
|
18480
|
-
1
|
|
18481
|
-
]);
|
|
18482
|
-
function isValidHex(id, length) {
|
|
18483
|
-
if (typeof id !== "string" || id.length !== length)
|
|
18484
|
-
return false;
|
|
18485
|
-
let r = 0;
|
|
18486
|
-
for (let i = 0;i < id.length; i += 4) {
|
|
18487
|
-
r += (isHex[id.charCodeAt(i)] | 0) + (isHex[id.charCodeAt(i + 1)] | 0) + (isHex[id.charCodeAt(i + 2)] | 0) + (isHex[id.charCodeAt(i + 3)] | 0);
|
|
18488
|
-
}
|
|
18489
|
-
return r === length;
|
|
18490
|
-
}
|
|
18491
|
-
function isValidTraceId(traceId) {
|
|
18492
|
-
return isValidHex(traceId, 32) && traceId !== invalid_span_constants_1.INVALID_TRACEID;
|
|
18493
|
-
}
|
|
18494
|
-
exports.isValidTraceId = isValidTraceId;
|
|
18495
|
-
function isValidSpanId(spanId) {
|
|
18496
|
-
return isValidHex(spanId, 16) && spanId !== invalid_span_constants_1.INVALID_SPANID;
|
|
18497
|
-
}
|
|
18498
|
-
exports.isValidSpanId = isValidSpanId;
|
|
18499
|
-
function isSpanContextValid(spanContext) {
|
|
18500
|
-
return isValidTraceId(spanContext.traceId) && isValidSpanId(spanContext.spanId);
|
|
18501
|
-
}
|
|
18502
|
-
exports.isSpanContextValid = isSpanContextValid;
|
|
18503
|
-
function wrapSpanContext(spanContext) {
|
|
18504
|
-
return new NonRecordingSpan_1.NonRecordingSpan(spanContext);
|
|
18505
|
-
}
|
|
18506
|
-
exports.wrapSpanContext = wrapSpanContext;
|
|
18507
|
-
});
|
|
18508
|
-
|
|
18509
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/NoopTracer.js
|
|
18510
|
-
var require_NoopTracer = __commonJS((exports) => {
|
|
18511
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18512
|
-
exports.NoopTracer = undefined;
|
|
18513
|
-
var context_1 = require_context2();
|
|
18514
|
-
var context_utils_1 = require_context_utils();
|
|
18515
|
-
var NonRecordingSpan_1 = require_NonRecordingSpan();
|
|
18516
|
-
var spancontext_utils_1 = require_spancontext_utils();
|
|
18517
|
-
var contextApi = context_1.ContextAPI.getInstance();
|
|
18518
|
-
|
|
18519
|
-
class NoopTracer {
|
|
18520
|
-
startSpan(name, options, context = contextApi.active()) {
|
|
18521
|
-
const root = Boolean(options === null || options === undefined ? undefined : options.root);
|
|
18522
|
-
if (root) {
|
|
18523
|
-
return new NonRecordingSpan_1.NonRecordingSpan;
|
|
18524
|
-
}
|
|
18525
|
-
const parentFromContext = context && (0, context_utils_1.getSpanContext)(context);
|
|
18526
|
-
if (isSpanContext(parentFromContext) && (0, spancontext_utils_1.isSpanContextValid)(parentFromContext)) {
|
|
18527
|
-
return new NonRecordingSpan_1.NonRecordingSpan(parentFromContext);
|
|
18528
|
-
} else {
|
|
18529
|
-
return new NonRecordingSpan_1.NonRecordingSpan;
|
|
18530
|
-
}
|
|
18531
|
-
}
|
|
18532
|
-
startActiveSpan(name, arg2, arg3, arg4) {
|
|
18533
|
-
let opts;
|
|
18534
|
-
let ctx;
|
|
18535
|
-
let fn;
|
|
18536
|
-
if (arguments.length < 2) {
|
|
18537
|
-
return;
|
|
18538
|
-
} else if (arguments.length === 2) {
|
|
18539
|
-
fn = arg2;
|
|
18540
|
-
} else if (arguments.length === 3) {
|
|
18541
|
-
opts = arg2;
|
|
18542
|
-
fn = arg3;
|
|
18543
|
-
} else {
|
|
18544
|
-
opts = arg2;
|
|
18545
|
-
ctx = arg3;
|
|
18546
|
-
fn = arg4;
|
|
18547
|
-
}
|
|
18548
|
-
const parentContext = ctx !== null && ctx !== undefined ? ctx : contextApi.active();
|
|
18549
|
-
const span = this.startSpan(name, opts, parentContext);
|
|
18550
|
-
const contextWithSpanSet = (0, context_utils_1.setSpan)(parentContext, span);
|
|
18551
|
-
return contextApi.with(contextWithSpanSet, fn, undefined, span);
|
|
18552
|
-
}
|
|
18553
|
-
}
|
|
18554
|
-
exports.NoopTracer = NoopTracer;
|
|
18555
|
-
function isSpanContext(spanContext) {
|
|
18556
|
-
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";
|
|
18557
|
-
}
|
|
18558
|
-
});
|
|
18559
|
-
|
|
18560
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/ProxyTracer.js
|
|
18561
|
-
var require_ProxyTracer = __commonJS((exports) => {
|
|
18562
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18563
|
-
exports.ProxyTracer = undefined;
|
|
18564
|
-
var NoopTracer_1 = require_NoopTracer();
|
|
18565
|
-
var NOOP_TRACER = new NoopTracer_1.NoopTracer;
|
|
18566
|
-
|
|
18567
|
-
class ProxyTracer {
|
|
18568
|
-
constructor(provider, name, version2, options) {
|
|
18569
|
-
this._provider = provider;
|
|
18570
|
-
this.name = name;
|
|
18571
|
-
this.version = version2;
|
|
18572
|
-
this.options = options;
|
|
18573
|
-
}
|
|
18574
|
-
startSpan(name, options, context) {
|
|
18575
|
-
return this._getTracer().startSpan(name, options, context);
|
|
18576
|
-
}
|
|
18577
|
-
startActiveSpan(_name, _options, _context, _fn) {
|
|
18578
|
-
const tracer = this._getTracer();
|
|
18579
|
-
return Reflect.apply(tracer.startActiveSpan, tracer, arguments);
|
|
18580
|
-
}
|
|
18581
|
-
_getTracer() {
|
|
18582
|
-
if (this._delegate) {
|
|
18583
|
-
return this._delegate;
|
|
18584
|
-
}
|
|
18585
|
-
const tracer = this._provider.getDelegateTracer(this.name, this.version, this.options);
|
|
18586
|
-
if (!tracer) {
|
|
18587
|
-
return NOOP_TRACER;
|
|
18588
|
-
}
|
|
18589
|
-
this._delegate = tracer;
|
|
18590
|
-
return this._delegate;
|
|
18591
|
-
}
|
|
18592
|
-
}
|
|
18593
|
-
exports.ProxyTracer = ProxyTracer;
|
|
18594
|
-
});
|
|
18595
|
-
|
|
18596
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/NoopTracerProvider.js
|
|
18597
|
-
var require_NoopTracerProvider = __commonJS((exports) => {
|
|
18598
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18599
|
-
exports.NoopTracerProvider = undefined;
|
|
18600
|
-
var NoopTracer_1 = require_NoopTracer();
|
|
18601
|
-
|
|
18602
|
-
class NoopTracerProvider {
|
|
18603
|
-
getTracer(_name, _version, _options) {
|
|
18604
|
-
return new NoopTracer_1.NoopTracer;
|
|
18605
|
-
}
|
|
18606
|
-
}
|
|
18607
|
-
exports.NoopTracerProvider = NoopTracerProvider;
|
|
18608
|
-
});
|
|
18609
|
-
|
|
18610
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/ProxyTracerProvider.js
|
|
18611
|
-
var require_ProxyTracerProvider = __commonJS((exports) => {
|
|
18612
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18613
|
-
exports.ProxyTracerProvider = undefined;
|
|
18614
|
-
var ProxyTracer_1 = require_ProxyTracer();
|
|
18615
|
-
var NoopTracerProvider_1 = require_NoopTracerProvider();
|
|
18616
|
-
var NOOP_TRACER_PROVIDER = new NoopTracerProvider_1.NoopTracerProvider;
|
|
18617
|
-
|
|
18618
|
-
class ProxyTracerProvider {
|
|
18619
|
-
getTracer(name, version2, options) {
|
|
18620
|
-
var _a3;
|
|
18621
|
-
return (_a3 = this.getDelegateTracer(name, version2, options)) !== null && _a3 !== undefined ? _a3 : new ProxyTracer_1.ProxyTracer(this, name, version2, options);
|
|
18622
|
-
}
|
|
18623
|
-
getDelegate() {
|
|
18624
|
-
var _a3;
|
|
18625
|
-
return (_a3 = this._delegate) !== null && _a3 !== undefined ? _a3 : NOOP_TRACER_PROVIDER;
|
|
18626
|
-
}
|
|
18627
|
-
setDelegate(delegate) {
|
|
18628
|
-
this._delegate = delegate;
|
|
18629
|
-
}
|
|
18630
|
-
getDelegateTracer(name, version2, options) {
|
|
18631
|
-
var _a3;
|
|
18632
|
-
return (_a3 = this._delegate) === null || _a3 === undefined ? undefined : _a3.getTracer(name, version2, options);
|
|
18633
|
-
}
|
|
18634
|
-
}
|
|
18635
|
-
exports.ProxyTracerProvider = ProxyTracerProvider;
|
|
18636
|
-
});
|
|
18637
|
-
|
|
18638
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/SamplingResult.js
|
|
18639
|
-
var require_SamplingResult = __commonJS((exports) => {
|
|
18640
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18641
|
-
exports.SamplingDecision = undefined;
|
|
18642
|
-
var SamplingDecision;
|
|
18643
|
-
(function(SamplingDecision2) {
|
|
18644
|
-
SamplingDecision2[SamplingDecision2["NOT_RECORD"] = 0] = "NOT_RECORD";
|
|
18645
|
-
SamplingDecision2[SamplingDecision2["RECORD"] = 1] = "RECORD";
|
|
18646
|
-
SamplingDecision2[SamplingDecision2["RECORD_AND_SAMPLED"] = 2] = "RECORD_AND_SAMPLED";
|
|
18647
|
-
})(SamplingDecision = exports.SamplingDecision || (exports.SamplingDecision = {}));
|
|
18648
|
-
});
|
|
18649
|
-
|
|
18650
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/span_kind.js
|
|
18651
|
-
var require_span_kind = __commonJS((exports) => {
|
|
18652
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18653
|
-
exports.SpanKind = undefined;
|
|
18654
|
-
var SpanKind;
|
|
18655
|
-
(function(SpanKind2) {
|
|
18656
|
-
SpanKind2[SpanKind2["INTERNAL"] = 0] = "INTERNAL";
|
|
18657
|
-
SpanKind2[SpanKind2["SERVER"] = 1] = "SERVER";
|
|
18658
|
-
SpanKind2[SpanKind2["CLIENT"] = 2] = "CLIENT";
|
|
18659
|
-
SpanKind2[SpanKind2["PRODUCER"] = 3] = "PRODUCER";
|
|
18660
|
-
SpanKind2[SpanKind2["CONSUMER"] = 4] = "CONSUMER";
|
|
18661
|
-
})(SpanKind = exports.SpanKind || (exports.SpanKind = {}));
|
|
18662
|
-
});
|
|
18663
|
-
|
|
18664
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/status.js
|
|
18665
|
-
var require_status = __commonJS((exports) => {
|
|
18666
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18667
|
-
exports.SpanStatusCode = undefined;
|
|
18668
|
-
var SpanStatusCode;
|
|
18669
|
-
(function(SpanStatusCode2) {
|
|
18670
|
-
SpanStatusCode2[SpanStatusCode2["UNSET"] = 0] = "UNSET";
|
|
18671
|
-
SpanStatusCode2[SpanStatusCode2["OK"] = 1] = "OK";
|
|
18672
|
-
SpanStatusCode2[SpanStatusCode2["ERROR"] = 2] = "ERROR";
|
|
18673
|
-
})(SpanStatusCode = exports.SpanStatusCode || (exports.SpanStatusCode = {}));
|
|
18674
|
-
});
|
|
18675
|
-
|
|
18676
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/internal/tracestate-validators.js
|
|
18677
|
-
var require_tracestate_validators = __commonJS((exports) => {
|
|
18678
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18679
|
-
exports.validateValue = exports.validateKey = undefined;
|
|
18680
|
-
var VALID_KEY_CHAR_RANGE = "[_0-9a-z-*/]";
|
|
18681
|
-
var VALID_KEY = `[a-z]${VALID_KEY_CHAR_RANGE}{0,255}`;
|
|
18682
|
-
var VALID_VENDOR_KEY = `[a-z0-9]${VALID_KEY_CHAR_RANGE}{0,240}@[a-z]${VALID_KEY_CHAR_RANGE}{0,13}`;
|
|
18683
|
-
var VALID_KEY_REGEX = new RegExp(`^(?:${VALID_KEY}|${VALID_VENDOR_KEY})$`);
|
|
18684
|
-
var VALID_VALUE_BASE_REGEX = /^[ -~]{0,255}[!-~]$/;
|
|
18685
|
-
var INVALID_VALUE_COMMA_EQUAL_REGEX = /,|=/;
|
|
18686
|
-
function validateKey(key) {
|
|
18687
|
-
return VALID_KEY_REGEX.test(key);
|
|
18688
|
-
}
|
|
18689
|
-
exports.validateKey = validateKey;
|
|
18690
|
-
function validateValue(value) {
|
|
18691
|
-
return VALID_VALUE_BASE_REGEX.test(value) && !INVALID_VALUE_COMMA_EQUAL_REGEX.test(value);
|
|
18692
|
-
}
|
|
18693
|
-
exports.validateValue = validateValue;
|
|
18694
|
-
});
|
|
18695
|
-
|
|
18696
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/internal/tracestate-impl.js
|
|
18697
|
-
var require_tracestate_impl = __commonJS((exports) => {
|
|
18698
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18699
|
-
exports.TraceStateImpl = undefined;
|
|
18700
|
-
var tracestate_validators_1 = require_tracestate_validators();
|
|
18701
|
-
var MAX_TRACE_STATE_ITEMS = 32;
|
|
18702
|
-
var MAX_TRACE_STATE_LEN = 512;
|
|
18703
|
-
var LIST_MEMBERS_SEPARATOR = ",";
|
|
18704
|
-
var LIST_MEMBER_KEY_VALUE_SPLITTER = "=";
|
|
18705
|
-
|
|
18706
|
-
class TraceStateImpl {
|
|
18707
|
-
constructor(rawTraceState) {
|
|
18708
|
-
this._internalState = new Map;
|
|
18709
|
-
if (rawTraceState)
|
|
18710
|
-
this._parse(rawTraceState);
|
|
18711
|
-
}
|
|
18712
|
-
set(key, value) {
|
|
18713
|
-
const traceState = this._clone();
|
|
18714
|
-
if (traceState._internalState.has(key)) {
|
|
18715
|
-
traceState._internalState.delete(key);
|
|
18716
|
-
}
|
|
18717
|
-
traceState._internalState.set(key, value);
|
|
18718
|
-
return traceState;
|
|
18719
|
-
}
|
|
18720
|
-
unset(key) {
|
|
18721
|
-
const traceState = this._clone();
|
|
18722
|
-
traceState._internalState.delete(key);
|
|
18723
|
-
return traceState;
|
|
18724
|
-
}
|
|
18725
|
-
get(key) {
|
|
18726
|
-
return this._internalState.get(key);
|
|
18727
|
-
}
|
|
18728
|
-
serialize() {
|
|
18729
|
-
return Array.from(this._internalState.keys()).reduceRight((agg, key) => {
|
|
18730
|
-
agg.push(key + LIST_MEMBER_KEY_VALUE_SPLITTER + this.get(key));
|
|
18731
|
-
return agg;
|
|
18732
|
-
}, []).join(LIST_MEMBERS_SEPARATOR);
|
|
18733
|
-
}
|
|
18734
|
-
_parse(rawTraceState) {
|
|
18735
|
-
if (rawTraceState.length > MAX_TRACE_STATE_LEN)
|
|
18736
|
-
return;
|
|
18737
|
-
this._internalState = rawTraceState.split(LIST_MEMBERS_SEPARATOR).reduceRight((agg, part) => {
|
|
18738
|
-
const listMember = part.trim();
|
|
18739
|
-
const i = listMember.indexOf(LIST_MEMBER_KEY_VALUE_SPLITTER);
|
|
18740
|
-
if (i !== -1) {
|
|
18741
|
-
const key = listMember.slice(0, i);
|
|
18742
|
-
const value = listMember.slice(i + 1, part.length);
|
|
18743
|
-
if ((0, tracestate_validators_1.validateKey)(key) && (0, tracestate_validators_1.validateValue)(value)) {
|
|
18744
|
-
agg.set(key, value);
|
|
18745
|
-
}
|
|
18746
|
-
}
|
|
18747
|
-
return agg;
|
|
18748
|
-
}, new Map);
|
|
18749
|
-
if (this._internalState.size > MAX_TRACE_STATE_ITEMS) {
|
|
18750
|
-
this._internalState = new Map(Array.from(this._internalState.entries()).reverse().slice(0, MAX_TRACE_STATE_ITEMS));
|
|
18751
|
-
}
|
|
18752
|
-
}
|
|
18753
|
-
_keys() {
|
|
18754
|
-
return Array.from(this._internalState.keys()).reverse();
|
|
18755
|
-
}
|
|
18756
|
-
_clone() {
|
|
18757
|
-
const traceState = new TraceStateImpl;
|
|
18758
|
-
traceState._internalState = new Map(this._internalState);
|
|
18759
|
-
return traceState;
|
|
18760
|
-
}
|
|
18761
|
-
}
|
|
18762
|
-
exports.TraceStateImpl = TraceStateImpl;
|
|
18763
|
-
});
|
|
18764
|
-
|
|
18765
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace/internal/utils.js
|
|
18766
|
-
var require_utils2 = __commonJS((exports) => {
|
|
18767
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18768
|
-
exports.createTraceState = undefined;
|
|
18769
|
-
var tracestate_impl_1 = require_tracestate_impl();
|
|
18770
|
-
function createTraceState(rawTraceState) {
|
|
18771
|
-
return new tracestate_impl_1.TraceStateImpl(rawTraceState);
|
|
18772
|
-
}
|
|
18773
|
-
exports.createTraceState = createTraceState;
|
|
18774
|
-
});
|
|
18775
|
-
|
|
18776
|
-
// ../../node_modules/@opentelemetry/api/build/src/context-api.js
|
|
18777
|
-
var require_context_api = __commonJS((exports) => {
|
|
18778
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18779
|
-
exports.context = undefined;
|
|
18780
|
-
var context_1 = require_context2();
|
|
18781
|
-
exports.context = context_1.ContextAPI.getInstance();
|
|
18782
|
-
});
|
|
18783
|
-
|
|
18784
|
-
// ../../node_modules/@opentelemetry/api/build/src/diag-api.js
|
|
18785
|
-
var require_diag_api = __commonJS((exports) => {
|
|
18786
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18787
|
-
exports.diag = undefined;
|
|
18788
|
-
var diag_1 = require_diag();
|
|
18789
|
-
exports.diag = diag_1.DiagAPI.instance();
|
|
18790
|
-
});
|
|
18791
|
-
|
|
18792
|
-
// ../../node_modules/@opentelemetry/api/build/src/metrics/NoopMeterProvider.js
|
|
18793
|
-
var require_NoopMeterProvider = __commonJS((exports) => {
|
|
18794
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18795
|
-
exports.NOOP_METER_PROVIDER = exports.NoopMeterProvider = undefined;
|
|
18796
|
-
var NoopMeter_1 = require_NoopMeter();
|
|
18797
|
-
|
|
18798
|
-
class NoopMeterProvider {
|
|
18799
|
-
getMeter(_name, _version, _options) {
|
|
18800
|
-
return NoopMeter_1.NOOP_METER;
|
|
18801
|
-
}
|
|
18802
|
-
}
|
|
18803
|
-
exports.NoopMeterProvider = NoopMeterProvider;
|
|
18804
|
-
exports.NOOP_METER_PROVIDER = new NoopMeterProvider;
|
|
18805
|
-
});
|
|
18806
|
-
|
|
18807
|
-
// ../../node_modules/@opentelemetry/api/build/src/api/metrics.js
|
|
18808
|
-
var require_metrics = __commonJS((exports) => {
|
|
18809
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18810
|
-
exports.MetricsAPI = undefined;
|
|
18811
|
-
var NoopMeterProvider_1 = require_NoopMeterProvider();
|
|
18812
|
-
var global_utils_1 = require_global_utils();
|
|
18813
|
-
var diag_1 = require_diag();
|
|
18814
|
-
var API_NAME = "metrics";
|
|
18815
|
-
|
|
18816
|
-
class MetricsAPI {
|
|
18817
|
-
constructor() {}
|
|
18818
|
-
static getInstance() {
|
|
18819
|
-
if (!this._instance) {
|
|
18820
|
-
this._instance = new MetricsAPI;
|
|
18821
|
-
}
|
|
18822
|
-
return this._instance;
|
|
18823
|
-
}
|
|
18824
|
-
setGlobalMeterProvider(provider) {
|
|
18825
|
-
return (0, global_utils_1.registerGlobal)(API_NAME, provider, diag_1.DiagAPI.instance());
|
|
18826
|
-
}
|
|
18827
|
-
getMeterProvider() {
|
|
18828
|
-
return (0, global_utils_1.getGlobal)(API_NAME) || NoopMeterProvider_1.NOOP_METER_PROVIDER;
|
|
18829
|
-
}
|
|
18830
|
-
getMeter(name, version2, options) {
|
|
18831
|
-
return this.getMeterProvider().getMeter(name, version2, options);
|
|
18832
|
-
}
|
|
18833
|
-
disable() {
|
|
18834
|
-
(0, global_utils_1.unregisterGlobal)(API_NAME, diag_1.DiagAPI.instance());
|
|
18835
|
-
}
|
|
18836
|
-
}
|
|
18837
|
-
exports.MetricsAPI = MetricsAPI;
|
|
18838
|
-
});
|
|
18839
|
-
|
|
18840
|
-
// ../../node_modules/@opentelemetry/api/build/src/metrics-api.js
|
|
18841
|
-
var require_metrics_api = __commonJS((exports) => {
|
|
18842
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18843
|
-
exports.metrics = undefined;
|
|
18844
|
-
var metrics_1 = require_metrics();
|
|
18845
|
-
exports.metrics = metrics_1.MetricsAPI.getInstance();
|
|
18846
|
-
});
|
|
18847
|
-
|
|
18848
|
-
// ../../node_modules/@opentelemetry/api/build/src/propagation/NoopTextMapPropagator.js
|
|
18849
|
-
var require_NoopTextMapPropagator = __commonJS((exports) => {
|
|
18850
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18851
|
-
exports.NoopTextMapPropagator = undefined;
|
|
18852
|
-
|
|
18853
|
-
class NoopTextMapPropagator {
|
|
18854
|
-
inject(_context, _carrier) {}
|
|
18855
|
-
extract(context, _carrier) {
|
|
18856
|
-
return context;
|
|
18857
|
-
}
|
|
18858
|
-
fields() {
|
|
18859
|
-
return [];
|
|
18860
|
-
}
|
|
18861
|
-
}
|
|
18862
|
-
exports.NoopTextMapPropagator = NoopTextMapPropagator;
|
|
18863
|
-
});
|
|
18864
|
-
|
|
18865
|
-
// ../../node_modules/@opentelemetry/api/build/src/baggage/context-helpers.js
|
|
18866
|
-
var require_context_helpers = __commonJS((exports) => {
|
|
18867
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18868
|
-
exports.deleteBaggage = exports.setBaggage = exports.getActiveBaggage = exports.getBaggage = undefined;
|
|
18869
|
-
var context_1 = require_context2();
|
|
18870
|
-
var context_2 = require_context();
|
|
18871
|
-
var BAGGAGE_KEY = (0, context_2.createContextKey)("OpenTelemetry Baggage Key");
|
|
18872
|
-
function getBaggage(context) {
|
|
18873
|
-
return context.getValue(BAGGAGE_KEY) || undefined;
|
|
18874
|
-
}
|
|
18875
|
-
exports.getBaggage = getBaggage;
|
|
18876
|
-
function getActiveBaggage() {
|
|
18877
|
-
return getBaggage(context_1.ContextAPI.getInstance().active());
|
|
18878
|
-
}
|
|
18879
|
-
exports.getActiveBaggage = getActiveBaggage;
|
|
18880
|
-
function setBaggage(context, baggage) {
|
|
18881
|
-
return context.setValue(BAGGAGE_KEY, baggage);
|
|
18882
|
-
}
|
|
18883
|
-
exports.setBaggage = setBaggage;
|
|
18884
|
-
function deleteBaggage(context) {
|
|
18885
|
-
return context.deleteValue(BAGGAGE_KEY);
|
|
18886
|
-
}
|
|
18887
|
-
exports.deleteBaggage = deleteBaggage;
|
|
18888
|
-
});
|
|
18889
|
-
|
|
18890
|
-
// ../../node_modules/@opentelemetry/api/build/src/api/propagation.js
|
|
18891
|
-
var require_propagation = __commonJS((exports) => {
|
|
18892
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18893
|
-
exports.PropagationAPI = undefined;
|
|
18894
|
-
var global_utils_1 = require_global_utils();
|
|
18895
|
-
var NoopTextMapPropagator_1 = require_NoopTextMapPropagator();
|
|
18896
|
-
var TextMapPropagator_1 = require_TextMapPropagator();
|
|
18897
|
-
var context_helpers_1 = require_context_helpers();
|
|
18898
|
-
var utils_1 = require_utils();
|
|
18899
|
-
var diag_1 = require_diag();
|
|
18900
|
-
var API_NAME = "propagation";
|
|
18901
|
-
var NOOP_TEXT_MAP_PROPAGATOR = new NoopTextMapPropagator_1.NoopTextMapPropagator;
|
|
18902
|
-
|
|
18903
|
-
class PropagationAPI {
|
|
18904
|
-
constructor() {
|
|
18905
|
-
this.createBaggage = utils_1.createBaggage;
|
|
18906
|
-
this.getBaggage = context_helpers_1.getBaggage;
|
|
18907
|
-
this.getActiveBaggage = context_helpers_1.getActiveBaggage;
|
|
18908
|
-
this.setBaggage = context_helpers_1.setBaggage;
|
|
18909
|
-
this.deleteBaggage = context_helpers_1.deleteBaggage;
|
|
18910
|
-
}
|
|
18911
|
-
static getInstance() {
|
|
18912
|
-
if (!this._instance) {
|
|
18913
|
-
this._instance = new PropagationAPI;
|
|
18914
|
-
}
|
|
18915
|
-
return this._instance;
|
|
18916
|
-
}
|
|
18917
|
-
setGlobalPropagator(propagator) {
|
|
18918
|
-
return (0, global_utils_1.registerGlobal)(API_NAME, propagator, diag_1.DiagAPI.instance());
|
|
18919
|
-
}
|
|
18920
|
-
inject(context, carrier, setter = TextMapPropagator_1.defaultTextMapSetter) {
|
|
18921
|
-
return this._getGlobalPropagator().inject(context, carrier, setter);
|
|
18922
|
-
}
|
|
18923
|
-
extract(context, carrier, getter = TextMapPropagator_1.defaultTextMapGetter) {
|
|
18924
|
-
return this._getGlobalPropagator().extract(context, carrier, getter);
|
|
18925
|
-
}
|
|
18926
|
-
fields() {
|
|
18927
|
-
return this._getGlobalPropagator().fields();
|
|
18928
|
-
}
|
|
18929
|
-
disable() {
|
|
18930
|
-
(0, global_utils_1.unregisterGlobal)(API_NAME, diag_1.DiagAPI.instance());
|
|
18931
|
-
}
|
|
18932
|
-
_getGlobalPropagator() {
|
|
18933
|
-
return (0, global_utils_1.getGlobal)(API_NAME) || NOOP_TEXT_MAP_PROPAGATOR;
|
|
18934
|
-
}
|
|
18935
|
-
}
|
|
18936
|
-
exports.PropagationAPI = PropagationAPI;
|
|
18937
|
-
});
|
|
18938
|
-
|
|
18939
|
-
// ../../node_modules/@opentelemetry/api/build/src/propagation-api.js
|
|
18940
|
-
var require_propagation_api = __commonJS((exports) => {
|
|
18941
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18942
|
-
exports.propagation = undefined;
|
|
18943
|
-
var propagation_1 = require_propagation();
|
|
18944
|
-
exports.propagation = propagation_1.PropagationAPI.getInstance();
|
|
18945
|
-
});
|
|
18946
|
-
|
|
18947
|
-
// ../../node_modules/@opentelemetry/api/build/src/api/trace.js
|
|
18948
|
-
var require_trace = __commonJS((exports) => {
|
|
18949
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18950
|
-
exports.TraceAPI = undefined;
|
|
18951
|
-
var global_utils_1 = require_global_utils();
|
|
18952
|
-
var ProxyTracerProvider_1 = require_ProxyTracerProvider();
|
|
18953
|
-
var spancontext_utils_1 = require_spancontext_utils();
|
|
18954
|
-
var context_utils_1 = require_context_utils();
|
|
18955
|
-
var diag_1 = require_diag();
|
|
18956
|
-
var API_NAME = "trace";
|
|
18957
|
-
|
|
18958
|
-
class TraceAPI {
|
|
18959
|
-
constructor() {
|
|
18960
|
-
this._proxyTracerProvider = new ProxyTracerProvider_1.ProxyTracerProvider;
|
|
18961
|
-
this.wrapSpanContext = spancontext_utils_1.wrapSpanContext;
|
|
18962
|
-
this.isSpanContextValid = spancontext_utils_1.isSpanContextValid;
|
|
18963
|
-
this.deleteSpan = context_utils_1.deleteSpan;
|
|
18964
|
-
this.getSpan = context_utils_1.getSpan;
|
|
18965
|
-
this.getActiveSpan = context_utils_1.getActiveSpan;
|
|
18966
|
-
this.getSpanContext = context_utils_1.getSpanContext;
|
|
18967
|
-
this.setSpan = context_utils_1.setSpan;
|
|
18968
|
-
this.setSpanContext = context_utils_1.setSpanContext;
|
|
18969
|
-
}
|
|
18970
|
-
static getInstance() {
|
|
18971
|
-
if (!this._instance) {
|
|
18972
|
-
this._instance = new TraceAPI;
|
|
18973
|
-
}
|
|
18974
|
-
return this._instance;
|
|
18975
|
-
}
|
|
18976
|
-
setGlobalTracerProvider(provider) {
|
|
18977
|
-
const success3 = (0, global_utils_1.registerGlobal)(API_NAME, this._proxyTracerProvider, diag_1.DiagAPI.instance());
|
|
18978
|
-
if (success3) {
|
|
18979
|
-
this._proxyTracerProvider.setDelegate(provider);
|
|
18980
|
-
}
|
|
18981
|
-
return success3;
|
|
18982
|
-
}
|
|
18983
|
-
getTracerProvider() {
|
|
18984
|
-
return (0, global_utils_1.getGlobal)(API_NAME) || this._proxyTracerProvider;
|
|
18985
|
-
}
|
|
18986
|
-
getTracer(name, version2) {
|
|
18987
|
-
return this.getTracerProvider().getTracer(name, version2);
|
|
18988
|
-
}
|
|
18989
|
-
disable() {
|
|
18990
|
-
(0, global_utils_1.unregisterGlobal)(API_NAME, diag_1.DiagAPI.instance());
|
|
18991
|
-
this._proxyTracerProvider = new ProxyTracerProvider_1.ProxyTracerProvider;
|
|
18992
|
-
}
|
|
18993
|
-
}
|
|
18994
|
-
exports.TraceAPI = TraceAPI;
|
|
18995
|
-
});
|
|
18996
|
-
|
|
18997
|
-
// ../../node_modules/@opentelemetry/api/build/src/trace-api.js
|
|
18998
|
-
var require_trace_api = __commonJS((exports) => {
|
|
18999
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
19000
|
-
exports.trace = undefined;
|
|
19001
|
-
var trace_1 = require_trace();
|
|
19002
|
-
exports.trace = trace_1.TraceAPI.getInstance();
|
|
19003
|
-
});
|
|
19004
|
-
|
|
19005
|
-
// ../../node_modules/@opentelemetry/api/build/src/index.js
|
|
19006
|
-
var require_src = __commonJS((exports) => {
|
|
19007
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
19008
|
-
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;
|
|
19009
|
-
var utils_1 = require_utils();
|
|
19010
|
-
Object.defineProperty(exports, "baggageEntryMetadataFromString", { enumerable: true, get: function() {
|
|
19011
|
-
return utils_1.baggageEntryMetadataFromString;
|
|
19012
|
-
} });
|
|
19013
|
-
var context_1 = require_context();
|
|
19014
|
-
Object.defineProperty(exports, "createContextKey", { enumerable: true, get: function() {
|
|
19015
|
-
return context_1.createContextKey;
|
|
19016
|
-
} });
|
|
19017
|
-
Object.defineProperty(exports, "ROOT_CONTEXT", { enumerable: true, get: function() {
|
|
19018
|
-
return context_1.ROOT_CONTEXT;
|
|
19019
|
-
} });
|
|
19020
|
-
var consoleLogger_1 = require_consoleLogger();
|
|
19021
|
-
Object.defineProperty(exports, "DiagConsoleLogger", { enumerable: true, get: function() {
|
|
19022
|
-
return consoleLogger_1.DiagConsoleLogger;
|
|
19023
|
-
} });
|
|
19024
|
-
var types_1 = require_types();
|
|
19025
|
-
Object.defineProperty(exports, "DiagLogLevel", { enumerable: true, get: function() {
|
|
19026
|
-
return types_1.DiagLogLevel;
|
|
19027
|
-
} });
|
|
19028
|
-
var NoopMeter_1 = require_NoopMeter();
|
|
19029
|
-
Object.defineProperty(exports, "createNoopMeter", { enumerable: true, get: function() {
|
|
19030
|
-
return NoopMeter_1.createNoopMeter;
|
|
19031
|
-
} });
|
|
19032
|
-
var Metric_1 = require_Metric();
|
|
19033
|
-
Object.defineProperty(exports, "ValueType", { enumerable: true, get: function() {
|
|
19034
|
-
return Metric_1.ValueType;
|
|
19035
|
-
} });
|
|
19036
|
-
var TextMapPropagator_1 = require_TextMapPropagator();
|
|
19037
|
-
Object.defineProperty(exports, "defaultTextMapGetter", { enumerable: true, get: function() {
|
|
19038
|
-
return TextMapPropagator_1.defaultTextMapGetter;
|
|
19039
|
-
} });
|
|
19040
|
-
Object.defineProperty(exports, "defaultTextMapSetter", { enumerable: true, get: function() {
|
|
19041
|
-
return TextMapPropagator_1.defaultTextMapSetter;
|
|
19042
|
-
} });
|
|
19043
|
-
var ProxyTracer_1 = require_ProxyTracer();
|
|
19044
|
-
Object.defineProperty(exports, "ProxyTracer", { enumerable: true, get: function() {
|
|
19045
|
-
return ProxyTracer_1.ProxyTracer;
|
|
19046
|
-
} });
|
|
19047
|
-
var ProxyTracerProvider_1 = require_ProxyTracerProvider();
|
|
19048
|
-
Object.defineProperty(exports, "ProxyTracerProvider", { enumerable: true, get: function() {
|
|
19049
|
-
return ProxyTracerProvider_1.ProxyTracerProvider;
|
|
19050
|
-
} });
|
|
19051
|
-
var SamplingResult_1 = require_SamplingResult();
|
|
19052
|
-
Object.defineProperty(exports, "SamplingDecision", { enumerable: true, get: function() {
|
|
19053
|
-
return SamplingResult_1.SamplingDecision;
|
|
19054
|
-
} });
|
|
19055
|
-
var span_kind_1 = require_span_kind();
|
|
19056
|
-
Object.defineProperty(exports, "SpanKind", { enumerable: true, get: function() {
|
|
19057
|
-
return span_kind_1.SpanKind;
|
|
19058
|
-
} });
|
|
19059
|
-
var status_1 = require_status();
|
|
19060
|
-
Object.defineProperty(exports, "SpanStatusCode", { enumerable: true, get: function() {
|
|
19061
|
-
return status_1.SpanStatusCode;
|
|
19062
|
-
} });
|
|
19063
|
-
var trace_flags_1 = require_trace_flags();
|
|
19064
|
-
Object.defineProperty(exports, "TraceFlags", { enumerable: true, get: function() {
|
|
19065
|
-
return trace_flags_1.TraceFlags;
|
|
19066
|
-
} });
|
|
19067
|
-
var utils_2 = require_utils2();
|
|
19068
|
-
Object.defineProperty(exports, "createTraceState", { enumerable: true, get: function() {
|
|
19069
|
-
return utils_2.createTraceState;
|
|
19070
|
-
} });
|
|
19071
|
-
var spancontext_utils_1 = require_spancontext_utils();
|
|
19072
|
-
Object.defineProperty(exports, "isSpanContextValid", { enumerable: true, get: function() {
|
|
19073
|
-
return spancontext_utils_1.isSpanContextValid;
|
|
19074
|
-
} });
|
|
19075
|
-
Object.defineProperty(exports, "isValidTraceId", { enumerable: true, get: function() {
|
|
19076
|
-
return spancontext_utils_1.isValidTraceId;
|
|
19077
|
-
} });
|
|
19078
|
-
Object.defineProperty(exports, "isValidSpanId", { enumerable: true, get: function() {
|
|
19079
|
-
return spancontext_utils_1.isValidSpanId;
|
|
19080
|
-
} });
|
|
19081
|
-
var invalid_span_constants_1 = require_invalid_span_constants();
|
|
19082
|
-
Object.defineProperty(exports, "INVALID_SPANID", { enumerable: true, get: function() {
|
|
19083
|
-
return invalid_span_constants_1.INVALID_SPANID;
|
|
19084
|
-
} });
|
|
19085
|
-
Object.defineProperty(exports, "INVALID_TRACEID", { enumerable: true, get: function() {
|
|
19086
|
-
return invalid_span_constants_1.INVALID_TRACEID;
|
|
19087
|
-
} });
|
|
19088
|
-
Object.defineProperty(exports, "INVALID_SPAN_CONTEXT", { enumerable: true, get: function() {
|
|
19089
|
-
return invalid_span_constants_1.INVALID_SPAN_CONTEXT;
|
|
19090
|
-
} });
|
|
19091
|
-
var context_api_1 = require_context_api();
|
|
19092
|
-
Object.defineProperty(exports, "context", { enumerable: true, get: function() {
|
|
19093
|
-
return context_api_1.context;
|
|
19094
|
-
} });
|
|
19095
|
-
var diag_api_1 = require_diag_api();
|
|
19096
|
-
Object.defineProperty(exports, "diag", { enumerable: true, get: function() {
|
|
19097
|
-
return diag_api_1.diag;
|
|
19098
|
-
} });
|
|
19099
|
-
var metrics_api_1 = require_metrics_api();
|
|
19100
|
-
Object.defineProperty(exports, "metrics", { enumerable: true, get: function() {
|
|
19101
|
-
return metrics_api_1.metrics;
|
|
19102
|
-
} });
|
|
19103
|
-
var propagation_api_1 = require_propagation_api();
|
|
19104
|
-
Object.defineProperty(exports, "propagation", { enumerable: true, get: function() {
|
|
19105
|
-
return propagation_api_1.propagation;
|
|
19106
|
-
} });
|
|
19107
|
-
var trace_api_1 = require_trace_api();
|
|
19108
|
-
Object.defineProperty(exports, "trace", { enumerable: true, get: function() {
|
|
19109
|
-
return trace_api_1.trace;
|
|
19110
|
-
} });
|
|
19111
|
-
exports.default = {
|
|
19112
|
-
context: context_api_1.context,
|
|
19113
|
-
diag: diag_api_1.diag,
|
|
19114
|
-
metrics: metrics_api_1.metrics,
|
|
19115
|
-
propagation: propagation_api_1.propagation,
|
|
19116
|
-
trace: trace_api_1.trace
|
|
19117
|
-
};
|
|
19118
|
-
});
|
|
19119
|
-
|
|
19120
|
-
// ../types/src/processor/processor.ts
|
|
19121
|
-
var import_api, noopTracingContext, ProcessorPortSchema, ProcessorDefinitionSchema, ProcessorExecutionContextSchema, TraceStatus;
|
|
19122
|
-
var init_processor = __esm(() => {
|
|
19123
|
-
init_zod();
|
|
19124
|
-
init_common();
|
|
19125
|
-
import_api = __toESM(require_src(), 1);
|
|
19126
|
-
noopTracingContext = {
|
|
19127
|
-
traceId: "",
|
|
19128
|
-
getActiveSpan() {
|
|
19129
|
-
return;
|
|
19130
|
-
},
|
|
19131
|
-
async withSpan(_name, _options, fn) {
|
|
19132
|
-
const noopSpan = {
|
|
19133
|
-
spanContext: () => ({
|
|
19134
|
-
traceId: "",
|
|
19135
|
-
spanId: "",
|
|
19136
|
-
traceFlags: 0
|
|
19137
|
-
}),
|
|
19138
|
-
setAttribute: () => noopSpan,
|
|
19139
|
-
setAttributes: () => noopSpan,
|
|
19140
|
-
addEvent: () => noopSpan,
|
|
19141
|
-
addLink: () => noopSpan,
|
|
19142
|
-
addLinks: () => noopSpan,
|
|
19143
|
-
setStatus: () => noopSpan,
|
|
19144
|
-
updateName: () => noopSpan,
|
|
19145
|
-
end: () => {},
|
|
19146
|
-
isRecording: () => false,
|
|
19147
|
-
recordException: () => {}
|
|
19148
|
-
};
|
|
19149
|
-
return fn(noopSpan);
|
|
19150
|
-
}
|
|
19151
|
-
};
|
|
19152
|
-
ProcessorPortSchema = exports_external.object({
|
|
19153
|
-
name: exports_external.string(),
|
|
19154
|
-
schema: JsonSchemaSchema,
|
|
19155
|
-
required: exports_external.boolean().default(true)
|
|
19156
|
-
});
|
|
19157
|
-
ProcessorDefinitionSchema = exports_external.object({
|
|
19158
|
-
id: exports_external.string(),
|
|
19159
|
-
name: exports_external.string(),
|
|
19160
|
-
description: exports_external.string().optional(),
|
|
19161
|
-
inputSchema: JsonSchemaSchema,
|
|
19162
|
-
outputSchema: JsonSchemaSchema,
|
|
19163
|
-
configSchema: JsonSchemaSchema.optional(),
|
|
19164
|
-
inputPorts: exports_external.array(ProcessorPortSchema).optional(),
|
|
19165
|
-
outputPorts: exports_external.array(ProcessorPortSchema).optional(),
|
|
19166
|
-
isBuiltin: exports_external.boolean().default(true),
|
|
19167
|
-
pluginName: exports_external.string().optional()
|
|
19168
|
-
});
|
|
19169
|
-
ProcessorExecutionContextSchema = exports_external.object({
|
|
19170
|
-
jobId: exports_external.string(),
|
|
19171
|
-
stepId: exports_external.string(),
|
|
19172
|
-
tenantId: exports_external.string(),
|
|
19173
|
-
automationId: exports_external.string().optional(),
|
|
19174
|
-
workflowId: exports_external.string(),
|
|
19175
|
-
workerId: exports_external.string().optional()
|
|
19176
|
-
});
|
|
19177
|
-
((TraceStatus2) => {
|
|
19178
|
-
TraceStatus2["PENDING"] = "pending";
|
|
19179
|
-
TraceStatus2["RUNNING"] = "running";
|
|
19180
|
-
TraceStatus2["COMPLETED"] = "completed";
|
|
19181
|
-
TraceStatus2["FAILED"] = "failed";
|
|
19182
|
-
})(TraceStatus ||= {});
|
|
19183
|
-
});
|
|
19184
|
-
|
|
19185
|
-
// ../types/src/processor/normalize-extract-input.ts
|
|
19186
|
-
function normalizeExtractInputToText(input) {
|
|
19187
|
-
if (typeof input === "string") {
|
|
19188
|
-
return input;
|
|
19189
|
-
}
|
|
19190
|
-
if (input && typeof input === "object") {
|
|
19191
|
-
const obj = input;
|
|
19192
|
-
if (typeof obj.content === "string") {
|
|
19193
|
-
return obj.content;
|
|
19194
|
-
}
|
|
19195
|
-
if (typeof obj.text === "string") {
|
|
19196
|
-
return obj.text;
|
|
19197
|
-
}
|
|
19198
|
-
return JSON.stringify(input, null, 2);
|
|
19199
|
-
}
|
|
19200
|
-
return String(input ?? "");
|
|
19201
|
-
}
|
|
19202
|
-
function extractSourceTextFromResolvedConfig(config2) {
|
|
19203
|
-
if (!config2 || typeof config2 !== "object")
|
|
19204
|
-
return null;
|
|
19205
|
-
if (typeof config2.content === "string") {
|
|
19206
|
-
return normalizeExtractInputToText({ content: config2.content });
|
|
19207
|
-
}
|
|
19208
|
-
if (typeof config2.text === "string") {
|
|
19209
|
-
return normalizeExtractInputToText({ text: config2.text });
|
|
19210
|
-
}
|
|
19211
|
-
if (typeof config2.input === "string") {
|
|
19212
|
-
return normalizeExtractInputToText({ content: config2.input });
|
|
19213
|
-
}
|
|
19214
|
-
if (config2.input !== null && config2.input !== undefined) {
|
|
19215
|
-
return normalizeExtractInputToText(config2.input);
|
|
19216
|
-
}
|
|
19217
|
-
return null;
|
|
19218
|
-
}
|
|
19219
|
-
|
|
19220
|
-
// ../types/src/processor/grounding.ts
|
|
19221
|
-
function stripGroundingMetadata(value) {
|
|
19222
|
-
if (Array.isArray(value))
|
|
19223
|
-
return value.map(stripGroundingMetadata);
|
|
19224
|
-
if (value && typeof value === "object") {
|
|
19225
|
-
const out = {};
|
|
19226
|
-
for (const [k, v] of Object.entries(value)) {
|
|
19227
|
-
if (k === "_grounding")
|
|
19228
|
-
continue;
|
|
19229
|
-
out[k] = stripGroundingMetadata(v);
|
|
19230
|
-
}
|
|
19231
|
-
return out;
|
|
19232
|
-
}
|
|
19233
|
-
return value;
|
|
19234
|
-
}
|
|
19235
|
-
|
|
19236
|
-
// ../types/src/processor/execution.ts
|
|
19237
|
-
function asTuple(values) {
|
|
19238
|
-
return values;
|
|
19239
|
-
}
|
|
19240
|
-
var WorkflowExecutionStatusValue, WorkflowExecutionStatusSchema, StepExecutionStatusValue, StepExecutionStatusSchema, TriggerTypeValue, TriggerTypeSchema, ExecutionTypeValue, ExecutionTypeSchema, WORKFLOW_EXECUTION_STATUSES, STEP_EXECUTION_STATUSES, TRIGGER_TYPES, EXECUTION_TYPES;
|
|
19241
|
-
var init_execution = __esm(() => {
|
|
19242
|
-
init_zod();
|
|
19243
|
-
WorkflowExecutionStatusValue = {
|
|
19244
|
-
CREATED: "created",
|
|
19245
|
-
PENDING: "pending",
|
|
19246
|
-
RUNNING: "running",
|
|
19247
|
-
WAITING: "waiting",
|
|
19248
|
-
COMPLETED: "completed",
|
|
19249
|
-
FAILED: "failed",
|
|
19250
|
-
CANCELLED: "cancelled"
|
|
19251
|
-
};
|
|
19252
|
-
WorkflowExecutionStatusSchema = exports_external.enum([
|
|
19253
|
-
WorkflowExecutionStatusValue.CREATED,
|
|
19254
|
-
WorkflowExecutionStatusValue.PENDING,
|
|
19255
|
-
WorkflowExecutionStatusValue.RUNNING,
|
|
19256
|
-
WorkflowExecutionStatusValue.WAITING,
|
|
19257
|
-
WorkflowExecutionStatusValue.COMPLETED,
|
|
19258
|
-
WorkflowExecutionStatusValue.FAILED,
|
|
19259
|
-
WorkflowExecutionStatusValue.CANCELLED
|
|
19260
|
-
]);
|
|
19261
|
-
StepExecutionStatusValue = {
|
|
19262
|
-
PENDING: "pending",
|
|
19263
|
-
RUNNING: "running",
|
|
19264
|
-
SUCCESS: "success",
|
|
19265
|
-
FAILURE: "failure",
|
|
19266
|
-
WAITING: "waiting",
|
|
19267
|
-
SKIPPED: "skipped"
|
|
19268
|
-
};
|
|
19269
|
-
StepExecutionStatusSchema = exports_external.enum([
|
|
19270
|
-
StepExecutionStatusValue.PENDING,
|
|
19271
|
-
StepExecutionStatusValue.RUNNING,
|
|
19272
|
-
StepExecutionStatusValue.SUCCESS,
|
|
19273
|
-
StepExecutionStatusValue.FAILURE,
|
|
19274
|
-
StepExecutionStatusValue.WAITING,
|
|
19275
|
-
StepExecutionStatusValue.SKIPPED
|
|
19276
|
-
]);
|
|
19277
|
-
TriggerTypeValue = {
|
|
19278
|
-
MANUAL: "manual",
|
|
19279
|
-
API: "api",
|
|
19280
|
-
WEBHOOK: "webhook",
|
|
19281
|
-
SCHEDULE: "schedule",
|
|
19282
|
-
EMAIL: "email",
|
|
19283
|
-
EVAL: "eval",
|
|
19284
|
-
CLI: "cli"
|
|
19285
|
-
};
|
|
19286
|
-
TriggerTypeSchema = exports_external.enum([
|
|
19287
|
-
TriggerTypeValue.MANUAL,
|
|
19288
|
-
TriggerTypeValue.API,
|
|
19289
|
-
TriggerTypeValue.WEBHOOK,
|
|
19290
|
-
TriggerTypeValue.SCHEDULE,
|
|
19291
|
-
TriggerTypeValue.EMAIL,
|
|
19292
|
-
TriggerTypeValue.EVAL,
|
|
19293
|
-
TriggerTypeValue.CLI
|
|
19294
|
-
]);
|
|
19295
|
-
ExecutionTypeValue = {
|
|
19296
|
-
PROD: "prod",
|
|
19297
|
-
EVAL: "eval",
|
|
19298
|
-
PLAYGROUND: "playground"
|
|
19299
|
-
};
|
|
19300
|
-
ExecutionTypeSchema = exports_external.enum([
|
|
19301
|
-
ExecutionTypeValue.PROD,
|
|
19302
|
-
ExecutionTypeValue.EVAL,
|
|
19303
|
-
ExecutionTypeValue.PLAYGROUND
|
|
19304
|
-
]);
|
|
19305
|
-
WORKFLOW_EXECUTION_STATUSES = asTuple(WorkflowExecutionStatusSchema.options);
|
|
19306
|
-
STEP_EXECUTION_STATUSES = asTuple(StepExecutionStatusSchema.options);
|
|
19307
|
-
TRIGGER_TYPES = TriggerTypeSchema.options;
|
|
19308
|
-
EXECUTION_TYPES = ExecutionTypeSchema.options;
|
|
19309
|
-
});
|
|
19310
|
-
|
|
19311
|
-
// ../types/src/processor/configs/classify.ts
|
|
19312
|
-
var ClassifyInputSchema, ClassifyLabelSchema, ClassifyConfigSchema, ClassifyOutputSchema;
|
|
19313
|
-
var init_classify = __esm(() => {
|
|
19314
|
-
init_zod();
|
|
19315
|
-
ClassifyInputSchema = exports_external.object({
|
|
19316
|
-
content: exports_external.string().optional().describe("Text content to classify"),
|
|
19317
|
-
text: exports_external.string().optional().describe("Text content (alternative to content)")
|
|
19318
|
-
}).refine((data) => !!(data.content || data.text), {
|
|
19319
|
-
message: "Either content or text must be provided"
|
|
19320
|
-
});
|
|
19321
|
-
ClassifyLabelSchema = exports_external.object({
|
|
19322
|
-
name: exports_external.string().min(1).describe("Label value returned in output.label"),
|
|
19323
|
-
description: exports_external.string().optional().describe("What documents fall into this label. Fed to the LLM as guidance.")
|
|
19324
|
-
});
|
|
19325
|
-
ClassifyConfigSchema = exports_external.object({
|
|
19326
|
-
labels: exports_external.array(ClassifyLabelSchema).min(2).describe("Allowed labels. The LLM is constrained to pick exactly one of these names."),
|
|
19327
|
-
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."),
|
|
19328
|
-
provider: exports_external.string().optional().describe('Provider ID (e.g., "openai-gpt4o-mini")'),
|
|
19329
|
-
model: exports_external.string().optional().describe("Model override"),
|
|
19330
|
-
maxInputTokens: exports_external.number().int().optional().describe("Max input tokens. Truncates input text when exceeded. Omit for no limit.")
|
|
19331
|
-
});
|
|
19332
|
-
ClassifyOutputSchema = exports_external.object({
|
|
19333
|
-
label: exports_external.string().describe("The selected label name"),
|
|
19334
|
-
confidence: exports_external.enum(["low", "medium", "high"]).describe("Coarse confidence in the classification"),
|
|
19335
|
-
reason: exports_external.string().describe("Short justification for the chosen label")
|
|
19336
|
-
});
|
|
19337
|
-
});
|
|
19338
|
-
|
|
19339
|
-
// ../types/src/processor/configs/classify-pages.ts
|
|
19340
|
-
var ClassifyPagesInputSchema, ClassifyPagesLabelSchema, ClassifyPagesConfigSchema, ClassifyPagesOutputSchema;
|
|
19341
|
-
var init_classify_pages = __esm(() => {
|
|
19342
|
-
init_zod();
|
|
19343
|
-
ClassifyPagesInputSchema = exports_external.object({
|
|
19344
|
-
pages: exports_external.array(exports_external.object({
|
|
19345
|
-
pageIndex: exports_external.number().int().nonnegative().describe("0-based page index"),
|
|
19346
|
-
text: exports_external.string().describe("Extracted text for this page"),
|
|
19347
|
-
pageName: exports_external.string().optional()
|
|
19348
|
-
})).min(1).describe("Per-page parsed content from a document parser")
|
|
19349
|
-
}).passthrough().describe("Document-parser-shaped input. Pass {{ steps.parse.output }} directly.");
|
|
19350
|
-
ClassifyPagesLabelSchema = exports_external.union([
|
|
19351
|
-
exports_external.string().min(1),
|
|
19352
|
-
exports_external.object({
|
|
19353
|
-
name: exports_external.string().min(1),
|
|
19354
|
-
description: exports_external.string().optional()
|
|
19355
|
-
})
|
|
19356
|
-
]);
|
|
19357
|
-
ClassifyPagesConfigSchema = exports_external.object({
|
|
19358
|
-
labels: exports_external.array(ClassifyPagesLabelSchema).min(1),
|
|
19359
|
-
prompt: exports_external.string().optional(),
|
|
19360
|
-
provider: exports_external.string().optional(),
|
|
19361
|
-
model: exports_external.string().optional(),
|
|
19362
|
-
windowTokenBudget: exports_external.number().int().positive().optional()
|
|
19363
|
-
});
|
|
19364
|
-
ClassifyPagesOutputSchema = exports_external.object({
|
|
19365
|
-
pages: exports_external.array(exports_external.object({
|
|
19366
|
-
pageIndex: exports_external.number().int(),
|
|
19367
|
-
labels: exports_external.array(exports_external.string())
|
|
19368
|
-
})),
|
|
19369
|
-
byLabel: exports_external.record(exports_external.string(), exports_external.array(exports_external.number().int()))
|
|
19370
|
-
});
|
|
19371
|
-
});
|
|
19372
|
-
|
|
19373
|
-
// ../types/src/parser/parser.ts
|
|
19374
|
-
function resolveEffectiveMimeType(filename, declaredMimeType) {
|
|
19375
|
-
const ext = filename.split(".").pop()?.toLowerCase();
|
|
19376
|
-
if (!ext)
|
|
19377
|
-
return declaredMimeType;
|
|
19378
|
-
const extensionMime = EXTENSION_TO_MIME[ext];
|
|
19379
|
-
return extensionMime ?? declaredMimeType;
|
|
19380
|
-
}
|
|
19381
|
-
function mimeTypeForExtension(extension) {
|
|
19382
|
-
return EXTENSION_TO_MIME[extension.replace(/^\./, "").toLowerCase()];
|
|
19383
|
-
}
|
|
19384
|
-
function extensionForMimeType(mimeType) {
|
|
19385
|
-
const base = mimeType.split(";")[0]?.trim().toLowerCase();
|
|
19386
|
-
return base ? MIME_TO_EXTENSION[base] : undefined;
|
|
19387
|
-
}
|
|
19388
|
-
function getParserCategory(mimeType) {
|
|
19389
|
-
const normalized = mimeType.toLowerCase().trim();
|
|
19390
|
-
if (ParserCategory.PLAINTEXT.includes(normalized)) {
|
|
19391
|
-
return "plaintext";
|
|
19392
|
-
}
|
|
19393
|
-
if (ParserCategory.OFFICE.includes(normalized)) {
|
|
19394
|
-
return "office";
|
|
19395
|
-
}
|
|
19396
|
-
if (ParserCategory.DOCUMENT.includes(normalized)) {
|
|
19397
|
-
return "document";
|
|
19398
|
-
}
|
|
19399
|
-
return null;
|
|
19400
|
-
}
|
|
19401
|
-
function requiresSpecializedParser(mimeType) {
|
|
19402
|
-
return getParserCategory(mimeType) === "document";
|
|
19403
|
-
}
|
|
19404
|
-
function getAllSupportedMimeTypes() {
|
|
19405
|
-
return [...ParserCategory.PLAINTEXT, ...ParserCategory.OFFICE, ...ParserCategory.DOCUMENT];
|
|
19406
|
-
}
|
|
19407
|
-
function getSupportedFormatsLabel() {
|
|
19408
|
-
const allMimes = getAllSupportedMimeTypes();
|
|
19409
|
-
const labels = [...new Set(allMimes.map((m) => MIME_TO_LABEL[m] ?? m))];
|
|
19410
|
-
return labels.join(", ");
|
|
19411
|
-
}
|
|
19412
|
-
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;
|
|
19413
|
-
var init_parser = __esm(() => {
|
|
19414
|
-
init_zod();
|
|
19415
|
-
OFFICE_MIME_TYPES = [
|
|
19416
|
-
"application/vnd.openxmlformats-officedocument.wordprocessingml.document",
|
|
19417
|
-
"application/msword",
|
|
19418
|
-
"application/vnd.oasis.opendocument.text",
|
|
19419
|
-
"application/rtf",
|
|
19420
|
-
"text/rtf",
|
|
19421
|
-
"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
|
19422
|
-
"application/vnd.ms-excel",
|
|
19423
|
-
"application/vnd.ms-excel.sheet.macroenabled.12",
|
|
19424
|
-
"application/vnd.ms-excel.sheet.binary.macroenabled.12",
|
|
19425
|
-
"application/vnd.oasis.opendocument.spreadsheet",
|
|
19426
|
-
"application/vnd.openxmlformats-officedocument.presentationml.presentation",
|
|
19427
|
-
"application/vnd.openxmlformats-officedocument.presentationml.slideshow",
|
|
19428
|
-
"application/vnd.ms-powerpoint.presentation.macroenabled.12",
|
|
19429
|
-
"application/vnd.ms-powerpoint",
|
|
19430
|
-
"application/vnd.oasis.opendocument.presentation",
|
|
19431
|
-
"message/rfc822",
|
|
19432
|
-
"application/vnd.ms-outlook",
|
|
19433
|
-
"application/epub+zip"
|
|
19434
|
-
];
|
|
19435
|
-
ParserCategory = {
|
|
19436
|
-
PLAINTEXT: [
|
|
19437
|
-
"text/plain",
|
|
19438
|
-
"text/markdown",
|
|
19439
|
-
"text/csv",
|
|
19440
|
-
"text/tab-separated-values",
|
|
19441
|
-
"text/html",
|
|
19442
|
-
"text/xml",
|
|
19443
|
-
"application/json",
|
|
19444
|
-
"application/x-yaml",
|
|
19445
|
-
"application/toml",
|
|
19446
|
-
"image/svg+xml",
|
|
19447
|
-
"text/x-rst",
|
|
19448
|
-
"text/x-org",
|
|
19449
|
-
"application/x-latex",
|
|
19450
|
-
"application/x-ipynb+json",
|
|
19451
|
-
"application/x-bibtex",
|
|
19452
|
-
"application/docbook+xml",
|
|
19453
|
-
"application/x-fictionbook+xml"
|
|
19454
|
-
],
|
|
19455
|
-
OFFICE: [...OFFICE_MIME_TYPES],
|
|
19456
|
-
DOCUMENT: [
|
|
19457
|
-
"application/pdf",
|
|
19458
|
-
"image/png",
|
|
19459
|
-
"image/jpeg",
|
|
19460
|
-
"image/webp",
|
|
19461
|
-
"image/tiff",
|
|
19462
|
-
"image/gif",
|
|
19463
|
-
"image/bmp"
|
|
19464
|
-
]
|
|
19465
|
-
};
|
|
19466
|
-
ParserTypeSchema = exports_external.enum([
|
|
19467
|
-
"plaintext",
|
|
19468
|
-
"office",
|
|
19469
|
-
"llm-vision",
|
|
19470
|
-
"ocr"
|
|
19471
|
-
]);
|
|
19472
|
-
DocumentMetadataSchema = exports_external.object({
|
|
19473
|
-
filename: exports_external.string(),
|
|
19474
|
-
mimeType: exports_external.string(),
|
|
19475
|
-
size: exports_external.number().describe("File size in bytes"),
|
|
19476
|
-
storageRef: exports_external.string().optional().describe("Storage reference for the original file")
|
|
19477
|
-
});
|
|
19478
|
-
ParseUsageSchema = exports_external.object({
|
|
19479
|
-
pageCount: exports_external.number(),
|
|
19480
|
-
processingTimeMs: exports_external.number().optional()
|
|
19481
|
-
});
|
|
19482
|
-
CoordinateUnitSchema = exports_external.enum(["pixel", "inch", "point", "normalized"]);
|
|
19483
|
-
PointSchema = exports_external.object({
|
|
19484
|
-
x: exports_external.number(),
|
|
19485
|
-
y: exports_external.number()
|
|
19486
|
-
});
|
|
19487
|
-
BoundingRegionSchema = exports_external.object({
|
|
19488
|
-
polygon: exports_external.array(PointSchema).min(3),
|
|
19489
|
-
unit: CoordinateUnitSchema,
|
|
19490
|
-
pageIndex: exports_external.number()
|
|
19491
|
-
});
|
|
19492
|
-
PositionedTextSchema = exports_external.object({
|
|
19493
|
-
text: exports_external.string(),
|
|
19494
|
-
confidence: exports_external.number().min(0).max(1).optional(),
|
|
19495
|
-
boundingRegion: BoundingRegionSchema.optional()
|
|
19496
|
-
});
|
|
19497
|
-
TableCellSchema = exports_external.object({
|
|
19498
|
-
content: exports_external.string(),
|
|
19499
|
-
rowIndex: exports_external.number(),
|
|
19500
|
-
columnIndex: exports_external.number(),
|
|
19501
|
-
rowSpan: exports_external.number().default(1),
|
|
19502
|
-
columnSpan: exports_external.number().default(1),
|
|
19503
|
-
boundingRegion: BoundingRegionSchema.optional()
|
|
19504
|
-
});
|
|
19505
|
-
ExtractedTableSchema = exports_external.object({
|
|
19506
|
-
cells: exports_external.array(TableCellSchema),
|
|
19507
|
-
rowCount: exports_external.number(),
|
|
19508
|
-
columnCount: exports_external.number(),
|
|
19509
|
-
boundingRegion: BoundingRegionSchema.optional()
|
|
19510
|
-
});
|
|
19511
|
-
LayoutElementTypeSchema = exports_external.enum([
|
|
19512
|
-
"paragraph",
|
|
19513
|
-
"title",
|
|
19514
|
-
"sectionHeading",
|
|
19515
|
-
"pageHeader",
|
|
19516
|
-
"pageFooter",
|
|
19517
|
-
"pageNumber",
|
|
19518
|
-
"footnote",
|
|
19519
|
-
"table",
|
|
19520
|
-
"figure",
|
|
19521
|
-
"formulaBlock"
|
|
19522
|
-
]);
|
|
19523
|
-
LayoutElementSchema = exports_external.object({
|
|
19524
|
-
type: LayoutElementTypeSchema,
|
|
19525
|
-
content: exports_external.string(),
|
|
19526
|
-
table: ExtractedTableSchema.optional(),
|
|
19527
|
-
caption: exports_external.string().optional(),
|
|
19528
|
-
figureId: exports_external.string().optional(),
|
|
19529
|
-
boundingRegion: BoundingRegionSchema.optional()
|
|
19530
|
-
});
|
|
19531
|
-
PageResultSchema = exports_external.object({
|
|
19532
|
-
pageIndex: exports_external.number().describe("0-based page index"),
|
|
19533
|
-
text: exports_external.string().describe("Extracted text content (markdown/HTML)"),
|
|
19534
|
-
pageName: exports_external.string().optional().describe("Page/sheet name (e.g., Excel sheet name)"),
|
|
19535
|
-
layoutElements: exports_external.array(LayoutElementSchema).optional().describe("Semantic layout elements in reading order"),
|
|
19536
|
-
words: exports_external.array(PositionedTextSchema).optional().describe("Word-level positions"),
|
|
19537
|
-
lines: exports_external.array(PositionedTextSchema).optional().describe("Line-level positions"),
|
|
19538
|
-
tables: exports_external.array(ExtractedTableSchema).optional().describe("Extracted tables"),
|
|
19539
|
-
width: exports_external.number().optional().describe("Page width"),
|
|
19540
|
-
height: exports_external.number().optional().describe("Page height"),
|
|
19541
|
-
unit: CoordinateUnitSchema.optional().describe("Unit for width/height and bounding regions"),
|
|
19542
|
-
confidence: exports_external.number().min(0).max(1).optional().describe("Overall page confidence")
|
|
19543
|
-
});
|
|
19544
|
-
ParseResultSchema = exports_external.object({
|
|
19545
|
-
document: DocumentMetadataSchema,
|
|
19546
|
-
usage: ParseUsageSchema,
|
|
19547
|
-
pages: exports_external.array(PageResultSchema),
|
|
19548
|
-
text: exports_external.string().describe("Combined text from all pages"),
|
|
19549
|
-
parserType: ParserTypeSchema,
|
|
19550
|
-
parserVersion: exports_external.string().optional(),
|
|
19551
|
-
model: exports_external.string().optional().describe("Model used (for LLM/OCR parsers)"),
|
|
19552
|
-
rawResponse: exports_external.unknown().optional()
|
|
19553
|
-
});
|
|
19554
|
-
ParseOptionsSchema = exports_external.object({
|
|
19555
|
-
outputFormat: exports_external.enum(["plain", "markdown", "djot", "html"]).default("markdown"),
|
|
19556
|
-
ocrProvider: exports_external.string().optional().describe("OCR provider ID to use"),
|
|
19557
|
-
includeWordPositions: exports_external.boolean().default(false),
|
|
19558
|
-
includeLinePositions: exports_external.boolean().default(false),
|
|
19559
|
-
extractTables: exports_external.boolean().default(true),
|
|
19560
|
-
provider: exports_external.string().optional().describe("LLM provider ID to use"),
|
|
19561
|
-
model: exports_external.string().optional(),
|
|
19562
|
-
maxConcurrency: exports_external.number().min(1).max(30).default(3),
|
|
19563
|
-
pagesPerBatch: exports_external.number().min(1).max(20).default(5),
|
|
19564
|
-
pdfRenderScale: exports_external.number().min(1).max(4).default(1).describe("Scale factor used when rendering PDF pages for VLM parsing"),
|
|
19565
|
-
imageQuality: exports_external.number().int().min(1).max(100).default(85).describe("JPEG quality used for PDF page images sent to VLM parsing"),
|
|
19566
|
-
prompt: exports_external.string().optional().describe("Custom prompt for LLM-based parsing"),
|
|
19567
|
-
languages: exports_external.array(exports_external.string()).optional().describe("OCR language hints"),
|
|
19568
|
-
tenantId: exports_external.string().optional()
|
|
19569
|
-
});
|
|
19570
|
-
ParserInputSchema = exports_external.object({
|
|
19571
|
-
data: exports_external.instanceof(Buffer).or(exports_external.instanceof(Uint8Array)),
|
|
19572
|
-
filename: exports_external.string(),
|
|
19573
|
-
mimeType: exports_external.string(),
|
|
19574
|
-
options: ParseOptionsSchema.optional()
|
|
19575
|
-
});
|
|
19576
|
-
EXTENSION_TO_MIME = {
|
|
19577
|
-
docx: "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
|
|
19578
|
-
doc: "application/msword",
|
|
19579
|
-
odt: "application/vnd.oasis.opendocument.text",
|
|
19580
|
-
rtf: "application/rtf",
|
|
19581
|
-
xlsx: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
|
19582
|
-
xls: "application/vnd.ms-excel",
|
|
19583
|
-
xlsm: "application/vnd.ms-excel.sheet.macroenabled.12",
|
|
19584
|
-
xlsb: "application/vnd.ms-excel.sheet.binary.macroenabled.12",
|
|
19585
|
-
ods: "application/vnd.oasis.opendocument.spreadsheet",
|
|
19586
|
-
pptx: "application/vnd.openxmlformats-officedocument.presentationml.presentation",
|
|
19587
|
-
ppsx: "application/vnd.openxmlformats-officedocument.presentationml.slideshow",
|
|
19588
|
-
pptm: "application/vnd.ms-powerpoint.presentation.macroenabled.12",
|
|
19589
|
-
ppt: "application/vnd.ms-powerpoint",
|
|
19590
|
-
odp: "application/vnd.oasis.opendocument.presentation",
|
|
19591
|
-
eml: "message/rfc822",
|
|
19592
|
-
msg: "application/vnd.ms-outlook",
|
|
19593
|
-
epub: "application/epub+zip",
|
|
19594
|
-
pdf: "application/pdf",
|
|
19595
|
-
png: "image/png",
|
|
19596
|
-
jpg: "image/jpeg",
|
|
19597
|
-
jpeg: "image/jpeg",
|
|
19598
|
-
webp: "image/webp",
|
|
19599
|
-
tiff: "image/tiff",
|
|
19600
|
-
tif: "image/tiff",
|
|
19601
|
-
gif: "image/gif",
|
|
19602
|
-
bmp: "image/bmp",
|
|
19603
|
-
svg: "image/svg+xml",
|
|
19604
|
-
txt: "text/plain",
|
|
19605
|
-
md: "text/markdown",
|
|
19606
|
-
markdown: "text/markdown",
|
|
19607
|
-
csv: "text/csv",
|
|
19608
|
-
tsv: "text/tab-separated-values",
|
|
19609
|
-
html: "text/html",
|
|
19610
|
-
htm: "text/html",
|
|
19611
|
-
xml: "text/xml",
|
|
19612
|
-
json: "application/json",
|
|
19613
|
-
yaml: "application/x-yaml",
|
|
19614
|
-
yml: "application/x-yaml",
|
|
19615
|
-
toml: "application/toml",
|
|
19616
|
-
rst: "text/x-rst",
|
|
19617
|
-
org: "text/x-org",
|
|
19618
|
-
tex: "application/x-latex",
|
|
19619
|
-
latex: "application/x-latex",
|
|
19620
|
-
ipynb: "application/x-ipynb+json",
|
|
19621
|
-
bib: "application/x-bibtex",
|
|
19622
|
-
dbk: "application/docbook+xml",
|
|
19623
|
-
docbook: "application/docbook+xml",
|
|
19624
|
-
fb2: "application/x-fictionbook+xml"
|
|
19625
|
-
};
|
|
19626
|
-
MIME_TO_EXTENSION = Object.entries(EXTENSION_TO_MIME).reduce((acc, [ext, mime]) => {
|
|
19627
|
-
if (!(mime in acc))
|
|
19628
|
-
acc[mime] = ext;
|
|
19629
|
-
return acc;
|
|
19630
|
-
}, {});
|
|
19631
|
-
MIME_TO_LABEL = {
|
|
19632
|
-
"application/vnd.openxmlformats-officedocument.wordprocessingml.document": "DOCX",
|
|
19633
|
-
"application/msword": "DOC",
|
|
19634
|
-
"application/vnd.oasis.opendocument.text": "ODT",
|
|
19635
|
-
"application/rtf": "RTF",
|
|
19636
|
-
"text/rtf": "RTF",
|
|
19637
|
-
"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": "XLSX",
|
|
19638
|
-
"application/vnd.ms-excel": "XLS",
|
|
19639
|
-
"application/vnd.ms-excel.sheet.macroenabled.12": "XLSM",
|
|
19640
|
-
"application/vnd.ms-excel.sheet.binary.macroenabled.12": "XLSB",
|
|
19641
|
-
"application/vnd.oasis.opendocument.spreadsheet": "ODS",
|
|
19642
|
-
"application/vnd.openxmlformats-officedocument.presentationml.presentation": "PPTX",
|
|
19643
|
-
"application/vnd.openxmlformats-officedocument.presentationml.slideshow": "PPSX",
|
|
19644
|
-
"application/vnd.ms-powerpoint.presentation.macroenabled.12": "PPTM",
|
|
19645
|
-
"application/vnd.ms-powerpoint": "PPT",
|
|
19646
|
-
"application/vnd.oasis.opendocument.presentation": "ODP",
|
|
19647
|
-
"message/rfc822": "EML",
|
|
19648
|
-
"application/vnd.ms-outlook": "MSG",
|
|
19649
|
-
"application/epub+zip": "EPUB",
|
|
19650
|
-
"application/pdf": "PDF",
|
|
19651
|
-
"image/png": "PNG",
|
|
19652
|
-
"image/jpeg": "JPEG",
|
|
19653
|
-
"image/webp": "WebP",
|
|
19654
|
-
"image/tiff": "TIFF",
|
|
19655
|
-
"image/gif": "GIF",
|
|
19656
|
-
"image/bmp": "BMP",
|
|
19657
|
-
"image/svg+xml": "SVG",
|
|
19658
|
-
"text/plain": "TXT",
|
|
19659
|
-
"text/markdown": "Markdown",
|
|
19660
|
-
"text/csv": "CSV",
|
|
19661
|
-
"text/tab-separated-values": "TSV",
|
|
19662
|
-
"text/html": "HTML",
|
|
19663
|
-
"text/xml": "XML",
|
|
19664
|
-
"application/json": "JSON",
|
|
19665
|
-
"application/x-yaml": "YAML",
|
|
19666
|
-
"application/toml": "TOML",
|
|
19667
|
-
"text/x-rst": "RST",
|
|
19668
|
-
"text/x-org": "Org",
|
|
19669
|
-
"application/x-latex": "LaTeX",
|
|
19670
|
-
"application/x-ipynb+json": "Jupyter",
|
|
19671
|
-
"application/x-bibtex": "BibTeX",
|
|
19672
|
-
"application/docbook+xml": "DocBook",
|
|
19673
|
-
"application/x-fictionbook+xml": "FB2"
|
|
19674
|
-
};
|
|
19675
|
-
});
|
|
19676
|
-
|
|
19677
|
-
// ../types/src/processor/configs/document-parser.ts
|
|
19678
|
-
var DocumentParserInputSchema, DocumentParserOutputSchema, DocumentParserConfigSchema;
|
|
19679
|
-
var init_document_parser = __esm(() => {
|
|
19680
|
-
init_zod();
|
|
19681
|
-
init_runtime_file_ref();
|
|
19682
|
-
init_parser();
|
|
19683
|
-
DocumentParserInputSchema = ResolvedProcessorFileSchema;
|
|
19684
|
-
DocumentParserOutputSchema = ParseResultSchema;
|
|
19685
|
-
DocumentParserConfigSchema = exports_external.object({
|
|
19686
|
-
ocrModel: exports_external.string().optional().describe("OCR provider ID for PDF/image parsing"),
|
|
19687
|
-
llmModel: exports_external.string().optional().describe("LLM provider ID for vision-based parsing"),
|
|
19688
|
-
maxConcurrency: exports_external.number().min(1).max(10).default(3).describe("Max concurrent VLM batch requests"),
|
|
19689
|
-
pagesPerBatch: exports_external.number().min(1).max(20).default(5).describe("Number of page images per VLM request"),
|
|
19690
|
-
pdfRenderScale: exports_external.number().min(1).max(4).default(1).optional().describe("Scale factor used when rendering PDF pages for VLM parsing"),
|
|
19691
|
-
imageQuality: exports_external.number().int().min(1).max(100).default(85).optional().describe("JPEG quality used for PDF page images sent to VLM parsing"),
|
|
19692
|
-
prompt: exports_external.string().optional().describe("Custom extraction prompt"),
|
|
19693
|
-
nativeText: exports_external.boolean().default(false).optional().describe("Use native text extraction for PDFs with embedded text (no OCR/VLM)"),
|
|
19694
|
-
describeFigures: exports_external.boolean().optional().describe("Opt-in (default off). After text extraction, detect figure pages with a layout model and caption them with a vision model, appending `<figure>description</figure>` to their text. Skipped for plaintext. The caption vision calls are billed."),
|
|
19695
|
-
figureInstructions: exports_external.string().optional().describe("Custom instruction for the figure-description pass."),
|
|
19696
|
-
languages: exports_external.array(exports_external.string()).optional().describe('OCR language hints (e.g., ["en", "de"])'),
|
|
19697
|
-
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.")
|
|
19698
|
-
}).prefault({});
|
|
19699
|
-
});
|
|
19700
|
-
|
|
19701
|
-
// ../types/src/processor/configs/extract.ts
|
|
19702
|
-
var ExtractInputSchema, ExtractOutputSchema, ExtractConfigSchema;
|
|
19703
|
-
var init_extract = __esm(() => {
|
|
19704
|
-
init_zod();
|
|
19705
|
-
ExtractInputSchema = exports_external.object({
|
|
19706
|
-
content: exports_external.string().optional().describe("Text content to extract from"),
|
|
19707
|
-
text: exports_external.string().optional().describe("Text content (alternative to content, e.g., from document parser)"),
|
|
19708
|
-
contentType: exports_external.enum(["text", "image"]).default("text"),
|
|
19709
|
-
imageData: exports_external.string().optional(),
|
|
19710
|
-
imageMimeType: exports_external.string().optional()
|
|
19711
|
-
}).refine((data) => data.content || data.text, {
|
|
19712
|
-
message: "Either content or text must be provided"
|
|
19713
|
-
});
|
|
19714
|
-
ExtractOutputSchema = exports_external.record(exports_external.string(), exports_external.unknown()).describe("Extracted structured data matching the provided schema. Unless grounding is disabled (grounded: false), the output also carries a reserved `_grounding` map keyed by field name: `_grounding.<field> = { confidence: high|medium|low, needsReview, reason?, source_span: { start, end, text, alignment } | null }`, plus reserved `_degraded: true` / `_reason` markers when the grounding LLM pass could not run.");
|
|
19715
|
-
ExtractConfigSchema = exports_external.object({
|
|
19716
|
-
schema: exports_external.record(exports_external.string(), exports_external.unknown()).describe("JSON Schema defining the structure to extract"),
|
|
19717
|
-
prompt: exports_external.string().optional().describe("Custom prompt template for extraction"),
|
|
19718
|
-
provider: exports_external.string().optional().describe('Provider ID to use (e.g., "openai-gpt4o", "anthropic-claude")'),
|
|
19719
|
-
model: exports_external.string().optional().describe("Model to use (overrides provider default)"),
|
|
19720
|
-
maxInputTokens: exports_external.number().int().optional().describe("Max input tokens. Truncates input text and logs a warning when exceeded. Omit for no limit."),
|
|
19721
|
-
grounded: exports_external.boolean().optional().describe("Grounding is ON by default: a grounding pass runs over the schema fields and attaches per-field source spans + confidence under a reserved `_grounding` output key, flagging fields whose value cannot be located in the source for human review. The pass runs through the workspace LLM (any provider) and chunks long documents automatically. Tri-state: unset (default) = on, degrading gracefully to deterministic text alignment (`_grounding._degraded: true`) if no grounding model is available; `true` = strict, the step fails when the grounding model cannot be resolved; `false` = off, no `_grounding` key at all."),
|
|
19722
|
-
groundingModel: exports_external.string().optional().describe("Provider/model for the grounding pass. Defaults to the workspace default LLM. Any configured provider works; the pass only fails the step when `grounded: true` is set explicitly and no model resolves."),
|
|
19723
|
-
groundingExamples: exports_external.array(exports_external.object({
|
|
19724
|
-
text: exports_external.string(),
|
|
19725
|
-
extractions: exports_external.array(exports_external.object({ field: exports_external.string(), text: exports_external.string() }))
|
|
19726
|
-
})).optional().describe("Few-shot examples for grounding (verbatim source text per field). Optional."),
|
|
19727
|
-
reviewOn: exports_external.enum(["medium_or_low", "low_only"]).optional().describe("Which grounding confidences set needsReview on a field. Default: low_only (only fields whose value could not be located in the source). Use medium_or_low to also flag approximate and derived matches.")
|
|
19728
|
-
});
|
|
19729
|
-
});
|
|
19730
|
-
|
|
19731
|
-
// ../types/src/processor/configs/merge.ts
|
|
19732
|
-
var MergeConfigSchema, MergeInputSchema, MergeOutputSchema;
|
|
19733
|
-
var init_merge = __esm(() => {
|
|
19734
|
-
init_zod();
|
|
19735
|
-
MergeConfigSchema = exports_external.object({
|
|
19736
|
-
preservePortNames: exports_external.boolean().default(true),
|
|
19737
|
-
outputKey: exports_external.string().optional()
|
|
19738
|
-
});
|
|
19739
|
-
MergeInputSchema = exports_external.record(exports_external.string(), exports_external.unknown());
|
|
19740
|
-
MergeOutputSchema = exports_external.object({
|
|
19741
|
-
items: exports_external.array(exports_external.unknown()),
|
|
19742
|
-
count: exports_external.number(),
|
|
19743
|
-
merged: exports_external.record(exports_external.string(), exports_external.unknown()).optional()
|
|
19744
|
-
});
|
|
19745
|
-
});
|
|
19746
|
-
|
|
19747
|
-
// ../types/src/processor/configs/pdf-embedder.ts
|
|
19748
|
-
var PdfEmbedderInputSchema, PdfEmbedderOutputSchema, PdfEmbedderConfigSchema;
|
|
19749
|
-
var init_pdf_embedder = __esm(() => {
|
|
19750
|
-
init_zod();
|
|
19751
|
-
init_runtime_file_ref();
|
|
19752
|
-
init_parser();
|
|
19753
|
-
PdfEmbedderInputSchema = exports_external.object({
|
|
19754
|
-
file: ResolvedProcessorFileSchema.describe("Resolved source file handle"),
|
|
19755
|
-
parseResult: exports_external.object({
|
|
19756
|
-
pages: exports_external.array(PageResultSchema),
|
|
19757
|
-
text: exports_external.string().optional()
|
|
19758
|
-
}).describe("Parse result from ai.parse step (must include word positions)")
|
|
19759
|
-
});
|
|
19760
|
-
PdfEmbedderOutputSchema = exports_external.object({
|
|
19761
|
-
fileId: exports_external.string().describe("File ID from files table"),
|
|
19762
|
-
pageCount: exports_external.number().describe("Number of pages in the output PDF"),
|
|
19763
|
-
wordCount: exports_external.number().describe("Number of words embedded"),
|
|
19764
|
-
text: exports_external.string().describe("Extracted text (from parse step)")
|
|
19765
|
-
});
|
|
19766
|
-
PdfEmbedderConfigSchema = exports_external.object({
|
|
19767
|
-
outputFilename: exports_external.string().optional().describe('Output filename - supports LiquidJS syntax e.g. "{{filename}}-searchable.pdf"'),
|
|
19768
|
-
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")
|
|
19769
|
-
}).prefault({});
|
|
19770
|
-
});
|
|
19771
|
-
|
|
19772
|
-
// ../types/src/processor/configs/segment.ts
|
|
19773
|
-
var SegmentInputSchema, SEGMENT_UNKNOWN_TYPE = "unknown", SegmentConfigSchema, ConfidenceLevelSchema, SegmentSummarySchema, SegmentOutputSchema;
|
|
19774
|
-
var init_segment = __esm(() => {
|
|
19775
|
-
init_zod();
|
|
19776
|
-
SegmentInputSchema = exports_external.object({
|
|
19777
|
-
pages: exports_external.array(exports_external.object({
|
|
19778
|
-
pageIndex: exports_external.number().describe("0-based page index"),
|
|
19779
|
-
text: exports_external.string().describe("Extracted text for this page"),
|
|
19780
|
-
pageName: exports_external.string().optional()
|
|
19781
|
-
})).min(1).describe("Per-page parsed content from a document parser")
|
|
19782
|
-
}).passthrough().describe("Document-parser-shaped input. Pass {{ steps.parse.output }} directly — extra fields like text/metadata are ignored.");
|
|
19783
|
-
SegmentConfigSchema = exports_external.object({
|
|
19784
|
-
documentTypes: exports_external.array(exports_external.object({
|
|
19785
|
-
name: exports_external.string().min(1).describe('Type label returned in documents[].type (e.g. "timesheet", "deal-memo").'),
|
|
19786
|
-
description: exports_external.string().optional().describe("What this document type looks like — headings, layout, vocabulary, and the visual cues that mark its FIRST page. Fed to the LLM as guidance for both boundary detection and typing.")
|
|
19787
|
-
})).min(1).describe('The document-type taxonomy. The LLM tags each detected document with one of these names, or the reserved "unknown" type when none fit.'),
|
|
19788
|
-
rules: exports_external.string().optional().describe("Optional natural-language rules appended to the system prompt"),
|
|
19789
|
-
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.'),
|
|
19790
|
-
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 boundaries on dense batches; larger windows when documents routinely exceed the per-window page count.")
|
|
19791
|
-
});
|
|
19792
|
-
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.");
|
|
19793
|
-
SegmentSummarySchema = exports_external.object({
|
|
19794
|
-
total: exports_external.number().int().describe("Total documents discovered in the batch."),
|
|
19795
|
-
labelled: exports_external.number().int().describe('Documents assigned a known taxonomy type (type !== "unknown").'),
|
|
19796
|
-
unlabelled: exports_external.number().int().describe('Documents the segmenter could not label (type === "unknown") — escalate to a human.'),
|
|
19797
|
-
lowConfidence: exports_external.number().int().describe('Documents whose boundary/type confidence is "low" — also worth human review.'),
|
|
19798
|
-
byType: exports_external.record(exports_external.string(), exports_external.number().int()).describe('Per-type document counts, keyed by type name (includes "unknown").'),
|
|
19799
|
-
needsReview: exports_external.array(exports_external.object({
|
|
19800
|
-
index: exports_external.number().int(),
|
|
19801
|
-
type: exports_external.string(),
|
|
19802
|
-
page_range: exports_external.tuple([exports_external.number().int(), exports_external.number().int()]),
|
|
19803
|
-
reason: exports_external.enum(["unlabelled", "low_confidence"]).describe("Why this document should be escalated to a human operator."),
|
|
19804
|
-
notes: exports_external.string()
|
|
19805
|
-
})).describe("The exact documents to escalate to a human operator, with the reason for each.")
|
|
19806
|
-
});
|
|
19807
|
-
SegmentOutputSchema = exports_external.object({
|
|
19808
|
-
summary: SegmentSummarySchema.describe("Batch-level escalation summary: labelled vs unlabelled counts and the documents needing human review."),
|
|
19809
|
-
documents: exports_external.array(exports_external.object({
|
|
19810
|
-
index: exports_external.number().int().describe("0-based position of this document in the batch, in page order."),
|
|
19811
|
-
type: exports_external.string().describe('Chosen type name from the taxonomy, or "unknown" when none fit.'),
|
|
19812
|
-
page_range: exports_external.tuple([exports_external.number().int(), exports_external.number().int()]).describe("Inclusive [startPage, endPage], 0-based, matching input pageIndex."),
|
|
19813
|
-
confidence: ConfidenceLevelSchema.describe("LLM confidence at the document boundary + type: low | medium | high."),
|
|
19814
|
-
notes: exports_external.string().describe("Short prose citing what marked this page as a new document."),
|
|
19815
|
-
evidence: exports_external.object({
|
|
19816
|
-
start_heading_text: exports_external.string().nullable().optional().describe("Verbatim heading/title text the LLM cited as the document start"),
|
|
19817
|
-
start_page: exports_external.number().int().nullable().optional().describe("Page where the start appears")
|
|
19818
|
-
}).optional().describe("Structured start evidence — for downstream parsing without regex over `notes`."),
|
|
19819
|
-
text: exports_external.string().describe("Joined per-page text for this document, ready for ai.extract"),
|
|
19820
|
-
pages: exports_external.array(exports_external.object({
|
|
19821
|
-
pageIndex: exports_external.number().int(),
|
|
19822
|
-
text: exports_external.string(),
|
|
19823
|
-
pageName: exports_external.string().optional(),
|
|
19824
|
-
source: exports_external.enum(["anchored", "inferred"]).describe("Whether this page was the LLM boundary (direct evidence) or filled in by continuity")
|
|
19825
|
-
})).describe("Raw per-page records covered by this document, in page order."),
|
|
19826
|
-
pages_anchored: exports_external.array(exports_external.number().int()),
|
|
19827
|
-
pages_inferred: exports_external.array(exports_external.number().int())
|
|
19828
|
-
}))
|
|
19829
|
-
});
|
|
19830
|
-
});
|
|
19831
|
-
|
|
19832
|
-
// ../types/src/processor/configs/split.ts
|
|
19833
|
-
var SplitInputSchema, SplitConfigSchema, ConfidenceLevelSchema2, SplitSectionSchema, SplitOutputSchema;
|
|
19834
|
-
var init_split = __esm(() => {
|
|
19835
|
-
init_zod();
|
|
19836
|
-
SplitInputSchema = exports_external.object({
|
|
19837
|
-
pages: exports_external.array(exports_external.object({
|
|
19838
|
-
pageIndex: exports_external.number().describe("0-based page index"),
|
|
19839
|
-
text: exports_external.string().describe("Extracted text for this page"),
|
|
19840
|
-
pageName: exports_external.string().optional()
|
|
19841
|
-
})).min(1).describe("Per-page parsed content from a document parser")
|
|
19842
|
-
}).passthrough().describe("Document-parser-shaped input. Pass {{ steps.parse.output }} directly — extra fields like text/metadata are ignored.");
|
|
19843
|
-
SplitConfigSchema = exports_external.object({
|
|
19844
|
-
sections: exports_external.array(exports_external.object({
|
|
19845
|
-
name: exports_external.string().min(1).describe("Stable id for the section"),
|
|
19846
|
-
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."),
|
|
19847
|
-
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").'),
|
|
19848
|
-
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.')
|
|
19849
|
-
})).min(1),
|
|
19850
|
-
rules: exports_external.string().optional().describe("Optional natural-language rules appended to the system prompt"),
|
|
19851
|
-
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.'),
|
|
19852
|
-
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.")
|
|
19853
|
-
});
|
|
19854
|
-
ConfidenceLevelSchema2 = 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.");
|
|
19855
|
-
SplitSectionSchema = exports_external.object({
|
|
19856
|
-
name: exports_external.string(),
|
|
19857
|
-
page_range: exports_external.tuple([exports_external.number().int(), exports_external.number().int()]),
|
|
19858
|
-
confidence: ConfidenceLevelSchema2.describe("LLM confidence at the start anchor: low | medium | high."),
|
|
19859
|
-
notes: exports_external.string(),
|
|
19860
|
-
evidence: exports_external.object({
|
|
19861
|
-
start_heading_text: exports_external.string().nullable().optional().describe("Verbatim heading text the LLM cited as the section start"),
|
|
19862
|
-
start_page: exports_external.number().int().nullable().optional().describe("Page where start_heading_text appears")
|
|
19863
|
-
}).optional().describe("Structured start-anchor evidence the LLM cited — for downstream parsing without regex over `notes`."),
|
|
19864
|
-
end_evidence: exports_external.object({
|
|
19865
|
-
end_page: exports_external.number().int().describe("LAST page of the section (inclusive)"),
|
|
19866
|
-
confidence: ConfidenceLevelSchema2,
|
|
19867
|
-
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.")
|
|
19868
|
-
}).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)."),
|
|
19869
|
-
text: exports_external.string().describe("Joined per-page text for this section, ready for ai.extract"),
|
|
19870
|
-
pages: exports_external.array(exports_external.object({
|
|
19871
|
-
pageIndex: exports_external.number().int(),
|
|
19872
|
-
text: exports_external.string(),
|
|
19873
|
-
pageName: exports_external.string().optional(),
|
|
19874
|
-
source: exports_external.enum(["anchored", "inferred"]).describe("Whether this page was the LLM anchor (direct evidence) or filled in by continuity")
|
|
19875
|
-
})).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."),
|
|
19876
|
-
pages_anchored: exports_external.array(exports_external.number().int()),
|
|
19877
|
-
pages_inferred: exports_external.array(exports_external.number().int())
|
|
19878
|
-
});
|
|
19879
|
-
SplitOutputSchema = exports_external.object({
|
|
19880
|
-
splits: exports_external.array(SplitSectionSchema),
|
|
19881
|
-
sections: exports_external.record(exports_external.string(), SplitSectionSchema).describe("The same sections keyed by their config name, for direct reference: `steps.<split>.output.sections.<name>.page_range`. On the rare duplicate name, the last section wins; use `splits` for the full ordered list.")
|
|
19882
|
-
});
|
|
19883
|
-
});
|
|
19884
|
-
|
|
19885
|
-
// ../types/src/processor/configs/template.ts
|
|
19886
|
-
var TemplateInputSchema, TemplateOutputSchema, TemplateConfigSchema;
|
|
19887
|
-
var init_template = __esm(() => {
|
|
19888
|
-
init_zod();
|
|
19889
|
-
TemplateInputSchema = exports_external.object({
|
|
19890
|
-
data: exports_external.record(exports_external.string(), exports_external.unknown()).describe("Data to merge into the template")
|
|
19891
|
-
});
|
|
19892
|
-
TemplateOutputSchema = exports_external.object({
|
|
19893
|
-
fileId: exports_external.string().describe("File ID from files table")
|
|
19894
|
-
});
|
|
19895
|
-
TemplateConfigSchema = exports_external.object({
|
|
19896
|
-
templateId: exports_external.string().describe("ID of the template from templates table"),
|
|
19897
|
-
outputFilename: exports_external.string().optional().describe('Output filename - supports LiquidJS syntax e.g. "{{invoice_id}}-report.docx"'),
|
|
19898
|
-
highlightNotFound: exports_external.boolean().default(true).optional().describe("Highlight missing variables with red-colored text in the output document"),
|
|
19899
|
-
notFoundText: exports_external.string().default("NOT FOUND").optional().describe("Text to display for missing variables when highlightNotFound is enabled")
|
|
19900
|
-
});
|
|
19901
|
-
});
|
|
19902
|
-
|
|
19903
|
-
// ../types/src/processor/configs/xlsx-to-json.ts
|
|
19904
|
-
var XlsxToJsonInputSchema, XlsxToJsonOutputSchema, XlsxToJsonConfigSchema;
|
|
19905
|
-
var init_xlsx_to_json = __esm(() => {
|
|
19906
|
-
init_zod();
|
|
19907
|
-
init_runtime_file_ref();
|
|
19908
|
-
XlsxToJsonInputSchema = ResolvedProcessorFileSchema;
|
|
19909
|
-
XlsxToJsonOutputSchema = exports_external.object({
|
|
19910
|
-
rows: exports_external.array(exports_external.record(exports_external.string(), exports_external.unknown())).describe("Array of row objects (header row = keys)"),
|
|
19911
|
-
fileId: exports_external.string().optional().describe("File ID of stored CSV when outputCsv is true")
|
|
19912
|
-
});
|
|
19913
|
-
XlsxToJsonConfigSchema = exports_external.object({
|
|
19914
|
-
sheet: exports_external.union([exports_external.number().int().min(0), exports_external.string()]).optional().describe("Sheet to read: 0-based index or sheet name"),
|
|
19915
|
-
outputCsv: exports_external.boolean().default(false).optional(),
|
|
19916
|
-
outputFilename: exports_external.string().optional().describe("Output CSV filename when outputCsv is true")
|
|
19917
|
-
});
|
|
19918
|
-
});
|
|
19919
|
-
|
|
19920
|
-
// ../types/src/processor/configs/react-hook-form.ts
|
|
19921
|
-
function extractFieldMetadata(schema) {
|
|
19922
|
-
const fields = [];
|
|
19923
|
-
let inner = schema;
|
|
19924
|
-
while (inner instanceof exports_external.ZodDefault || inner instanceof exports_external.ZodPrefault) {
|
|
19925
|
-
inner = inner.unwrap();
|
|
19926
|
-
}
|
|
19927
|
-
if (inner instanceof exports_external.ZodObject) {
|
|
19928
|
-
for (const [name, fieldSchema] of Object.entries(inner.shape)) {
|
|
19929
|
-
fields.push(extractSingleFieldMetadata(name, fieldSchema));
|
|
19930
|
-
}
|
|
19931
|
-
}
|
|
19932
|
-
return fields;
|
|
19933
|
-
}
|
|
19934
|
-
function extractSingleFieldMetadata(name, schema) {
|
|
19935
|
-
let current = schema;
|
|
19936
|
-
let required2 = true;
|
|
19937
|
-
let defaultValue = undefined;
|
|
19938
|
-
let description = current.description;
|
|
19939
|
-
while (true) {
|
|
19940
|
-
if (current instanceof exports_external.ZodOptional) {
|
|
19941
|
-
required2 = false;
|
|
19942
|
-
current = current.unwrap();
|
|
19943
|
-
} else if (current instanceof exports_external.ZodDefault || current instanceof exports_external.ZodPrefault) {
|
|
19944
|
-
defaultValue = current._def.defaultValue;
|
|
19945
|
-
current = current.unwrap();
|
|
19946
|
-
} else {
|
|
19947
|
-
break;
|
|
19948
|
-
}
|
|
19949
|
-
description ??= current.description;
|
|
19950
|
-
}
|
|
19951
|
-
const base = { name, type: "unknown", required: required2, description, defaultValue };
|
|
19952
|
-
if (current instanceof exports_external.ZodString)
|
|
19953
|
-
return { ...base, type: "string" };
|
|
19954
|
-
if (current instanceof exports_external.ZodNumber) {
|
|
19955
|
-
let min;
|
|
19956
|
-
let max;
|
|
19957
|
-
for (const c of current._def.checks ?? []) {
|
|
19958
|
-
const def = c._zod.def;
|
|
19959
|
-
if (def.check === "greater_than")
|
|
19960
|
-
min = def.value;
|
|
19961
|
-
if (def.check === "less_than")
|
|
19962
|
-
max = def.value;
|
|
19963
|
-
}
|
|
19964
|
-
return { ...base, type: "number", min, max };
|
|
19965
|
-
}
|
|
19966
|
-
if (current instanceof exports_external.ZodBoolean)
|
|
19967
|
-
return { ...base, type: "boolean" };
|
|
19968
|
-
if (current instanceof exports_external.ZodEnum) {
|
|
19969
|
-
return { ...base, type: "enum", enumValues: current.options };
|
|
19970
|
-
}
|
|
19971
|
-
if (current instanceof exports_external.ZodArray)
|
|
19972
|
-
return { ...base, type: "array" };
|
|
19973
|
-
if (current instanceof exports_external.ZodObject || current instanceof exports_external.ZodRecord) {
|
|
19974
|
-
return { ...base, type: "object" };
|
|
19975
|
-
}
|
|
19976
|
-
return base;
|
|
19977
|
-
}
|
|
19978
|
-
function getConfigFieldMetadata(processorId) {
|
|
19979
|
-
const schema = getConfigSchema(processorId);
|
|
19980
|
-
if (!schema)
|
|
19981
|
-
return;
|
|
19982
|
-
return extractFieldMetadata(schema);
|
|
19983
|
-
}
|
|
19984
|
-
function getConfigDefaults(processorId) {
|
|
19985
|
-
const schema = PROCESSOR_SCHEMAS[processorId]?.configSchema;
|
|
19986
|
-
if (!schema)
|
|
19987
|
-
return {};
|
|
19988
|
-
try {
|
|
19989
|
-
const result = schema.safeParse({});
|
|
19990
|
-
if (result.success) {
|
|
19991
|
-
return result.data;
|
|
19992
|
-
}
|
|
19993
|
-
} catch {}
|
|
19994
|
-
const fields = extractFieldMetadata(schema);
|
|
19995
|
-
const defaults = {};
|
|
19996
|
-
for (const field of fields) {
|
|
19997
|
-
if (field.defaultValue !== undefined) {
|
|
19998
|
-
defaults[field.name] = field.defaultValue;
|
|
19999
|
-
}
|
|
20000
|
-
}
|
|
20001
|
-
return defaults;
|
|
20002
|
-
}
|
|
20003
|
-
function validateConfig(processorId, config2) {
|
|
20004
|
-
const schema = getConfigSchema(processorId);
|
|
20005
|
-
if (!schema) {
|
|
20006
|
-
return { valid: true, errors: {} };
|
|
20007
|
-
}
|
|
20008
|
-
const result = schema.safeParse(config2);
|
|
20009
|
-
if (result.success) {
|
|
20010
|
-
return { valid: true, errors: {} };
|
|
20011
|
-
}
|
|
20012
|
-
const errors3 = {};
|
|
20013
|
-
for (const issue2 of result.error.issues) {
|
|
20014
|
-
const path = issue2.path.join(".");
|
|
20015
|
-
errors3[path] = issue2.message;
|
|
20016
|
-
}
|
|
20017
|
-
return { valid: false, errors: errors3 };
|
|
20018
|
-
}
|
|
20019
|
-
var init_react_hook_form = __esm(() => {
|
|
20020
|
-
init_zod();
|
|
20021
|
-
init_configs();
|
|
20022
|
-
});
|
|
20023
|
-
|
|
20024
|
-
// ../types/src/processor/configs/index.ts
|
|
20025
|
-
function getProcessorSchemas(processorId) {
|
|
20026
|
-
return PROCESSOR_SCHEMAS[processorId];
|
|
20027
|
-
}
|
|
20028
|
-
function getConfigSchema(processorId) {
|
|
20029
|
-
return PROCESSOR_SCHEMAS[processorId]?.configSchema;
|
|
20030
|
-
}
|
|
20031
|
-
function getAllProcessorJsonSchemas() {
|
|
20032
|
-
return Object.values(PROCESSOR_SCHEMAS).map((p) => ({
|
|
20033
|
-
id: p.id,
|
|
20034
|
-
inputSchema: toJsonSchema(p.inputSchema),
|
|
20035
|
-
outputSchema: toJsonSchema(p.outputSchema),
|
|
20036
|
-
configSchema: toJsonSchema(p.configSchema)
|
|
20037
|
-
}));
|
|
20038
|
-
}
|
|
20039
|
-
function listProcessorIds() {
|
|
20040
|
-
return Object.keys(PROCESSOR_SCHEMAS);
|
|
20041
|
-
}
|
|
20042
|
-
var PROCESSOR_SCHEMAS;
|
|
20043
|
-
var init_configs = __esm(() => {
|
|
20044
|
-
init_common();
|
|
20045
|
-
init_ids();
|
|
20046
|
-
init_classify();
|
|
20047
|
-
init_classify_pages();
|
|
20048
|
-
init_document_parser();
|
|
20049
|
-
init_extract();
|
|
20050
|
-
init_merge();
|
|
20051
|
-
init_pdf_embedder();
|
|
20052
|
-
init_segment();
|
|
20053
|
-
init_split();
|
|
20054
|
-
init_template();
|
|
20055
|
-
init_xlsx_to_json();
|
|
20056
|
-
init_react_hook_form();
|
|
20057
|
-
init_classify();
|
|
20058
|
-
init_classify_pages();
|
|
20059
|
-
init_document_parser();
|
|
20060
|
-
init_extract();
|
|
20061
|
-
init_merge();
|
|
20062
|
-
init_pdf_embedder();
|
|
20063
|
-
init_segment();
|
|
20064
|
-
init_split();
|
|
20065
|
-
init_template();
|
|
20066
|
-
init_xlsx_to_json();
|
|
20067
|
-
PROCESSOR_SCHEMAS = {
|
|
20068
|
-
[PROCESSOR_IDS.EXTRACT]: {
|
|
20069
|
-
id: PROCESSOR_IDS.EXTRACT,
|
|
20070
|
-
inputSchema: ExtractInputSchema,
|
|
20071
|
-
outputSchema: ExtractOutputSchema,
|
|
20072
|
-
configSchema: ExtractConfigSchema
|
|
20073
|
-
},
|
|
20074
|
-
[PROCESSOR_IDS.DOCUMENT_PARSER]: {
|
|
20075
|
-
id: PROCESSOR_IDS.DOCUMENT_PARSER,
|
|
20076
|
-
inputSchema: DocumentParserInputSchema,
|
|
20077
|
-
outputSchema: DocumentParserOutputSchema,
|
|
20078
|
-
configSchema: DocumentParserConfigSchema
|
|
20079
|
-
},
|
|
20080
|
-
[PROCESSOR_IDS.MERGE]: {
|
|
20081
|
-
id: PROCESSOR_IDS.MERGE,
|
|
20082
|
-
inputSchema: MergeInputSchema,
|
|
20083
|
-
outputSchema: MergeOutputSchema,
|
|
20084
|
-
configSchema: MergeConfigSchema
|
|
20085
|
-
},
|
|
20086
|
-
[PROCESSOR_IDS.TEMPLATE]: {
|
|
20087
|
-
id: PROCESSOR_IDS.TEMPLATE,
|
|
20088
|
-
inputSchema: TemplateInputSchema,
|
|
20089
|
-
outputSchema: TemplateOutputSchema,
|
|
20090
|
-
configSchema: TemplateConfigSchema
|
|
20091
|
-
},
|
|
20092
|
-
[PROCESSOR_IDS.PDF_EMBEDDER]: {
|
|
20093
|
-
id: PROCESSOR_IDS.PDF_EMBEDDER,
|
|
20094
|
-
inputSchema: PdfEmbedderInputSchema,
|
|
20095
|
-
outputSchema: PdfEmbedderOutputSchema,
|
|
20096
|
-
configSchema: PdfEmbedderConfigSchema
|
|
20097
|
-
},
|
|
20098
|
-
[PROCESSOR_IDS.SPLIT]: {
|
|
20099
|
-
id: PROCESSOR_IDS.SPLIT,
|
|
20100
|
-
inputSchema: SplitInputSchema,
|
|
20101
|
-
outputSchema: SplitOutputSchema,
|
|
20102
|
-
configSchema: SplitConfigSchema
|
|
20103
|
-
},
|
|
20104
|
-
[PROCESSOR_IDS.SEGMENT]: {
|
|
20105
|
-
id: PROCESSOR_IDS.SEGMENT,
|
|
20106
|
-
inputSchema: SegmentInputSchema,
|
|
20107
|
-
outputSchema: SegmentOutputSchema,
|
|
20108
|
-
configSchema: SegmentConfigSchema
|
|
20109
|
-
},
|
|
20110
|
-
[PROCESSOR_IDS.CLASSIFY]: {
|
|
20111
|
-
id: PROCESSOR_IDS.CLASSIFY,
|
|
20112
|
-
inputSchema: ClassifyInputSchema,
|
|
20113
|
-
outputSchema: ClassifyOutputSchema,
|
|
20114
|
-
configSchema: ClassifyConfigSchema
|
|
20115
|
-
},
|
|
20116
|
-
[PROCESSOR_IDS.CLASSIFY_PAGES]: {
|
|
20117
|
-
id: PROCESSOR_IDS.CLASSIFY_PAGES,
|
|
20118
|
-
inputSchema: ClassifyPagesInputSchema,
|
|
20119
|
-
outputSchema: ClassifyPagesOutputSchema,
|
|
20120
|
-
configSchema: ClassifyPagesConfigSchema
|
|
20121
|
-
},
|
|
20122
|
-
[PROCESSOR_IDS.XLSX_TO_JSON]: {
|
|
20123
|
-
id: PROCESSOR_IDS.XLSX_TO_JSON,
|
|
20124
|
-
inputSchema: XlsxToJsonInputSchema,
|
|
20125
|
-
outputSchema: XlsxToJsonOutputSchema,
|
|
20126
|
-
configSchema: XlsxToJsonConfigSchema
|
|
20127
|
-
}
|
|
20128
|
-
};
|
|
20129
|
-
});
|
|
20130
|
-
|
|
20131
17496
|
// ../types/src/processor/index.ts
|
|
20132
|
-
var
|
|
20133
|
-
init_processor();
|
|
20134
|
-
init_execution();
|
|
20135
|
-
init_configs();
|
|
20136
|
-
});
|
|
17497
|
+
var init_processor = () => {};
|
|
20137
17498
|
|
|
20138
17499
|
// ../types/src/parser/index.ts
|
|
20139
|
-
var
|
|
20140
|
-
init_parser();
|
|
20141
|
-
});
|
|
17500
|
+
var init_parser = () => {};
|
|
20142
17501
|
|
|
20143
17502
|
// ../types/src/otel/semantic-conventions.ts
|
|
20144
17503
|
function mapLLMAttributes(attrs) {
|
|
@@ -23176,9 +20535,9 @@ var require_validate = __commonJS((exports) => {
|
|
|
23176
20535
|
}
|
|
23177
20536
|
let expr = data;
|
|
23178
20537
|
const segments = jsonPointer.split("/");
|
|
23179
|
-
for (const
|
|
23180
|
-
if (
|
|
23181
|
-
data = (0, codegen_1._)`${data}${(0, codegen_1.getProperty)((0, util_1.unescapeJsonPointer)(
|
|
20538
|
+
for (const segment of segments) {
|
|
20539
|
+
if (segment) {
|
|
20540
|
+
data = (0, codegen_1._)`${data}${(0, codegen_1.getProperty)((0, util_1.unescapeJsonPointer)(segment))}`;
|
|
23182
20541
|
expr = (0, codegen_1._)`${expr} && ${data}`;
|
|
23183
20542
|
}
|
|
23184
20543
|
}
|
|
@@ -23458,7 +20817,7 @@ var require_data = __commonJS((exports, module) => {
|
|
|
23458
20817
|
});
|
|
23459
20818
|
|
|
23460
20819
|
// ../../node_modules/fast-uri/lib/utils.js
|
|
23461
|
-
var
|
|
20820
|
+
var require_utils = __commonJS((exports, module) => {
|
|
23462
20821
|
var isUUID = RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu);
|
|
23463
20822
|
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);
|
|
23464
20823
|
function stringArrayToHexStripped(input) {
|
|
@@ -23714,7 +21073,7 @@ var require_utils3 = __commonJS((exports, module) => {
|
|
|
23714
21073
|
|
|
23715
21074
|
// ../../node_modules/fast-uri/lib/schemes.js
|
|
23716
21075
|
var require_schemes = __commonJS((exports, module) => {
|
|
23717
|
-
var { isUUID } =
|
|
21076
|
+
var { isUUID } = require_utils();
|
|
23718
21077
|
var URN_REG = /([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu;
|
|
23719
21078
|
var supportedSchemeNames = [
|
|
23720
21079
|
"http",
|
|
@@ -23888,7 +21247,7 @@ var require_schemes = __commonJS((exports, module) => {
|
|
|
23888
21247
|
|
|
23889
21248
|
// ../../node_modules/fast-uri/index.js
|
|
23890
21249
|
var require_fast_uri = __commonJS((exports, module) => {
|
|
23891
|
-
var { normalizeIPv6, removeDotSegments, recomposeAuthority, normalizeComponentEncoding, isIPv4, nonSimpleDomain } =
|
|
21250
|
+
var { normalizeIPv6, removeDotSegments, recomposeAuthority, normalizeComponentEncoding, isIPv4, nonSimpleDomain } = require_utils();
|
|
23892
21251
|
var { SCHEMES, getSchemeHandler } = require_schemes();
|
|
23893
21252
|
function normalize(uri, options) {
|
|
23894
21253
|
if (typeof uri === "string") {
|
|
@@ -26298,7 +23657,7 @@ var require_draft7 = __commonJS((exports) => {
|
|
|
26298
23657
|
});
|
|
26299
23658
|
|
|
26300
23659
|
// ../../node_modules/ajv/dist/vocabularies/discriminator/types.js
|
|
26301
|
-
var
|
|
23660
|
+
var require_types = __commonJS((exports) => {
|
|
26302
23661
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26303
23662
|
exports.DiscrError = undefined;
|
|
26304
23663
|
var DiscrError;
|
|
@@ -26312,7 +23671,7 @@ var require_types2 = __commonJS((exports) => {
|
|
|
26312
23671
|
var require_discriminator = __commonJS((exports) => {
|
|
26313
23672
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26314
23673
|
var codegen_1 = require_codegen();
|
|
26315
|
-
var types_1 =
|
|
23674
|
+
var types_1 = require_types();
|
|
26316
23675
|
var compile_1 = require_compile();
|
|
26317
23676
|
var ref_error_1 = require_ref_error();
|
|
26318
23677
|
var util_1 = require_util();
|
|
@@ -27240,6 +24599,24 @@ var init_validation = __esm(() => {
|
|
|
27240
24599
|
init_workspace_schema();
|
|
27241
24600
|
});
|
|
27242
24601
|
|
|
24602
|
+
// ../types/src/core/common.ts
|
|
24603
|
+
function toJsonSchema2(schema) {
|
|
24604
|
+
return exports_external.toJSONSchema(schema, { target: "draft-7" });
|
|
24605
|
+
}
|
|
24606
|
+
var TimestampSchema2, JsonSchemaSchema2, BaseEntitySchema2;
|
|
24607
|
+
var init_common = __esm(() => {
|
|
24608
|
+
init_zod();
|
|
24609
|
+
TimestampSchema2 = exports_external.union([exports_external.date(), exports_external.string().datetime()]).transform((val) => {
|
|
24610
|
+
return typeof val === "string" ? new Date(val) : val;
|
|
24611
|
+
});
|
|
24612
|
+
JsonSchemaSchema2 = exports_external.record(exports_external.string(), exports_external.unknown());
|
|
24613
|
+
BaseEntitySchema2 = exports_external.object({
|
|
24614
|
+
id: exports_external.string(),
|
|
24615
|
+
createdAt: TimestampSchema2.optional(),
|
|
24616
|
+
updatedAt: TimestampSchema2.optional()
|
|
24617
|
+
});
|
|
24618
|
+
});
|
|
24619
|
+
|
|
27243
24620
|
// ../../node_modules/@babel/parser/lib/index.js
|
|
27244
24621
|
var require_lib = __commonJS((exports) => {
|
|
27245
24622
|
Object.defineProperty(exports, "__esModule", {
|
|
@@ -27653,12 +25030,12 @@ var require_lib = __commonJS((exports) => {
|
|
|
27653
25030
|
}
|
|
27654
25031
|
const ParseErrorConstructors = {};
|
|
27655
25032
|
for (const reasonCode of Object.keys(argument)) {
|
|
27656
|
-
const
|
|
27657
|
-
const _ref = typeof
|
|
27658
|
-
message: () =>
|
|
27659
|
-
} : typeof
|
|
27660
|
-
message:
|
|
27661
|
-
} :
|
|
25033
|
+
const template = argument[reasonCode];
|
|
25034
|
+
const _ref = typeof template === "string" ? {
|
|
25035
|
+
message: () => template
|
|
25036
|
+
} : typeof template === "function" ? {
|
|
25037
|
+
message: template
|
|
25038
|
+
} : template, {
|
|
27662
25039
|
message
|
|
27663
25040
|
} = _ref, rest = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
27664
25041
|
const toMessage = typeof message === "string" ? () => message : message;
|
|
@@ -42131,7 +39508,7 @@ var require_keywords = __commonJS((exports) => {
|
|
|
42131
39508
|
});
|
|
42132
39509
|
|
|
42133
39510
|
// ../../node_modules/sucrase/dist/parser/tokenizer/types.js
|
|
42134
|
-
var
|
|
39511
|
+
var require_types2 = __commonJS((exports) => {
|
|
42135
39512
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
42136
39513
|
var TokenType;
|
|
42137
39514
|
(function(TokenType2) {
|
|
@@ -42195,8 +39572,8 @@ var require_types3 = __commonJS((exports) => {
|
|
|
42195
39572
|
TokenType2[TokenType2["questionDot"] = questionDot] = "questionDot";
|
|
42196
39573
|
const arrow = 22528;
|
|
42197
39574
|
TokenType2[TokenType2["arrow"] = arrow] = "arrow";
|
|
42198
|
-
const
|
|
42199
|
-
TokenType2[TokenType2["template"] =
|
|
39575
|
+
const template = 23552;
|
|
39576
|
+
TokenType2[TokenType2["template"] = template] = "template";
|
|
42200
39577
|
const ellipsis = 24576;
|
|
42201
39578
|
TokenType2[TokenType2["ellipsis"] = ellipsis] = "ellipsis";
|
|
42202
39579
|
const backQuote = 25600;
|
|
@@ -42615,7 +39992,7 @@ var require_types3 = __commonJS((exports) => {
|
|
|
42615
39992
|
var require_state = __commonJS((exports) => {
|
|
42616
39993
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
42617
39994
|
var _keywords = require_keywords();
|
|
42618
|
-
var _types =
|
|
39995
|
+
var _types = require_types2();
|
|
42619
39996
|
|
|
42620
39997
|
class Scope {
|
|
42621
39998
|
constructor(startTokenIndex, endTokenIndex, isFunctionScope) {
|
|
@@ -43001,7 +40378,7 @@ var require_base = __commonJS((exports) => {
|
|
|
43001
40378
|
var require_util2 = __commonJS((exports) => {
|
|
43002
40379
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
43003
40380
|
var _index = require_tokenizer();
|
|
43004
|
-
var _types =
|
|
40381
|
+
var _types = require_types2();
|
|
43005
40382
|
var _charcodes = require_charcodes();
|
|
43006
40383
|
var _base = require_base();
|
|
43007
40384
|
function isContextual(contextualKeyword) {
|
|
@@ -43163,7 +40540,7 @@ var require_identifier = __commonJS((exports) => {
|
|
|
43163
40540
|
var require_readWordTree = __commonJS((exports) => {
|
|
43164
40541
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
43165
40542
|
var _keywords = require_keywords();
|
|
43166
|
-
var _types =
|
|
40543
|
+
var _types = require_types2();
|
|
43167
40544
|
var READ_WORD_TREE = new Int32Array([
|
|
43168
40545
|
-1,
|
|
43169
40546
|
27,
|
|
@@ -52141,7 +49518,7 @@ var require_readWord = __commonJS((exports) => {
|
|
|
52141
49518
|
var _identifier = require_identifier();
|
|
52142
49519
|
var _index = require_tokenizer();
|
|
52143
49520
|
var _readWordTree = require_readWordTree();
|
|
52144
|
-
var _types =
|
|
49521
|
+
var _types = require_types2();
|
|
52145
49522
|
function readWord() {
|
|
52146
49523
|
let treePos = 0;
|
|
52147
49524
|
let code = 0;
|
|
@@ -52207,7 +49584,7 @@ var require_tokenizer = __commonJS((exports) => {
|
|
|
52207
49584
|
var _keywords = require_keywords();
|
|
52208
49585
|
var _readWord = require_readWord();
|
|
52209
49586
|
var _readWord2 = _interopRequireDefault(_readWord);
|
|
52210
|
-
var _types =
|
|
49587
|
+
var _types = require_types2();
|
|
52211
49588
|
var IdentifierRole;
|
|
52212
49589
|
(function(IdentifierRole2) {
|
|
52213
49590
|
const Access = 0;
|
|
@@ -52924,7 +50301,7 @@ var require_tokenizer = __commonJS((exports) => {
|
|
|
52924
50301
|
// ../../node_modules/sucrase/dist/util/getImportExportSpecifierInfo.js
|
|
52925
50302
|
var require_getImportExportSpecifierInfo = __commonJS((exports) => {
|
|
52926
50303
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
52927
|
-
var _types =
|
|
50304
|
+
var _types = require_types2();
|
|
52928
50305
|
function getImportExportSpecifierInfo(tokens, index = tokens.currentIndex()) {
|
|
52929
50306
|
let endIndex = index + 1;
|
|
52930
50307
|
if (isSpecifierEnd(tokens, endIndex)) {
|
|
@@ -53277,7 +50654,7 @@ var require_JSXTransformer = __commonJS((exports) => {
|
|
|
53277
50654
|
var _xhtml = require_xhtml();
|
|
53278
50655
|
var _xhtml2 = _interopRequireDefault(_xhtml);
|
|
53279
50656
|
var _tokenizer = require_tokenizer();
|
|
53280
|
-
var _types =
|
|
50657
|
+
var _types = require_types2();
|
|
53281
50658
|
var _charcodes = require_charcodes();
|
|
53282
50659
|
var _getJSXPragmaInfo = require_getJSXPragmaInfo();
|
|
53283
50660
|
var _getJSXPragmaInfo2 = _interopRequireDefault(_getJSXPragmaInfo);
|
|
@@ -53781,7 +51158,7 @@ var require_getNonTypeIdentifiers = __commonJS((exports) => {
|
|
|
53781
51158
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
53782
51159
|
}
|
|
53783
51160
|
var _tokenizer = require_tokenizer();
|
|
53784
|
-
var _types =
|
|
51161
|
+
var _types = require_types2();
|
|
53785
51162
|
var _JSXTransformer = require_JSXTransformer();
|
|
53786
51163
|
var _getJSXPragmaInfo = require_getJSXPragmaInfo();
|
|
53787
51164
|
var _getJSXPragmaInfo2 = _interopRequireDefault(_getJSXPragmaInfo);
|
|
@@ -53820,7 +51197,7 @@ var require_CJSImportProcessor = __commonJS((exports) => {
|
|
|
53820
51197
|
}
|
|
53821
51198
|
var _tokenizer = require_tokenizer();
|
|
53822
51199
|
var _keywords = require_keywords();
|
|
53823
|
-
var _types =
|
|
51200
|
+
var _types = require_types2();
|
|
53824
51201
|
var _getImportExportSpecifierInfo = require_getImportExportSpecifierInfo();
|
|
53825
51202
|
var _getImportExportSpecifierInfo2 = _interopRequireDefault(_getImportExportSpecifierInfo);
|
|
53826
51203
|
var _getNonTypeIdentifiers = require_getNonTypeIdentifiers();
|
|
@@ -54591,18 +51968,18 @@ var require_sourcemap_codec_umd = __commonJS((exports, module) => {
|
|
|
54591
51968
|
continue;
|
|
54592
51969
|
let genColumn = 0;
|
|
54593
51970
|
for (let j = 0;j < line.length; j++) {
|
|
54594
|
-
const
|
|
51971
|
+
const segment = line[j];
|
|
54595
51972
|
if (j > 0)
|
|
54596
51973
|
writer.write(comma);
|
|
54597
|
-
genColumn = encodeInteger(writer,
|
|
54598
|
-
if (
|
|
51974
|
+
genColumn = encodeInteger(writer, segment[0], genColumn);
|
|
51975
|
+
if (segment.length === 1)
|
|
54599
51976
|
continue;
|
|
54600
|
-
sourcesIndex = encodeInteger(writer,
|
|
54601
|
-
sourceLine = encodeInteger(writer,
|
|
54602
|
-
sourceColumn = encodeInteger(writer,
|
|
54603
|
-
if (
|
|
51977
|
+
sourcesIndex = encodeInteger(writer, segment[1], sourcesIndex);
|
|
51978
|
+
sourceLine = encodeInteger(writer, segment[2], sourceLine);
|
|
51979
|
+
sourceColumn = encodeInteger(writer, segment[3], sourceColumn);
|
|
51980
|
+
if (segment.length === 4)
|
|
54604
51981
|
continue;
|
|
54605
|
-
namesIndex = encodeInteger(writer,
|
|
51982
|
+
namesIndex = encodeInteger(writer, segment[4], namesIndex);
|
|
54606
51983
|
}
|
|
54607
51984
|
}
|
|
54608
51985
|
return writer.flush();
|
|
@@ -55157,11 +52534,11 @@ var require_trace_mapping_umd = __commonJS((exports, module) => {
|
|
|
55157
52534
|
const index = traceSegmentInternal(segments, cast(map2)._decodedMemo, line, column, bias || GREATEST_LOWER_BOUND);
|
|
55158
52535
|
if (index === -1)
|
|
55159
52536
|
return OMapping(null, null, null, null);
|
|
55160
|
-
const
|
|
55161
|
-
if (
|
|
52537
|
+
const segment = segments[index];
|
|
52538
|
+
if (segment.length === 1)
|
|
55162
52539
|
return OMapping(null, null, null, null);
|
|
55163
52540
|
const { names, resolvedSources } = map2;
|
|
55164
|
-
return OMapping(resolvedSources[
|
|
52541
|
+
return OMapping(resolvedSources[segment[SOURCES_INDEX]], segment[SOURCE_LINE] + 1, segment[SOURCE_COLUMN], segment.length === 5 ? names[segment[NAMES_INDEX]] : null);
|
|
55165
52542
|
}
|
|
55166
52543
|
function generatedPositionFor(map2, needle) {
|
|
55167
52544
|
const { source, line, column, bias } = needle;
|
|
@@ -55274,8 +52651,8 @@ var require_trace_mapping_umd = __commonJS((exports, module) => {
|
|
|
55274
52651
|
const max = upperBound(segments, matchedColumn, min);
|
|
55275
52652
|
const result = [];
|
|
55276
52653
|
for (;min <= max; min++) {
|
|
55277
|
-
const
|
|
55278
|
-
result.push(GMapping(
|
|
52654
|
+
const segment = segments[min];
|
|
52655
|
+
result.push(GMapping(segment[REV_GENERATED_LINE] + 1, segment[REV_GENERATED_COLUMN]));
|
|
55279
52656
|
}
|
|
55280
52657
|
return result;
|
|
55281
52658
|
}
|
|
@@ -55303,8 +52680,8 @@ var require_trace_mapping_umd = __commonJS((exports, module) => {
|
|
|
55303
52680
|
const index = traceSegmentInternal(segments, memo, line, column, bias);
|
|
55304
52681
|
if (index === -1)
|
|
55305
52682
|
return GMapping(null, null);
|
|
55306
|
-
const
|
|
55307
|
-
return GMapping(
|
|
52683
|
+
const segment = segments[index];
|
|
52684
|
+
return GMapping(segment[REV_GENERATED_LINE] + 1, segment[REV_GENERATED_COLUMN]);
|
|
55308
52685
|
}
|
|
55309
52686
|
});
|
|
55310
52687
|
});
|
|
@@ -55855,7 +53232,7 @@ var require_HelperManager = __commonJS((exports) => {
|
|
|
55855
53232
|
var require_identifyShadowedGlobals = __commonJS((exports) => {
|
|
55856
53233
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
55857
53234
|
var _tokenizer = require_tokenizer();
|
|
55858
|
-
var _types =
|
|
53235
|
+
var _types = require_types2();
|
|
55859
53236
|
function identifyShadowedGlobals(tokens, scopes, globalNames) {
|
|
55860
53237
|
if (!hasShadowedGlobals(tokens, globalNames)) {
|
|
55861
53238
|
return;
|
|
@@ -55920,7 +53297,7 @@ var require_identifyShadowedGlobals = __commonJS((exports) => {
|
|
|
55920
53297
|
// ../../node_modules/sucrase/dist/util/getIdentifierNames.js
|
|
55921
53298
|
var require_getIdentifierNames = __commonJS((exports) => {
|
|
55922
53299
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
55923
|
-
var _types =
|
|
53300
|
+
var _types = require_types2();
|
|
55924
53301
|
function getIdentifierNames(code, tokens) {
|
|
55925
53302
|
const names = [];
|
|
55926
53303
|
for (const token of tokens) {
|
|
@@ -56096,7 +53473,7 @@ var require_util3 = __commonJS((exports) => {
|
|
|
56096
53473
|
});
|
|
56097
53474
|
|
|
56098
53475
|
// ../../node_modules/ts-interface-checker/dist/types.js
|
|
56099
|
-
var
|
|
53476
|
+
var require_types3 = __commonJS((exports) => {
|
|
56100
53477
|
var __extends = exports && exports.__extends || function() {
|
|
56101
53478
|
var extendStatics = function(d, b) {
|
|
56102
53479
|
extendStatics = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(d2, b2) {
|
|
@@ -56696,9 +54073,9 @@ var require_dist2 = __commonJS((exports) => {
|
|
|
56696
54073
|
};
|
|
56697
54074
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
56698
54075
|
exports.Checker = exports.createCheckers = undefined;
|
|
56699
|
-
var types_1 =
|
|
54076
|
+
var types_1 = require_types3();
|
|
56700
54077
|
var util_1 = require_util3();
|
|
56701
|
-
var types_2 =
|
|
54078
|
+
var types_2 = require_types3();
|
|
56702
54079
|
Object.defineProperty(exports, "TArray", { enumerable: true, get: function() {
|
|
56703
54080
|
return types_2.TArray;
|
|
56704
54081
|
} });
|
|
@@ -56980,7 +54357,7 @@ var require_lval = __commonJS((exports) => {
|
|
|
56980
54357
|
var _typescript = require_typescript();
|
|
56981
54358
|
var _index = require_tokenizer();
|
|
56982
54359
|
var _keywords = require_keywords();
|
|
56983
|
-
var _types =
|
|
54360
|
+
var _types = require_types2();
|
|
56984
54361
|
var _base = require_base();
|
|
56985
54362
|
var _expression = require_expression();
|
|
56986
54363
|
var _util = require_util2();
|
|
@@ -57112,7 +54489,7 @@ var require_typescript = __commonJS((exports) => {
|
|
|
57112
54489
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
57113
54490
|
var _index = require_tokenizer();
|
|
57114
54491
|
var _keywords = require_keywords();
|
|
57115
|
-
var _types =
|
|
54492
|
+
var _types = require_types2();
|
|
57116
54493
|
var _base = require_base();
|
|
57117
54494
|
var _expression = require_expression();
|
|
57118
54495
|
var _lval = require_lval();
|
|
@@ -58374,7 +55751,7 @@ var require_typescript = __commonJS((exports) => {
|
|
|
58374
55751
|
var require_jsx = __commonJS((exports) => {
|
|
58375
55752
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
58376
55753
|
var _index = require_tokenizer();
|
|
58377
|
-
var _types =
|
|
55754
|
+
var _types = require_types2();
|
|
58378
55755
|
var _base = require_base();
|
|
58379
55756
|
var _expression = require_expression();
|
|
58380
55757
|
var _util = require_util2();
|
|
@@ -58637,10 +56014,10 @@ var require_jsx = __commonJS((exports) => {
|
|
|
58637
56014
|
});
|
|
58638
56015
|
|
|
58639
56016
|
// ../../node_modules/sucrase/dist/parser/plugins/types.js
|
|
58640
|
-
var
|
|
56017
|
+
var require_types4 = __commonJS((exports) => {
|
|
58641
56018
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
58642
56019
|
var _index = require_tokenizer();
|
|
58643
|
-
var _types =
|
|
56020
|
+
var _types = require_types2();
|
|
58644
56021
|
var _base = require_base();
|
|
58645
56022
|
var _expression = require_expression();
|
|
58646
56023
|
var _flow = require_flow();
|
|
@@ -58673,12 +56050,12 @@ var require_expression = __commonJS((exports) => {
|
|
|
58673
56050
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
58674
56051
|
var _flow = require_flow();
|
|
58675
56052
|
var _index = require_jsx();
|
|
58676
|
-
var _types =
|
|
56053
|
+
var _types = require_types4();
|
|
58677
56054
|
var _typescript = require_typescript();
|
|
58678
56055
|
var _index3 = require_tokenizer();
|
|
58679
56056
|
var _keywords = require_keywords();
|
|
58680
56057
|
var _state = require_state();
|
|
58681
|
-
var _types3 =
|
|
56058
|
+
var _types3 = require_types2();
|
|
58682
56059
|
var _charcodes = require_charcodes();
|
|
58683
56060
|
var _identifier = require_identifier();
|
|
58684
56061
|
var _base = require_base();
|
|
@@ -59394,7 +56771,7 @@ var require_flow = __commonJS((exports) => {
|
|
|
59394
56771
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
59395
56772
|
var _index = require_tokenizer();
|
|
59396
56773
|
var _keywords = require_keywords();
|
|
59397
|
-
var _types =
|
|
56774
|
+
var _types = require_types2();
|
|
59398
56775
|
var _base = require_base();
|
|
59399
56776
|
var _expression = require_expression();
|
|
59400
56777
|
var _statement = require_statement();
|
|
@@ -60269,7 +57646,7 @@ var require_statement = __commonJS((exports) => {
|
|
|
60269
57646
|
var _tokenizer = require_tokenizer();
|
|
60270
57647
|
var _keywords = require_keywords();
|
|
60271
57648
|
var _state = require_state();
|
|
60272
|
-
var _types =
|
|
57649
|
+
var _types = require_types2();
|
|
60273
57650
|
var _charcodes = require_charcodes();
|
|
60274
57651
|
var _base = require_base();
|
|
60275
57652
|
var _expression = require_expression();
|
|
@@ -61304,7 +58681,7 @@ var require_TokenProcessor = __commonJS((exports) => {
|
|
|
61304
58681
|
function _interopRequireDefault(obj) {
|
|
61305
58682
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
61306
58683
|
}
|
|
61307
|
-
var _types =
|
|
58684
|
+
var _types = require_types2();
|
|
61308
58685
|
var _isAsyncOperation = require_isAsyncOperation();
|
|
61309
58686
|
var _isAsyncOperation2 = _interopRequireDefault(_isAsyncOperation);
|
|
61310
58687
|
|
|
@@ -61562,7 +58939,7 @@ var require_TokenProcessor = __commonJS((exports) => {
|
|
|
61562
58939
|
var require_getClassInfo = __commonJS((exports) => {
|
|
61563
58940
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
61564
58941
|
var _keywords = require_keywords();
|
|
61565
|
-
var _types =
|
|
58942
|
+
var _types = require_types2();
|
|
61566
58943
|
function getClassInfo(rootTransformer, tokens, nameManager, disableESTransforms) {
|
|
61567
58944
|
const snapshot = tokens.snapshot();
|
|
61568
58945
|
const headerInfo = processClassHeader(tokens);
|
|
@@ -61800,7 +59177,7 @@ var require_getClassInfo = __commonJS((exports) => {
|
|
|
61800
59177
|
// ../../node_modules/sucrase/dist/util/elideImportEquals.js
|
|
61801
59178
|
var require_elideImportEquals = __commonJS((exports) => {
|
|
61802
59179
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
61803
|
-
var _types =
|
|
59180
|
+
var _types = require_types2();
|
|
61804
59181
|
function elideImportEquals(tokens) {
|
|
61805
59182
|
tokens.removeInitialToken();
|
|
61806
59183
|
tokens.removeToken();
|
|
@@ -61824,7 +59201,7 @@ var require_elideImportEquals = __commonJS((exports) => {
|
|
|
61824
59201
|
var require_getDeclarationInfo = __commonJS((exports) => {
|
|
61825
59202
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
61826
59203
|
var _tokenizer = require_tokenizer();
|
|
61827
|
-
var _types =
|
|
59204
|
+
var _types = require_types2();
|
|
61828
59205
|
var EMPTY_DECLARATION_INFO = {
|
|
61829
59206
|
typeDeclarations: new Set,
|
|
61830
59207
|
valueDeclarations: new Set
|
|
@@ -61852,7 +59229,7 @@ var require_getDeclarationInfo = __commonJS((exports) => {
|
|
|
61852
59229
|
var require_isExportFrom = __commonJS((exports) => {
|
|
61853
59230
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
61854
59231
|
var _keywords = require_keywords();
|
|
61855
|
-
var _types =
|
|
59232
|
+
var _types = require_types2();
|
|
61856
59233
|
function isExportFrom(tokens) {
|
|
61857
59234
|
let closeBraceIndex = tokens.currentIndex();
|
|
61858
59235
|
while (!tokens.matches1AtIndex(closeBraceIndex, _types.TokenType.braceR)) {
|
|
@@ -61867,7 +59244,7 @@ var require_isExportFrom = __commonJS((exports) => {
|
|
|
61867
59244
|
var require_removeMaybeImportAttributes = __commonJS((exports) => {
|
|
61868
59245
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
61869
59246
|
var _keywords = require_keywords();
|
|
61870
|
-
var _types =
|
|
59247
|
+
var _types = require_types2();
|
|
61871
59248
|
function removeMaybeImportAttributes(tokens) {
|
|
61872
59249
|
if (tokens.matches2(_types.TokenType._with, _types.TokenType.braceL) || tokens.matches2(_types.TokenType.name, _types.TokenType.braceL) && tokens.matchesContextual(_keywords.ContextualKeyword._assert)) {
|
|
61873
59250
|
tokens.removeToken();
|
|
@@ -61882,7 +59259,7 @@ var require_removeMaybeImportAttributes = __commonJS((exports) => {
|
|
|
61882
59259
|
// ../../node_modules/sucrase/dist/util/shouldElideDefaultExport.js
|
|
61883
59260
|
var require_shouldElideDefaultExport = __commonJS((exports) => {
|
|
61884
59261
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
61885
|
-
var _types =
|
|
59262
|
+
var _types = require_types2();
|
|
61886
59263
|
function shouldElideDefaultExport(isTypeScriptTransformEnabled, keepUnusedImports, tokens, declarationInfo) {
|
|
61887
59264
|
if (!isTypeScriptTransformEnabled || keepUnusedImports) {
|
|
61888
59265
|
return false;
|
|
@@ -61913,7 +59290,7 @@ var require_CJSImportTransformer = __commonJS((exports) => {
|
|
|
61913
59290
|
}
|
|
61914
59291
|
var _tokenizer = require_tokenizer();
|
|
61915
59292
|
var _keywords = require_keywords();
|
|
61916
|
-
var _types =
|
|
59293
|
+
var _types = require_types2();
|
|
61917
59294
|
var _elideImportEquals = require_elideImportEquals();
|
|
61918
59295
|
var _elideImportEquals2 = _interopRequireDefault(_elideImportEquals);
|
|
61919
59296
|
var _getDeclarationInfo = require_getDeclarationInfo();
|
|
@@ -62555,7 +59932,7 @@ var require_ESMImportTransformer = __commonJS((exports) => {
|
|
|
62555
59932
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
62556
59933
|
}
|
|
62557
59934
|
var _keywords = require_keywords();
|
|
62558
|
-
var _types =
|
|
59935
|
+
var _types = require_types2();
|
|
62559
59936
|
var _elideImportEquals = require_elideImportEquals();
|
|
62560
59937
|
var _elideImportEquals2 = _interopRequireDefault(_elideImportEquals);
|
|
62561
59938
|
var _getDeclarationInfo = require_getDeclarationInfo();
|
|
@@ -62825,7 +60202,7 @@ var require_FlowTransformer = __commonJS((exports) => {
|
|
|
62825
60202
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
62826
60203
|
}
|
|
62827
60204
|
var _keywords = require_keywords();
|
|
62828
|
-
var _types =
|
|
60205
|
+
var _types = require_types2();
|
|
62829
60206
|
var _Transformer = require_Transformer();
|
|
62830
60207
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
62831
60208
|
|
|
@@ -62945,7 +60322,7 @@ var require_JestHoistTransformer = __commonJS((exports) => {
|
|
|
62945
60322
|
}
|
|
62946
60323
|
return value;
|
|
62947
60324
|
}
|
|
62948
|
-
var _types =
|
|
60325
|
+
var _types = require_types2();
|
|
62949
60326
|
var _Transformer = require_Transformer();
|
|
62950
60327
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
62951
60328
|
var JEST_GLOBAL_NAME = "jest";
|
|
@@ -63019,7 +60396,7 @@ var require_NumericSeparatorTransformer = __commonJS((exports) => {
|
|
|
63019
60396
|
function _interopRequireDefault(obj) {
|
|
63020
60397
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
63021
60398
|
}
|
|
63022
|
-
var _types =
|
|
60399
|
+
var _types = require_types2();
|
|
63023
60400
|
var _Transformer = require_Transformer();
|
|
63024
60401
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
63025
60402
|
|
|
@@ -63048,7 +60425,7 @@ var require_OptionalCatchBindingTransformer = __commonJS((exports) => {
|
|
|
63048
60425
|
function _interopRequireDefault(obj) {
|
|
63049
60426
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
63050
60427
|
}
|
|
63051
|
-
var _types =
|
|
60428
|
+
var _types = require_types2();
|
|
63052
60429
|
var _Transformer = require_Transformer();
|
|
63053
60430
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
63054
60431
|
|
|
@@ -63076,7 +60453,7 @@ var require_OptionalChainingNullishTransformer = __commonJS((exports) => {
|
|
|
63076
60453
|
function _interopRequireDefault(obj) {
|
|
63077
60454
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
63078
60455
|
}
|
|
63079
|
-
var _types =
|
|
60456
|
+
var _types = require_types2();
|
|
63080
60457
|
var _Transformer = require_Transformer();
|
|
63081
60458
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
63082
60459
|
|
|
@@ -63192,7 +60569,7 @@ var require_ReactDisplayNameTransformer = __commonJS((exports) => {
|
|
|
63192
60569
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
63193
60570
|
}
|
|
63194
60571
|
var _tokenizer = require_tokenizer();
|
|
63195
|
-
var _types =
|
|
60572
|
+
var _types = require_types2();
|
|
63196
60573
|
var _Transformer = require_Transformer();
|
|
63197
60574
|
var _Transformer2 = _interopRequireDefault(_Transformer);
|
|
63198
60575
|
|
|
@@ -63443,7 +60820,7 @@ var require_TypeScriptTransformer = __commonJS((exports) => {
|
|
|
63443
60820
|
function _interopRequireDefault(obj) {
|
|
63444
60821
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
63445
60822
|
}
|
|
63446
|
-
var _types =
|
|
60823
|
+
var _types = require_types2();
|
|
63447
60824
|
var _isIdentifier = require_isIdentifier();
|
|
63448
60825
|
var _isIdentifier2 = _interopRequireDefault(_isIdentifier);
|
|
63449
60826
|
var _Transformer = require_Transformer();
|
|
@@ -63589,7 +60966,7 @@ var require_RootTransformer = __commonJS((exports) => {
|
|
|
63589
60966
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
63590
60967
|
}
|
|
63591
60968
|
var _keywords = require_keywords();
|
|
63592
|
-
var _types =
|
|
60969
|
+
var _types = require_types2();
|
|
63593
60970
|
var _getClassInfo = require_getClassInfo();
|
|
63594
60971
|
var _getClassInfo2 = _interopRequireDefault(_getClassInfo);
|
|
63595
60972
|
var _CJSImportTransformer = require_CJSImportTransformer();
|
|
@@ -63988,7 +61365,7 @@ var require_formatTokens = __commonJS((exports) => {
|
|
|
63988
61365
|
}
|
|
63989
61366
|
var _linesandcolumns = require_build();
|
|
63990
61367
|
var _linesandcolumns2 = _interopRequireDefault(_linesandcolumns);
|
|
63991
|
-
var _types =
|
|
61368
|
+
var _types = require_types2();
|
|
63992
61369
|
function formatTokens(code, tokens) {
|
|
63993
61370
|
if (tokens.length === 0) {
|
|
63994
61371
|
return "";
|
|
@@ -64053,7 +61430,7 @@ var require_getTSImportedNames = __commonJS((exports) => {
|
|
|
64053
61430
|
function _interopRequireDefault(obj) {
|
|
64054
61431
|
return obj && obj.__esModule ? obj : { default: obj };
|
|
64055
61432
|
}
|
|
64056
|
-
var _types =
|
|
61433
|
+
var _types = require_types2();
|
|
64057
61434
|
var _getImportExportSpecifierInfo = require_getImportExportSpecifierInfo();
|
|
64058
61435
|
var _getImportExportSpecifierInfo2 = _interopRequireDefault(_getImportExportSpecifierInfo);
|
|
64059
61436
|
function getTSImportedNames(tokens) {
|
|
@@ -64438,7 +61815,7 @@ function describeUnsupportedType(nodeType) {
|
|
|
64438
61815
|
function compileTypedScript(opts) {
|
|
64439
61816
|
let ast;
|
|
64440
61817
|
try {
|
|
64441
|
-
ast =
|
|
61818
|
+
ast = import_parser2.parse(opts.source, {
|
|
64442
61819
|
sourceType: "script",
|
|
64443
61820
|
plugins: ["typescript"],
|
|
64444
61821
|
ranges: true
|
|
@@ -64690,9 +62067,9 @@ function stripCommentsAndStrings(s) {
|
|
|
64690
62067
|
out = out.replace(/`(\\.|[^`\\])*`/g, "``");
|
|
64691
62068
|
return out;
|
|
64692
62069
|
}
|
|
64693
|
-
var
|
|
62070
|
+
var import_parser2, import_sucrase, EVALUATOR_FN_NAME = "scoreScript", EVALUATOR_PARAM_NAMES, TRANSFORM_FN_NAME = "script";
|
|
64694
62071
|
var init_compile = __esm(() => {
|
|
64695
|
-
|
|
62072
|
+
import_parser2 = __toESM(require_lib(), 1);
|
|
64696
62073
|
import_sucrase = __toESM(require_dist3(), 1);
|
|
64697
62074
|
EVALUATOR_PARAM_NAMES = ["expected", "actual"];
|
|
64698
62075
|
});
|
|
@@ -65054,8 +62431,8 @@ function getAllStepJsonSchemas() {
|
|
|
65054
62431
|
category: def.category,
|
|
65055
62432
|
name: def.name,
|
|
65056
62433
|
description: def.description,
|
|
65057
|
-
configSchema:
|
|
65058
|
-
outputSchema:
|
|
62434
|
+
configSchema: toJsonSchema2(def.configSchema),
|
|
62435
|
+
outputSchema: toJsonSchema2(def.outputSchema),
|
|
65059
62436
|
configInWith: def.configInWith
|
|
65060
62437
|
}));
|
|
65061
62438
|
}
|
|
@@ -65969,6 +63346,81 @@ var init_actions = __esm(() => {
|
|
|
65969
63346
|
ACTION_TYPES = ActionTypeSchema.options;
|
|
65970
63347
|
});
|
|
65971
63348
|
|
|
63349
|
+
// ../types/src/processor/execution.ts
|
|
63350
|
+
function asTuple(values) {
|
|
63351
|
+
return values;
|
|
63352
|
+
}
|
|
63353
|
+
var WorkflowExecutionStatusValue2, WorkflowExecutionStatusSchema2, StepExecutionStatusValue2, StepExecutionStatusSchema2, TriggerTypeValue2, TriggerTypeSchema2, ExecutionTypeValue2, ExecutionTypeSchema2, WORKFLOW_EXECUTION_STATUSES2, STEP_EXECUTION_STATUSES2, TRIGGER_TYPES2, EXECUTION_TYPES2;
|
|
63354
|
+
var init_execution = __esm(() => {
|
|
63355
|
+
init_zod();
|
|
63356
|
+
WorkflowExecutionStatusValue2 = {
|
|
63357
|
+
CREATED: "created",
|
|
63358
|
+
PENDING: "pending",
|
|
63359
|
+
RUNNING: "running",
|
|
63360
|
+
WAITING: "waiting",
|
|
63361
|
+
COMPLETED: "completed",
|
|
63362
|
+
FAILED: "failed",
|
|
63363
|
+
CANCELLED: "cancelled"
|
|
63364
|
+
};
|
|
63365
|
+
WorkflowExecutionStatusSchema2 = exports_external.enum([
|
|
63366
|
+
WorkflowExecutionStatusValue2.CREATED,
|
|
63367
|
+
WorkflowExecutionStatusValue2.PENDING,
|
|
63368
|
+
WorkflowExecutionStatusValue2.RUNNING,
|
|
63369
|
+
WorkflowExecutionStatusValue2.WAITING,
|
|
63370
|
+
WorkflowExecutionStatusValue2.COMPLETED,
|
|
63371
|
+
WorkflowExecutionStatusValue2.FAILED,
|
|
63372
|
+
WorkflowExecutionStatusValue2.CANCELLED
|
|
63373
|
+
]);
|
|
63374
|
+
StepExecutionStatusValue2 = {
|
|
63375
|
+
PENDING: "pending",
|
|
63376
|
+
RUNNING: "running",
|
|
63377
|
+
SUCCESS: "success",
|
|
63378
|
+
FAILURE: "failure",
|
|
63379
|
+
WAITING: "waiting",
|
|
63380
|
+
SKIPPED: "skipped"
|
|
63381
|
+
};
|
|
63382
|
+
StepExecutionStatusSchema2 = exports_external.enum([
|
|
63383
|
+
StepExecutionStatusValue2.PENDING,
|
|
63384
|
+
StepExecutionStatusValue2.RUNNING,
|
|
63385
|
+
StepExecutionStatusValue2.SUCCESS,
|
|
63386
|
+
StepExecutionStatusValue2.FAILURE,
|
|
63387
|
+
StepExecutionStatusValue2.WAITING,
|
|
63388
|
+
StepExecutionStatusValue2.SKIPPED
|
|
63389
|
+
]);
|
|
63390
|
+
TriggerTypeValue2 = {
|
|
63391
|
+
MANUAL: "manual",
|
|
63392
|
+
API: "api",
|
|
63393
|
+
WEBHOOK: "webhook",
|
|
63394
|
+
SCHEDULE: "schedule",
|
|
63395
|
+
EMAIL: "email",
|
|
63396
|
+
EVAL: "eval",
|
|
63397
|
+
CLI: "cli"
|
|
63398
|
+
};
|
|
63399
|
+
TriggerTypeSchema2 = exports_external.enum([
|
|
63400
|
+
TriggerTypeValue2.MANUAL,
|
|
63401
|
+
TriggerTypeValue2.API,
|
|
63402
|
+
TriggerTypeValue2.WEBHOOK,
|
|
63403
|
+
TriggerTypeValue2.SCHEDULE,
|
|
63404
|
+
TriggerTypeValue2.EMAIL,
|
|
63405
|
+
TriggerTypeValue2.EVAL,
|
|
63406
|
+
TriggerTypeValue2.CLI
|
|
63407
|
+
]);
|
|
63408
|
+
ExecutionTypeValue2 = {
|
|
63409
|
+
PROD: "prod",
|
|
63410
|
+
EVAL: "eval",
|
|
63411
|
+
PLAYGROUND: "playground"
|
|
63412
|
+
};
|
|
63413
|
+
ExecutionTypeSchema2 = exports_external.enum([
|
|
63414
|
+
ExecutionTypeValue2.PROD,
|
|
63415
|
+
ExecutionTypeValue2.EVAL,
|
|
63416
|
+
ExecutionTypeValue2.PLAYGROUND
|
|
63417
|
+
]);
|
|
63418
|
+
WORKFLOW_EXECUTION_STATUSES2 = asTuple(WorkflowExecutionStatusSchema2.options);
|
|
63419
|
+
STEP_EXECUTION_STATUSES2 = asTuple(StepExecutionStatusSchema2.options);
|
|
63420
|
+
TRIGGER_TYPES2 = TriggerTypeSchema2.options;
|
|
63421
|
+
EXECUTION_TYPES2 = ExecutionTypeSchema2.options;
|
|
63422
|
+
});
|
|
63423
|
+
|
|
65972
63424
|
// ../types/src/workflow/workflow.ts
|
|
65973
63425
|
function suggestWorkflowName(raw) {
|
|
65974
63426
|
return raw.toLowerCase().replace(/[^a-z0-9_-]+/g, "-").replace(/^[_-]+|[_-]+$/g, "").slice(0, 64);
|
|
@@ -66050,11 +63502,11 @@ var init_workflow = __esm(() => {
|
|
|
66050
63502
|
ManualTriggerMethodSchema = exports_external.object({
|
|
66051
63503
|
type: exports_external.literal("manual"),
|
|
66052
63504
|
enabled: exports_external.boolean().optional(),
|
|
66053
|
-
inputSchema:
|
|
63505
|
+
inputSchema: JsonSchemaSchema2.optional()
|
|
66054
63506
|
});
|
|
66055
63507
|
ApiTriggerMethodSchema = exports_external.object({
|
|
66056
63508
|
type: exports_external.literal("api"),
|
|
66057
|
-
inputSchema:
|
|
63509
|
+
inputSchema: JsonSchemaSchema2.optional()
|
|
66058
63510
|
});
|
|
66059
63511
|
EmailTriggerMethodSchema = exports_external.object({
|
|
66060
63512
|
type: exports_external.literal("email"),
|
|
@@ -66094,8 +63546,8 @@ var init_workflow = __esm(() => {
|
|
|
66094
63546
|
yamlContent: exports_external.string(),
|
|
66095
63547
|
definition: WorkflowDefinitionSchema,
|
|
66096
63548
|
isCurrent: exports_external.boolean().default(true),
|
|
66097
|
-
createdAt:
|
|
66098
|
-
updatedAt:
|
|
63549
|
+
createdAt: TimestampSchema2,
|
|
63550
|
+
updatedAt: TimestampSchema2.optional(),
|
|
66099
63551
|
createdBy: exports_external.string()
|
|
66100
63552
|
});
|
|
66101
63553
|
CreateWorkflowDefinitionSchema = exports_external.object({
|
|
@@ -66277,15 +63729,15 @@ function isFileOutput(value) {
|
|
|
66277
63729
|
function isWorkflowResult(value) {
|
|
66278
63730
|
return value != null && typeof value === "object" && "files" in value && Array.isArray(value.files);
|
|
66279
63731
|
}
|
|
66280
|
-
var
|
|
63732
|
+
var WorkflowExecutionStatusSchema3, StepExecutionStatusSchema3, ScopeEntryTypeSchema, ScopeEntrySchema, ScopeStackSchema, StepResultSchema, ExecutionContextSchema, StepInputReferenceSchema, WorkflowExecutionSchema, StepExecutionSchema, StepExecutionAttemptSchema, ConnectorSchema, WorkflowFileOutputSchema, WorkflowResultSchema;
|
|
66281
63733
|
var init_execution2 = __esm(() => {
|
|
66282
63734
|
init_zod();
|
|
66283
63735
|
init_common();
|
|
66284
63736
|
init_execution();
|
|
66285
63737
|
init_retry();
|
|
66286
63738
|
init_workflow();
|
|
66287
|
-
|
|
66288
|
-
|
|
63739
|
+
WorkflowExecutionStatusSchema3 = WorkflowExecutionStatusSchema2;
|
|
63740
|
+
StepExecutionStatusSchema3 = StepExecutionStatusSchema2;
|
|
66289
63741
|
ScopeEntryTypeSchema = exports_external.enum([
|
|
66290
63742
|
"root",
|
|
66291
63743
|
"if-then",
|
|
@@ -66308,7 +63760,7 @@ var init_execution2 = __esm(() => {
|
|
|
66308
63760
|
ScopeStackSchema = exports_external.array(ScopeEntrySchema);
|
|
66309
63761
|
StepResultSchema = exports_external.object({
|
|
66310
63762
|
output: exports_external.unknown(),
|
|
66311
|
-
status:
|
|
63763
|
+
status: StepExecutionStatusSchema3
|
|
66312
63764
|
});
|
|
66313
63765
|
ExecutionContextSchema = exports_external.object({
|
|
66314
63766
|
input: exports_external.record(exports_external.string(), exports_external.unknown()),
|
|
@@ -66336,24 +63788,24 @@ var init_execution2 = __esm(() => {
|
|
|
66336
63788
|
triggerType: exports_external.string(),
|
|
66337
63789
|
triggerInput: exports_external.record(exports_external.string(), exports_external.unknown()).nullable(),
|
|
66338
63790
|
overrides: exports_external.object({ steps: exports_external.record(exports_external.string(), exports_external.record(exports_external.string(), exports_external.unknown())).optional() }).nullable().optional(),
|
|
66339
|
-
status:
|
|
63791
|
+
status: WorkflowExecutionStatusSchema3,
|
|
66340
63792
|
scopeStack: ScopeStackSchema,
|
|
66341
63793
|
currentStepIndex: exports_external.number(),
|
|
66342
63794
|
stepResults: exports_external.record(exports_external.string(), StepResultSchema).optional(),
|
|
66343
63795
|
result: exports_external.unknown().nullable(),
|
|
66344
63796
|
error: exports_external.string().nullable(),
|
|
66345
63797
|
priority: exports_external.number().default(50),
|
|
66346
|
-
availableAt:
|
|
63798
|
+
availableAt: TimestampSchema2,
|
|
66347
63799
|
leaseId: exports_external.string().nullable(),
|
|
66348
|
-
leaseExpiresAt:
|
|
63800
|
+
leaseExpiresAt: TimestampSchema2.nullable(),
|
|
66349
63801
|
workerId: exports_external.string().nullable(),
|
|
66350
63802
|
maxRetries: exports_external.number().default(0),
|
|
66351
63803
|
originalExecutionId: exports_external.string().nullable().optional(),
|
|
66352
63804
|
previousExecutionId: exports_external.string().nullable().optional(),
|
|
66353
63805
|
retryNumber: exports_external.number().default(0),
|
|
66354
|
-
createdAt:
|
|
66355
|
-
startedAt:
|
|
66356
|
-
completedAt:
|
|
63806
|
+
createdAt: TimestampSchema2,
|
|
63807
|
+
startedAt: TimestampSchema2.nullable(),
|
|
63808
|
+
completedAt: TimestampSchema2.nullable(),
|
|
66357
63809
|
createdBy: exports_external.string().nullable()
|
|
66358
63810
|
});
|
|
66359
63811
|
StepExecutionSchema = exports_external.object({
|
|
@@ -66372,15 +63824,15 @@ var init_execution2 = __esm(() => {
|
|
|
66372
63824
|
effectiveRetryPolicy: ResolvedRetryPolicySchema.nullable().optional(),
|
|
66373
63825
|
retryPolicySource: RetryPolicySourceSchema.nullable().optional(),
|
|
66374
63826
|
latestAttempt: exports_external.number().default(0),
|
|
66375
|
-
nextAttemptAt:
|
|
63827
|
+
nextAttemptAt: TimestampSchema2.nullable().optional(),
|
|
66376
63828
|
inputData: exports_external.unknown().nullable(),
|
|
66377
63829
|
outputData: exports_external.unknown().nullable(),
|
|
66378
|
-
status:
|
|
63830
|
+
status: StepExecutionStatusSchema3,
|
|
66379
63831
|
error: exports_external.string().nullable(),
|
|
66380
63832
|
overrideMode: exports_external.enum(["skipped", "partial"]).nullable().optional(),
|
|
66381
63833
|
durationMs: exports_external.number().nullable(),
|
|
66382
|
-
startedAt:
|
|
66383
|
-
completedAt:
|
|
63834
|
+
startedAt: TimestampSchema2.nullable(),
|
|
63835
|
+
completedAt: TimestampSchema2.nullable()
|
|
66384
63836
|
});
|
|
66385
63837
|
StepExecutionAttemptSchema = exports_external.object({
|
|
66386
63838
|
id: exports_external.string(),
|
|
@@ -66393,8 +63845,8 @@ var init_execution2 = __esm(() => {
|
|
|
66393
63845
|
failure: ExecutionFailureSchema.nullable(),
|
|
66394
63846
|
retryDecision: RetryDecisionSchema.nullable(),
|
|
66395
63847
|
replaySafe: exports_external.boolean().nullable(),
|
|
66396
|
-
startedAt:
|
|
66397
|
-
completedAt:
|
|
63848
|
+
startedAt: TimestampSchema2,
|
|
63849
|
+
completedAt: TimestampSchema2.nullable(),
|
|
66398
63850
|
durationMs: exports_external.number().nullable()
|
|
66399
63851
|
});
|
|
66400
63852
|
ConnectorSchema = exports_external.object({
|
|
@@ -66406,8 +63858,8 @@ var init_execution2 = __esm(() => {
|
|
|
66406
63858
|
config: exports_external.record(exports_external.string(), exports_external.unknown()),
|
|
66407
63859
|
inputSchema: exports_external.unknown().optional(),
|
|
66408
63860
|
outputSchema: exports_external.unknown().optional(),
|
|
66409
|
-
createdAt:
|
|
66410
|
-
updatedAt:
|
|
63861
|
+
createdAt: TimestampSchema2,
|
|
63862
|
+
updatedAt: TimestampSchema2.optional(),
|
|
66411
63863
|
createdBy: exports_external.string()
|
|
66412
63864
|
});
|
|
66413
63865
|
WorkflowFileOutputSchema = exports_external.object({
|
|
@@ -67373,8 +64825,8 @@ function parseRunTarget(target) {
|
|
|
67373
64825
|
if (root !== "agents") {
|
|
67374
64826
|
throw new Error(`Agent target must be rooted at "agents.", got "${idOrSlug2}"`);
|
|
67375
64827
|
}
|
|
67376
|
-
for (const
|
|
67377
|
-
RunTargetSegmentSchema.parse(
|
|
64828
|
+
for (const segment of segments) {
|
|
64829
|
+
RunTargetSegmentSchema.parse(segment);
|
|
67378
64830
|
}
|
|
67379
64831
|
const packagePath = packageName.split(".").join("/");
|
|
67380
64832
|
const [, ...slugParts] = packagePath.split("/");
|
|
@@ -67487,9 +64939,9 @@ var init_grammar = __esm(() => {
|
|
|
67487
64939
|
if (!SourcePackageTypeSchema.safeParse(parts[0]).success) {
|
|
67488
64940
|
ctx.addIssue({ code: "custom", message: `Invalid package root: ${parts[0]}` });
|
|
67489
64941
|
}
|
|
67490
|
-
for (const
|
|
67491
|
-
if (!SourcePackageSegmentSchema.safeParse(
|
|
67492
|
-
ctx.addIssue({ code: "custom", message: `Invalid package segment: ${
|
|
64942
|
+
for (const segment of parts.slice(1)) {
|
|
64943
|
+
if (!SourcePackageSegmentSchema.safeParse(segment).success) {
|
|
64944
|
+
ctx.addIssue({ code: "custom", message: `Invalid package segment: ${segment}` });
|
|
67493
64945
|
}
|
|
67494
64946
|
}
|
|
67495
64947
|
});
|
|
@@ -67505,9 +64957,9 @@ var init_grammar = __esm(() => {
|
|
|
67505
64957
|
if (!SourcePackageTypeSchema.safeParse(parts[0]).success) {
|
|
67506
64958
|
ctx.addIssue({ code: "custom", message: `Invalid package root: ${parts[0]}` });
|
|
67507
64959
|
}
|
|
67508
|
-
for (const
|
|
67509
|
-
if (!SourcePackageSegmentSchema.safeParse(
|
|
67510
|
-
ctx.addIssue({ code: "custom", message: `Invalid package segment: ${
|
|
64960
|
+
for (const segment of parts.slice(1)) {
|
|
64961
|
+
if (!SourcePackageSegmentSchema.safeParse(segment).success) {
|
|
64962
|
+
ctx.addIssue({ code: "custom", message: `Invalid package segment: ${segment}` });
|
|
67511
64963
|
}
|
|
67512
64964
|
}
|
|
67513
64965
|
});
|
|
@@ -67601,9 +65053,9 @@ var init_grammar = __esm(() => {
|
|
|
67601
65053
|
});
|
|
67602
65054
|
return;
|
|
67603
65055
|
}
|
|
67604
|
-
for (const
|
|
67605
|
-
if (!RunTargetSegmentSchema.safeParse(
|
|
67606
|
-
ctx.addIssue({ code: "custom", message: `Invalid run target segment: ${
|
|
65056
|
+
for (const segment of parts.slice(1)) {
|
|
65057
|
+
if (!RunTargetSegmentSchema.safeParse(segment).success) {
|
|
65058
|
+
ctx.addIssue({ code: "custom", message: `Invalid run target segment: ${segment}` });
|
|
67607
65059
|
}
|
|
67608
65060
|
}
|
|
67609
65061
|
if (ref) {
|
|
@@ -68353,7 +65805,7 @@ function fromBig(n, le = false) {
|
|
|
68353
65805
|
return { h: Number(n & U32_MASK64), l: Number(n >> _32n & U32_MASK64) };
|
|
68354
65806
|
return { h: Number(n >> _32n & U32_MASK64) | 0, l: Number(n & U32_MASK64) | 0 };
|
|
68355
65807
|
}
|
|
68356
|
-
function
|
|
65808
|
+
function split(lst, le = false) {
|
|
68357
65809
|
const len = lst.length;
|
|
68358
65810
|
let Ah = new Uint32Array(len);
|
|
68359
65811
|
let Al = new Uint32Array(len);
|
|
@@ -68533,7 +65985,7 @@ var init_sha2 = __esm(() => {
|
|
|
68533
65985
|
super(28);
|
|
68534
65986
|
}
|
|
68535
65987
|
};
|
|
68536
|
-
K512 = /* @__PURE__ */ (() =>
|
|
65988
|
+
K512 = /* @__PURE__ */ (() => split([
|
|
68537
65989
|
"0x428a2f98d728ae22",
|
|
68538
65990
|
"0x7137449123ef65cd",
|
|
68539
65991
|
"0xb5c0fbcfec4d3b2f",
|
|
@@ -70856,11 +68308,11 @@ function walkGrammar(node, parts) {
|
|
|
70856
68308
|
}
|
|
70857
68309
|
return current;
|
|
70858
68310
|
}
|
|
70859
|
-
function normalizeTemplate(
|
|
70860
|
-
return
|
|
68311
|
+
function normalizeTemplate(template) {
|
|
68312
|
+
return template.endsWith("/") ? template.slice(0, -1) : template;
|
|
70861
68313
|
}
|
|
70862
|
-
function renderTemplate(
|
|
70863
|
-
return normalizeTemplate(
|
|
68314
|
+
function renderTemplate(template, params) {
|
|
68315
|
+
return normalizeTemplate(template).split("/").flatMap((part) => {
|
|
70864
68316
|
if (!part.startsWith(":")) {
|
|
70865
68317
|
return [part];
|
|
70866
68318
|
}
|
|
@@ -70870,36 +68322,36 @@ function renderTemplate(template2, params) {
|
|
|
70870
68322
|
throw new Error(`Missing S3 path parameter: ${part}`);
|
|
70871
68323
|
}
|
|
70872
68324
|
if (name === "path") {
|
|
70873
|
-
return value.split("/").map((
|
|
68325
|
+
return value.split("/").map((segment) => assertSegment("path", segment));
|
|
70874
68326
|
}
|
|
70875
68327
|
return [assertSegment(String(name), value)];
|
|
70876
68328
|
});
|
|
70877
68329
|
}
|
|
70878
|
-
function buildS3Path(tenantId,
|
|
68330
|
+
function buildS3Path(tenantId, template, params) {
|
|
70879
68331
|
const tenant = assertSegment("tenantId", tenantId);
|
|
70880
|
-
const parts = renderTemplate(
|
|
68332
|
+
const parts = renderTemplate(template, params);
|
|
70881
68333
|
const node = walkGrammar(S3_PATH_GRAMMAR, parts);
|
|
70882
|
-
if (
|
|
70883
|
-
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(
|
|
68334
|
+
if (template.endsWith("/") && node === PATH_LEAF) {
|
|
68335
|
+
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(template)}`);
|
|
70884
68336
|
}
|
|
70885
68337
|
const path = ["tenants", tenant, ...parts].join("/");
|
|
70886
|
-
return
|
|
68338
|
+
return template.endsWith("/") ? `${path}/` : path;
|
|
70887
68339
|
}
|
|
70888
|
-
function buildS3PathSuffix(
|
|
70889
|
-
const parts = renderTemplate(
|
|
68340
|
+
function buildS3PathSuffix(template, params) {
|
|
68341
|
+
const parts = renderTemplate(template, params);
|
|
70890
68342
|
const node = walkGrammar(S3_PATH_GRAMMAR, parts);
|
|
70891
|
-
if (
|
|
70892
|
-
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(
|
|
68343
|
+
if (template.endsWith("/") && node === PATH_LEAF) {
|
|
68344
|
+
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(template)}`);
|
|
70893
68345
|
}
|
|
70894
68346
|
const path = parts.join("/");
|
|
70895
|
-
return
|
|
68347
|
+
return template.endsWith("/") ? `${path}/` : path;
|
|
70896
68348
|
}
|
|
70897
68349
|
function stripTenantPrefix(key) {
|
|
70898
68350
|
return key.replace(TENANT_PREFIX_RX, "");
|
|
70899
68351
|
}
|
|
70900
|
-
function matchS3Path(
|
|
68352
|
+
function matchS3Path(template, key) {
|
|
70901
68353
|
const keyParts = stripTenantPrefix(key).split("/");
|
|
70902
|
-
const templateParts = normalizeTemplate(
|
|
68354
|
+
const templateParts = normalizeTemplate(template).split("/");
|
|
70903
68355
|
const params = {};
|
|
70904
68356
|
let keyIndex = 0;
|
|
70905
68357
|
for (let templateIndex = 0;templateIndex < templateParts.length; templateIndex += 1) {
|
|
@@ -70918,7 +68370,7 @@ function matchS3Path(template2, key) {
|
|
|
70918
68370
|
if (rest.length === 0)
|
|
70919
68371
|
return null;
|
|
70920
68372
|
try {
|
|
70921
|
-
params.path = rest.map((
|
|
68373
|
+
params.path = rest.map((segment) => assertSegment("path", segment)).join("/");
|
|
70922
68374
|
walkGrammar(S3_PATH_GRAMMAR, keyParts);
|
|
70923
68375
|
} catch {
|
|
70924
68376
|
return null;
|
|
@@ -70952,23 +68404,23 @@ function createBuilder(grammarNode, prefixSegments, boundTenantId) {
|
|
|
70952
68404
|
}
|
|
70953
68405
|
return assertSegment("tenantId", tenantId);
|
|
70954
68406
|
};
|
|
70955
|
-
const build = (
|
|
68407
|
+
const build = (template, params) => {
|
|
70956
68408
|
const tenant = resolveTenantId(params);
|
|
70957
|
-
const parts = renderTemplate(
|
|
68409
|
+
const parts = renderTemplate(template, params ?? {});
|
|
70958
68410
|
const node = walkGrammar(grammarNode, parts);
|
|
70959
|
-
if (
|
|
70960
|
-
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(
|
|
68411
|
+
if (template.endsWith("/") && node === PATH_LEAF) {
|
|
68412
|
+
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(template)}`);
|
|
70961
68413
|
}
|
|
70962
68414
|
const path = ["tenants", tenant, ...prefixSegments, ...parts].join("/");
|
|
70963
|
-
return
|
|
68415
|
+
return template.endsWith("/") ? `${path}/` : path;
|
|
70964
68416
|
};
|
|
70965
68417
|
const builder = build;
|
|
70966
|
-
builder.at = (
|
|
68418
|
+
builder.at = (template, params) => {
|
|
70967
68419
|
const tenant = resolveTenantId(params);
|
|
70968
|
-
const parts = renderTemplate(
|
|
68420
|
+
const parts = renderTemplate(template, params ?? {});
|
|
70969
68421
|
const nextNode = walkGrammar(grammarNode, parts);
|
|
70970
|
-
if (
|
|
70971
|
-
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(
|
|
68422
|
+
if (template.endsWith("/") && nextNode === PATH_LEAF) {
|
|
68423
|
+
throw new Error(`S3 path leaf cannot have a trailing slash: ${JSON.stringify(template)}`);
|
|
70972
68424
|
}
|
|
70973
68425
|
return createBuilder(nextNode, [...prefixSegments, ...parts], tenant);
|
|
70974
68426
|
};
|
|
@@ -71425,7 +68877,7 @@ __export(exports_src, {
|
|
|
71425
68877
|
SplitConfigSchema: () => SplitConfigSchema,
|
|
71426
68878
|
SpanTypes: () => SpanTypes,
|
|
71427
68879
|
SpanKindMap: () => SpanKindMap,
|
|
71428
|
-
SpanKind: () =>
|
|
68880
|
+
SpanKind: () => SpanKind,
|
|
71429
68881
|
SourceVersionRefSchema: () => SourceVersionRefSchema,
|
|
71430
68882
|
SourceSecretsFileSchema: () => SourceSecretsFileSchema,
|
|
71431
68883
|
SourcePackageTypeSchema: () => SourcePackageTypeSchema,
|
|
@@ -71640,7 +69092,7 @@ __export(exports_src, {
|
|
|
71640
69092
|
GPFS_FILE_SOURCE_DESCRIPTOR: () => GPFS_FILE_SOURCE_DESCRIPTOR,
|
|
71641
69093
|
ForeachStepSchema: () => ForeachStepSchema,
|
|
71642
69094
|
FileReferenceSentinelSchema: () => FileReferenceSentinelSchema,
|
|
71643
|
-
FilePathDescriptorSchema: () =>
|
|
69095
|
+
FilePathDescriptorSchema: () => FilePathDescriptorSchema2,
|
|
71644
69096
|
FileIngressRefSchema: () => FileIngressRefSchema,
|
|
71645
69097
|
FileIdIngressRefSchema: () => FileIdIngressRefSchema,
|
|
71646
69098
|
FailStepSchema: () => FailStepSchema,
|
|
@@ -71807,8 +69259,8 @@ var init_src = __esm(() => {
|
|
|
71807
69259
|
init_legacy_boundary();
|
|
71808
69260
|
init_runtime_file_ref();
|
|
71809
69261
|
init_scoped_file_ref();
|
|
71810
|
-
|
|
71811
|
-
|
|
69262
|
+
init_processor();
|
|
69263
|
+
init_parser();
|
|
71812
69264
|
init_otel();
|
|
71813
69265
|
init_execution_row();
|
|
71814
69266
|
init_run_expand();
|
|
@@ -72723,7 +70175,7 @@ var require_foldFlowLines = __commonJS((exports) => {
|
|
|
72723
70175
|
else
|
|
72724
70176
|
end = lineWidth - indentAtStart;
|
|
72725
70177
|
}
|
|
72726
|
-
let
|
|
70178
|
+
let split2 = undefined;
|
|
72727
70179
|
let prev = undefined;
|
|
72728
70180
|
let overflow = false;
|
|
72729
70181
|
let i = -1;
|
|
@@ -72757,20 +70209,20 @@ var require_foldFlowLines = __commonJS((exports) => {
|
|
|
72757
70209
|
if (mode === FOLD_BLOCK)
|
|
72758
70210
|
i = consumeMoreIndentedLines(text, i, indent.length);
|
|
72759
70211
|
end = i + indent.length + endStep;
|
|
72760
|
-
|
|
70212
|
+
split2 = undefined;
|
|
72761
70213
|
} else {
|
|
72762
70214
|
if (ch === " " && prev && prev !== " " && prev !== `
|
|
72763
70215
|
` && prev !== "\t") {
|
|
72764
70216
|
const next = text[i + 1];
|
|
72765
70217
|
if (next && next !== " " && next !== `
|
|
72766
70218
|
` && next !== "\t")
|
|
72767
|
-
|
|
70219
|
+
split2 = i;
|
|
72768
70220
|
}
|
|
72769
70221
|
if (i >= end) {
|
|
72770
|
-
if (
|
|
72771
|
-
folds.push(
|
|
72772
|
-
end =
|
|
72773
|
-
|
|
70222
|
+
if (split2) {
|
|
70223
|
+
folds.push(split2);
|
|
70224
|
+
end = split2 + endStep;
|
|
70225
|
+
split2 = undefined;
|
|
72774
70226
|
} else if (mode === FOLD_QUOTED) {
|
|
72775
70227
|
while (prev === " " || prev === "\t") {
|
|
72776
70228
|
prev = ch;
|
|
@@ -72783,7 +70235,7 @@ var require_foldFlowLines = __commonJS((exports) => {
|
|
|
72783
70235
|
folds.push(j);
|
|
72784
70236
|
escapedFolds[j] = true;
|
|
72785
70237
|
end = j + endStep;
|
|
72786
|
-
|
|
70238
|
+
split2 = undefined;
|
|
72787
70239
|
} else {
|
|
72788
70240
|
overflow = true;
|
|
72789
70241
|
}
|
|
@@ -73417,7 +70869,7 @@ var require_merge = __commonJS((exports) => {
|
|
|
73417
70869
|
var identity = require_identity();
|
|
73418
70870
|
var Scalar = require_Scalar();
|
|
73419
70871
|
var MERGE_KEY = "<<";
|
|
73420
|
-
var
|
|
70872
|
+
var merge2 = {
|
|
73421
70873
|
identify: (value) => value === MERGE_KEY || typeof value === "symbol" && value.description === MERGE_KEY,
|
|
73422
70874
|
default: "key",
|
|
73423
70875
|
tag: "tag:yaml.org,2002:merge",
|
|
@@ -73427,7 +70879,7 @@ var require_merge = __commonJS((exports) => {
|
|
|
73427
70879
|
}),
|
|
73428
70880
|
stringify: () => MERGE_KEY
|
|
73429
70881
|
};
|
|
73430
|
-
var isMergeKey = (ctx, key) => (
|
|
70882
|
+
var isMergeKey = (ctx, key) => (merge2.identify(key) || identity.isScalar(key) && (!key.type || key.type === Scalar.Scalar.PLAIN) && merge2.identify(key.value)) && ctx?.doc.schema.tags.some((tag) => tag.tag === merge2.tag && tag.default);
|
|
73431
70883
|
function addMergeToJSMap(ctx, map2, value) {
|
|
73432
70884
|
const source = resolveAliasValue(ctx, value);
|
|
73433
70885
|
if (identity.isSeq(source))
|
|
@@ -73466,21 +70918,21 @@ var require_merge = __commonJS((exports) => {
|
|
|
73466
70918
|
}
|
|
73467
70919
|
exports.addMergeToJSMap = addMergeToJSMap;
|
|
73468
70920
|
exports.isMergeKey = isMergeKey;
|
|
73469
|
-
exports.merge =
|
|
70921
|
+
exports.merge = merge2;
|
|
73470
70922
|
});
|
|
73471
70923
|
|
|
73472
70924
|
// ../../node_modules/yaml/dist/nodes/addPairToJSMap.js
|
|
73473
70925
|
var require_addPairToJSMap = __commonJS((exports) => {
|
|
73474
70926
|
var log = require_log();
|
|
73475
|
-
var
|
|
70927
|
+
var merge2 = require_merge();
|
|
73476
70928
|
var stringify = require_stringify();
|
|
73477
70929
|
var identity = require_identity();
|
|
73478
70930
|
var toJS = require_toJS();
|
|
73479
70931
|
function addPairToJSMap(ctx, map2, { key, value }) {
|
|
73480
70932
|
if (identity.isNode(key) && key.addToJSMap)
|
|
73481
70933
|
key.addToJSMap(ctx, map2, value);
|
|
73482
|
-
else if (
|
|
73483
|
-
|
|
70934
|
+
else if (merge2.isMergeKey(ctx, key))
|
|
70935
|
+
merge2.addMergeToJSMap(ctx, map2, value);
|
|
73484
70936
|
else {
|
|
73485
70937
|
const jsKey = toJS.toJS(key, "", ctx);
|
|
73486
70938
|
if (map2 instanceof Map) {
|
|
@@ -74756,7 +72208,7 @@ var require_schema3 = __commonJS((exports) => {
|
|
|
74756
72208
|
var bool = require_bool2();
|
|
74757
72209
|
var float = require_float2();
|
|
74758
72210
|
var int2 = require_int2();
|
|
74759
|
-
var
|
|
72211
|
+
var merge2 = require_merge();
|
|
74760
72212
|
var omap = require_omap();
|
|
74761
72213
|
var pairs = require_pairs();
|
|
74762
72214
|
var set2 = require_set();
|
|
@@ -74776,7 +72228,7 @@ var require_schema3 = __commonJS((exports) => {
|
|
|
74776
72228
|
float.floatExp,
|
|
74777
72229
|
float.float,
|
|
74778
72230
|
binary.binary,
|
|
74779
|
-
|
|
72231
|
+
merge2.merge,
|
|
74780
72232
|
omap.omap,
|
|
74781
72233
|
pairs.pairs,
|
|
74782
72234
|
set2.set,
|
|
@@ -74799,7 +72251,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
74799
72251
|
var schema = require_schema();
|
|
74800
72252
|
var schema$1 = require_schema2();
|
|
74801
72253
|
var binary = require_binary();
|
|
74802
|
-
var
|
|
72254
|
+
var merge2 = require_merge();
|
|
74803
72255
|
var omap = require_omap();
|
|
74804
72256
|
var pairs = require_pairs();
|
|
74805
72257
|
var schema$2 = require_schema3();
|
|
@@ -74824,7 +72276,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
74824
72276
|
intOct: int2.intOct,
|
|
74825
72277
|
intTime: timestamp.intTime,
|
|
74826
72278
|
map: map2.map,
|
|
74827
|
-
merge:
|
|
72279
|
+
merge: merge2.merge,
|
|
74828
72280
|
null: _null4.nullTag,
|
|
74829
72281
|
omap: omap.omap,
|
|
74830
72282
|
pairs: pairs.pairs,
|
|
@@ -74834,7 +72286,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
74834
72286
|
};
|
|
74835
72287
|
var coreKnownTags = {
|
|
74836
72288
|
"tag:yaml.org,2002:binary": binary.binary,
|
|
74837
|
-
"tag:yaml.org,2002:merge":
|
|
72289
|
+
"tag:yaml.org,2002:merge": merge2.merge,
|
|
74838
72290
|
"tag:yaml.org,2002:omap": omap.omap,
|
|
74839
72291
|
"tag:yaml.org,2002:pairs": pairs.pairs,
|
|
74840
72292
|
"tag:yaml.org,2002:set": set2.set,
|
|
@@ -74843,7 +72295,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
74843
72295
|
function getTags(customTags, schemaName, addMergeTag) {
|
|
74844
72296
|
const schemaTags = schemas3.get(schemaName);
|
|
74845
72297
|
if (schemaTags && !customTags) {
|
|
74846
|
-
return addMergeTag && !schemaTags.includes(
|
|
72298
|
+
return addMergeTag && !schemaTags.includes(merge2.merge) ? schemaTags.concat(merge2.merge) : schemaTags.slice();
|
|
74847
72299
|
}
|
|
74848
72300
|
let tags = schemaTags;
|
|
74849
72301
|
if (!tags) {
|
|
@@ -74861,7 +72313,7 @@ var require_tags = __commonJS((exports) => {
|
|
|
74861
72313
|
tags = customTags(tags.slice());
|
|
74862
72314
|
}
|
|
74863
72315
|
if (addMergeTag)
|
|
74864
|
-
tags = tags.concat(
|
|
72316
|
+
tags = tags.concat(merge2.merge);
|
|
74865
72317
|
return tags.reduce((tags2, tag) => {
|
|
74866
72318
|
const tagObj = typeof tag === "string" ? tagsByName[tag] : tag;
|
|
74867
72319
|
if (!tagObj) {
|
|
@@ -74888,11 +72340,11 @@ var require_Schema = __commonJS((exports) => {
|
|
|
74888
72340
|
var sortMapEntriesByKey = (a, b) => a.key < b.key ? -1 : a.key > b.key ? 1 : 0;
|
|
74889
72341
|
|
|
74890
72342
|
class Schema {
|
|
74891
|
-
constructor({ compat: compat2, customTags, merge:
|
|
72343
|
+
constructor({ compat: compat2, customTags, merge: merge2, resolveKnownTags, schema, sortMapEntries, toStringDefaults }) {
|
|
74892
72344
|
this.compat = Array.isArray(compat2) ? tags.getTags(compat2, "compat") : compat2 ? tags.getTags(null, compat2) : null;
|
|
74893
72345
|
this.name = typeof schema === "string" && schema || "core";
|
|
74894
72346
|
this.knownTags = resolveKnownTags ? tags.coreKnownTags : {};
|
|
74895
|
-
this.tags = tags.getTags(customTags, this.name,
|
|
72347
|
+
this.tags = tags.getTags(customTags, this.name, merge2);
|
|
74896
72348
|
this.toStringOptions = toStringDefaults ?? null;
|
|
74897
72349
|
Object.defineProperty(this, identity.MAP, { value: map2.map });
|
|
74898
72350
|
Object.defineProperty(this, identity.SCALAR, { value: string4.string });
|
|
@@ -76115,13 +73567,13 @@ var require_resolve_block_scalar = __commonJS((exports) => {
|
|
|
76115
73567
|
return { mode, indent, chomp, comment, length };
|
|
76116
73568
|
}
|
|
76117
73569
|
function splitLines(source) {
|
|
76118
|
-
const
|
|
76119
|
-
const first =
|
|
73570
|
+
const split2 = source.split(/\n( *)/);
|
|
73571
|
+
const first = split2[0];
|
|
76120
73572
|
const m = first.match(/^( *)/);
|
|
76121
73573
|
const line0 = m?.[1] ? [m[1], first.slice(m[1].length)] : ["", first];
|
|
76122
73574
|
const lines = [line0];
|
|
76123
|
-
for (let i = 1;i <
|
|
76124
|
-
lines.push([
|
|
73575
|
+
for (let i = 1;i < split2.length; i += 2)
|
|
73576
|
+
lines.push([split2[i], split2[i + 1]]);
|
|
76125
73577
|
return lines;
|
|
76126
73578
|
}
|
|
76127
73579
|
exports.resolveBlockScalar = resolveBlockScalar;
|
|
@@ -79135,7 +76587,7 @@ var init_main = __esm(() => {
|
|
|
79135
76587
|
});
|
|
79136
76588
|
|
|
79137
76589
|
// ../../node_modules/sisteransi/src/index.js
|
|
79138
|
-
var
|
|
76590
|
+
var require_src = __commonJS((exports, module) => {
|
|
79139
76591
|
var ESC2 = "\x1B";
|
|
79140
76592
|
var CSI2 = `${ESC2}[`;
|
|
79141
76593
|
var beep = "\x07";
|
|
@@ -79478,7 +76930,7 @@ var import_sisteransi, G, K, h, Y, k, A = (r) => ("columns" in r) && typeof r.co
|
|
|
79478
76930
|
}, Q, X, Z, et, it, rt, nt, ot, ut, at, ht;
|
|
79479
76931
|
var init_dist3 = __esm(() => {
|
|
79480
76932
|
init_main();
|
|
79481
|
-
import_sisteransi = __toESM(
|
|
76933
|
+
import_sisteransi = __toESM(require_src(), 1);
|
|
79482
76934
|
G = ["up", "down", "left", "right", "space", "enter", "cancel"];
|
|
79483
76935
|
K = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
|
|
79484
76936
|
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)}` } } };
|
|
@@ -80821,7 +78273,7 @@ var init_dist4 = __esm(() => {
|
|
|
80821
78273
|
init_dist3();
|
|
80822
78274
|
init_main();
|
|
80823
78275
|
init_dist2();
|
|
80824
|
-
import_sisteransi2 = __toESM(
|
|
78276
|
+
import_sisteransi2 = __toESM(require_src(), 1);
|
|
80825
78277
|
tt2 = te();
|
|
80826
78278
|
_t = w2("◆", "*");
|
|
80827
78279
|
ot2 = w2("■", "x");
|
|
@@ -174313,7 +171765,7 @@ var require3, __filename2, __dirname2, __create2, __defProp3, __getOwnPropDesc,
|
|
|
174313
171765
|
__defProp3(to5, key2, { get: () => from[key2], enumerable: !(desc = __getOwnPropDesc(from, key2)) || desc.enumerable });
|
|
174314
171766
|
}
|
|
174315
171767
|
return to5;
|
|
174316
|
-
}, __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,
|
|
171768
|
+
}, __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_utils2, 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_utils3, require_tasks, require_async, require_sync, require_fs2, require_settings, require_out, require_queue_microtask, require_run_parallel, require_constants3, require_fs3, require_utils4, 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_semver, require_compare, require_gte, require_pseudomap, require_map2, require_yallist, require_lru_cache, require_sigmund, require_fnmatch, require_ini, require_package, require_src2, require_js_tokens, require_readlines, require_ignore, index_exports, Diff = class {
|
|
174317
171769
|
diff(oldStr, newStr, options8 = {}) {
|
|
174318
171770
|
let callback;
|
|
174319
171771
|
if (typeof options8 === "function") {
|
|
@@ -175335,7 +172787,7 @@ var init_prettier = __esm(() => {
|
|
|
175335
172787
|
};
|
|
175336
172788
|
}
|
|
175337
172789
|
});
|
|
175338
|
-
|
|
172790
|
+
require_utils2 = __commonJS2({
|
|
175339
172791
|
"node_modules/braces/lib/utils.js"(exports) {
|
|
175340
172792
|
exports.isInteger = (num) => {
|
|
175341
172793
|
if (typeof num === "number") {
|
|
@@ -175424,7 +172876,7 @@ var init_prettier = __esm(() => {
|
|
|
175424
172876
|
});
|
|
175425
172877
|
require_stringify2 = __commonJS2({
|
|
175426
172878
|
"node_modules/braces/lib/stringify.js"(exports, module) {
|
|
175427
|
-
var utils2 =
|
|
172879
|
+
var utils2 = require_utils2();
|
|
175428
172880
|
module.exports = (ast, options8 = {}) => {
|
|
175429
172881
|
const stringify2 = (node, parent = {}) => {
|
|
175430
172882
|
const invalidBlock = options8.escapeInvalid && utils2.isInvalidBrace(parent);
|
|
@@ -175878,7 +173330,7 @@ var init_prettier = __esm(() => {
|
|
|
175878
173330
|
require_compile2 = __commonJS2({
|
|
175879
173331
|
"node_modules/braces/lib/compile.js"(exports, module) {
|
|
175880
173332
|
var fill2 = require_fill_range();
|
|
175881
|
-
var utils2 =
|
|
173333
|
+
var utils2 = require_utils2();
|
|
175882
173334
|
var compile = (ast, options8 = {}) => {
|
|
175883
173335
|
const walk = (node, parent = {}) => {
|
|
175884
173336
|
const invalidBlock = utils2.isInvalidBrace(parent);
|
|
@@ -175928,7 +173380,7 @@ var init_prettier = __esm(() => {
|
|
|
175928
173380
|
"node_modules/braces/lib/expand.js"(exports, module) {
|
|
175929
173381
|
var fill2 = require_fill_range();
|
|
175930
173382
|
var stringify2 = require_stringify2();
|
|
175931
|
-
var utils2 =
|
|
173383
|
+
var utils2 = require_utils2();
|
|
175932
173384
|
var append = (queue = "", stash = "", enclose = false) => {
|
|
175933
173385
|
const result = [];
|
|
175934
173386
|
queue = [].concat(queue);
|
|
@@ -178127,8 +175579,8 @@ var init_prettier = __esm(() => {
|
|
|
178127
175579
|
var Stream = __require2("stream");
|
|
178128
175580
|
var PassThrough = Stream.PassThrough;
|
|
178129
175581
|
var slice = Array.prototype.slice;
|
|
178130
|
-
module.exports =
|
|
178131
|
-
function
|
|
175582
|
+
module.exports = merge2;
|
|
175583
|
+
function merge2() {
|
|
178132
175584
|
const streamsQueue = [];
|
|
178133
175585
|
const args = slice.call(arguments);
|
|
178134
175586
|
let merging = false;
|
|
@@ -178242,9 +175694,9 @@ var init_prettier = __esm(() => {
|
|
|
178242
175694
|
"node_modules/fast-glob/out/utils/stream.js"(exports) {
|
|
178243
175695
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
178244
175696
|
exports.merge = undefined;
|
|
178245
|
-
var
|
|
175697
|
+
var merge2 = require_merge2();
|
|
178246
175698
|
function merge3(streams) {
|
|
178247
|
-
const mergedStream =
|
|
175699
|
+
const mergedStream = merge2(streams);
|
|
178248
175700
|
streams.forEach((stream) => {
|
|
178249
175701
|
stream.once("error", (error52) => mergedStream.emit("error", error52));
|
|
178250
175702
|
});
|
|
@@ -178272,7 +175724,7 @@ var init_prettier = __esm(() => {
|
|
|
178272
175724
|
exports.isEmpty = isEmpty;
|
|
178273
175725
|
}
|
|
178274
175726
|
});
|
|
178275
|
-
|
|
175727
|
+
require_utils3 = __commonJS2({
|
|
178276
175728
|
"node_modules/fast-glob/out/utils/index.js"(exports) {
|
|
178277
175729
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
178278
175730
|
exports.string = exports.stream = exports.pattern = exports.path = exports.fs = exports.errno = exports.array = undefined;
|
|
@@ -178296,7 +175748,7 @@ var init_prettier = __esm(() => {
|
|
|
178296
175748
|
"node_modules/fast-glob/out/managers/tasks.js"(exports) {
|
|
178297
175749
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
178298
175750
|
exports.convertPatternGroupToTask = exports.convertPatternGroupsToTasks = exports.groupPatternsByBaseDirectory = exports.getNegativePatternsAsPositive = exports.getPositivePatterns = exports.convertPatternsToTasks = exports.generate = undefined;
|
|
178299
|
-
var utils2 =
|
|
175751
|
+
var utils2 = require_utils3();
|
|
178300
175752
|
function generate(input, settings) {
|
|
178301
175753
|
const patterns = processPatterns(input, settings);
|
|
178302
175754
|
const ignore = processPatterns(settings.ignore, settings);
|
|
@@ -178605,7 +176057,7 @@ var init_prettier = __esm(() => {
|
|
|
178605
176057
|
exports.createDirentFromStats = createDirentFromStats;
|
|
178606
176058
|
}
|
|
178607
176059
|
});
|
|
178608
|
-
|
|
176060
|
+
require_utils4 = __commonJS2({
|
|
178609
176061
|
"node_modules/@nodelib/fs.scandir/out/utils/index.js"(exports) {
|
|
178610
176062
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
178611
176063
|
exports.fs = undefined;
|
|
@@ -178633,7 +176085,7 @@ var init_prettier = __esm(() => {
|
|
|
178633
176085
|
var fsStat = require_out();
|
|
178634
176086
|
var rpl = require_run_parallel();
|
|
178635
176087
|
var constants_1 = require_constants3();
|
|
178636
|
-
var utils2 =
|
|
176088
|
+
var utils2 = require_utils4();
|
|
178637
176089
|
var common = require_common();
|
|
178638
176090
|
function read3(directory, settings, callback) {
|
|
178639
176091
|
if (!settings.stats && constants_1.IS_SUPPORT_READDIR_WITH_FILE_TYPES) {
|
|
@@ -178739,7 +176191,7 @@ var init_prettier = __esm(() => {
|
|
|
178739
176191
|
exports.readdir = exports.readdirWithFileTypes = exports.read = undefined;
|
|
178740
176192
|
var fsStat = require_out();
|
|
178741
176193
|
var constants_1 = require_constants3();
|
|
178742
|
-
var utils2 =
|
|
176194
|
+
var utils2 = require_utils4();
|
|
178743
176195
|
var common = require_common();
|
|
178744
176196
|
function read3(directory, settings) {
|
|
178745
176197
|
if (!settings.stats && constants_1.IS_SUPPORT_READDIR_WITH_FILE_TYPES) {
|
|
@@ -179519,7 +176971,7 @@ var init_prettier = __esm(() => {
|
|
|
179519
176971
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
179520
176972
|
var path15 = __require2("path");
|
|
179521
176973
|
var fsStat = require_out();
|
|
179522
|
-
var utils2 =
|
|
176974
|
+
var utils2 = require_utils3();
|
|
179523
176975
|
var Reader = class {
|
|
179524
176976
|
constructor(_settings) {
|
|
179525
176977
|
this._settings = _settings;
|
|
@@ -179643,7 +177095,7 @@ var init_prettier = __esm(() => {
|
|
|
179643
177095
|
require_matcher = __commonJS2({
|
|
179644
177096
|
"node_modules/fast-glob/out/providers/matchers/matcher.js"(exports) {
|
|
179645
177097
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
179646
|
-
var utils2 =
|
|
177098
|
+
var utils2 = require_utils3();
|
|
179647
177099
|
var Matcher = class {
|
|
179648
177100
|
constructor(_patterns, _settings, _micromatchOptions) {
|
|
179649
177101
|
this._patterns = _patterns;
|
|
@@ -179682,7 +177134,7 @@ var init_prettier = __esm(() => {
|
|
|
179682
177134
|
});
|
|
179683
177135
|
}
|
|
179684
177136
|
_splitSegmentsIntoSections(segments) {
|
|
179685
|
-
return utils2.array.splitWhen(segments, (
|
|
177137
|
+
return utils2.array.splitWhen(segments, (segment) => segment.dynamic && utils2.pattern.hasGlobStar(segment.pattern));
|
|
179686
177138
|
}
|
|
179687
177139
|
};
|
|
179688
177140
|
exports.default = Matcher;
|
|
@@ -179703,11 +177155,11 @@ var init_prettier = __esm(() => {
|
|
|
179703
177155
|
return true;
|
|
179704
177156
|
}
|
|
179705
177157
|
const match = parts.every((part, index) => {
|
|
179706
|
-
const
|
|
179707
|
-
if (
|
|
177158
|
+
const segment = pattern.segments[index];
|
|
177159
|
+
if (segment.dynamic && segment.patternRe.test(part)) {
|
|
179708
177160
|
return true;
|
|
179709
177161
|
}
|
|
179710
|
-
if (!
|
|
177162
|
+
if (!segment.dynamic && segment.pattern === part) {
|
|
179711
177163
|
return true;
|
|
179712
177164
|
}
|
|
179713
177165
|
return false;
|
|
@@ -179725,7 +177177,7 @@ var init_prettier = __esm(() => {
|
|
|
179725
177177
|
require_deep = __commonJS2({
|
|
179726
177178
|
"node_modules/fast-glob/out/providers/filters/deep.js"(exports) {
|
|
179727
177179
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
179728
|
-
var utils2 =
|
|
177180
|
+
var utils2 = require_utils3();
|
|
179729
177181
|
var partial_1 = require_partial();
|
|
179730
177182
|
var DeepFilter = class {
|
|
179731
177183
|
constructor(_settings, _micromatchOptions) {
|
|
@@ -179787,7 +177239,7 @@ var init_prettier = __esm(() => {
|
|
|
179787
177239
|
require_entry = __commonJS2({
|
|
179788
177240
|
"node_modules/fast-glob/out/providers/filters/entry.js"(exports) {
|
|
179789
177241
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
179790
|
-
var utils2 =
|
|
177242
|
+
var utils2 = require_utils3();
|
|
179791
177243
|
var EntryFilter = class {
|
|
179792
177244
|
constructor(_settings, _micromatchOptions) {
|
|
179793
177245
|
this._settings = _settings;
|
|
@@ -179872,7 +177324,7 @@ var init_prettier = __esm(() => {
|
|
|
179872
177324
|
require_error2 = __commonJS2({
|
|
179873
177325
|
"node_modules/fast-glob/out/providers/filters/error.js"(exports) {
|
|
179874
177326
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
179875
|
-
var utils2 =
|
|
177327
|
+
var utils2 = require_utils3();
|
|
179876
177328
|
var ErrorFilter = class {
|
|
179877
177329
|
constructor(_settings) {
|
|
179878
177330
|
this._settings = _settings;
|
|
@@ -179890,7 +177342,7 @@ var init_prettier = __esm(() => {
|
|
|
179890
177342
|
require_entry2 = __commonJS2({
|
|
179891
177343
|
"node_modules/fast-glob/out/providers/transformers/entry.js"(exports) {
|
|
179892
177344
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
179893
|
-
var utils2 =
|
|
177345
|
+
var utils2 = require_utils3();
|
|
179894
177346
|
var EntryTransformer = class {
|
|
179895
177347
|
constructor(_settings) {
|
|
179896
177348
|
this._settings = _settings;
|
|
@@ -180158,7 +177610,7 @@ var init_prettier = __esm(() => {
|
|
|
180158
177610
|
var stream_1 = require_stream4();
|
|
180159
177611
|
var sync_1 = require_sync6();
|
|
180160
177612
|
var settings_1 = require_settings4();
|
|
180161
|
-
var utils2 =
|
|
177613
|
+
var utils2 = require_utils3();
|
|
180162
177614
|
async function FastGlob(source2, options8) {
|
|
180163
177615
|
assertPatternsInput(source2);
|
|
180164
177616
|
const works = getWorks(source2, async_1.default, options8);
|
|
@@ -180476,7 +177928,7 @@ var init_prettier = __esm(() => {
|
|
|
180476
177928
|
};
|
|
180477
177929
|
}
|
|
180478
177930
|
});
|
|
180479
|
-
|
|
177931
|
+
require_semver = __commonJS2({
|
|
180480
177932
|
"node_modules/semver/classes/semver.js"(exports, module) {
|
|
180481
177933
|
var debug = require_debug();
|
|
180482
177934
|
var { MAX_LENGTH, MAX_SAFE_INTEGER } = require_constants4();
|
|
@@ -180746,7 +178198,7 @@ var init_prettier = __esm(() => {
|
|
|
180746
178198
|
});
|
|
180747
178199
|
require_compare = __commonJS2({
|
|
180748
178200
|
"node_modules/semver/functions/compare.js"(exports, module) {
|
|
180749
|
-
var SemVer =
|
|
178201
|
+
var SemVer = require_semver();
|
|
180750
178202
|
var compare = (a5, b8, loose) => new SemVer(a5, loose).compare(new SemVer(b8, loose));
|
|
180751
178203
|
module.exports = compare;
|
|
180752
178204
|
}
|
|
@@ -182479,7 +179931,7 @@ globstar while`, file2, fr10, pattern, pr8, swallowee);
|
|
|
182479
179931
|
};
|
|
182480
179932
|
}
|
|
182481
179933
|
});
|
|
182482
|
-
|
|
179934
|
+
require_src2 = __commonJS2({
|
|
182483
179935
|
"node_modules/editorconfig/src/index.js"(exports) {
|
|
182484
179936
|
var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P9, generator) {
|
|
182485
179937
|
return new (P9 || (P9 = Promise))(function(resolve3, reject) {
|
|
@@ -183942,7 +181394,7 @@ globstar while`, file2, fr10, pattern, pr8, swallowee);
|
|
|
183942
181394
|
mockable_default = mockable.mocked;
|
|
183943
181395
|
import_micromatch = __toESM2(require_micromatch(), 1);
|
|
183944
181396
|
partition_default = partition2;
|
|
183945
|
-
import_editorconfig = __toESM2(
|
|
181397
|
+
import_editorconfig = __toESM2(require_src2(), 1);
|
|
183946
181398
|
iterate_directory_up_default = iterateDirectoryUp;
|
|
183947
181399
|
FileSearcher = class extends Searcher {
|
|
183948
181400
|
findInDirectory = findFile;
|
|
@@ -186538,7 +183990,7 @@ import { fileURLToPath as fileURLToPath9 } from "url";
|
|
|
186538
183990
|
// package.json
|
|
186539
183991
|
var package_default = {
|
|
186540
183992
|
name: "@eigenpal/cli",
|
|
186541
|
-
version: "0.10.
|
|
183993
|
+
version: "0.10.40",
|
|
186542
183994
|
description: "Eigenpal CLI — author and run document workflows from your terminal. Agent-ready.",
|
|
186543
183995
|
keywords: [
|
|
186544
183996
|
"eigenpal",
|
|
@@ -188053,7 +185505,7 @@ async function pushCurrentBranch(input) {
|
|
|
188053
185505
|
function slugifyPackageSegment(value) {
|
|
188054
185506
|
return value.trim().toLowerCase().replace(/[^a-z0-9_-]+/g, "-").replace(/^-+|-+$/g, "");
|
|
188055
185507
|
}
|
|
188056
|
-
function packagePathForTemplate(
|
|
185508
|
+
function packagePathForTemplate(template, name) {
|
|
188057
185509
|
const slug = slugifyPackageSegment(name);
|
|
188058
185510
|
if (!slug)
|
|
188059
185511
|
throw new Error("Package name must include at least one letter or number.");
|
|
@@ -188065,7 +185517,7 @@ function packagePathForTemplate(template2, name) {
|
|
|
188065
185517
|
knowledge: "resources/knowledge",
|
|
188066
185518
|
evaluator: "evaluators"
|
|
188067
185519
|
};
|
|
188068
|
-
const root = rootByTemplate[
|
|
185520
|
+
const root = rootByTemplate[template];
|
|
188069
185521
|
if (!root)
|
|
188070
185522
|
throw new Error("Template must be agent, workflow, skill, rule, knowledge, or evaluator.");
|
|
188071
185523
|
return SourcePackagePathSchema.parse(`${root}/${slug}`);
|
|
@@ -188496,12 +185948,12 @@ function archivePackage(input) {
|
|
|
188496
185948
|
runGit(["archive", "--format=tar", `--output=${tarPath}`, input.ref, input.packagePath], {
|
|
188497
185949
|
cwd: input.gitRoot
|
|
188498
185950
|
});
|
|
188499
|
-
const
|
|
185951
|
+
const extract = spawnSync3("tar", ["-xf", tarPath, "--strip-components", String(input.packagePath.split("/").length)], {
|
|
188500
185952
|
cwd: input.outDir,
|
|
188501
185953
|
encoding: "utf8"
|
|
188502
185954
|
});
|
|
188503
|
-
if (
|
|
188504
|
-
throw new Error(
|
|
185955
|
+
if (extract.status !== 0)
|
|
185956
|
+
throw new Error(extract.stderr.trim() || "tar extraction failed");
|
|
188505
185957
|
} finally {
|
|
188506
185958
|
rmSync(path5.dirname(tarPath), { recursive: true, force: true });
|
|
188507
185959
|
}
|
|
@@ -188530,12 +185982,12 @@ async function tryHostedArchive(input) {
|
|
|
188530
185982
|
const tarPath = path5.join(mkdtempSyncCompat("eigenpal-hosted-source-"), "package.tar");
|
|
188531
185983
|
try {
|
|
188532
185984
|
writeFileSync4(tarPath, Buffer.from(await response.arrayBuffer()));
|
|
188533
|
-
const
|
|
185985
|
+
const extract = spawnSync3("tar", ["-xf", tarPath, "--strip-components", String(input.packagePath.split("/").length)], {
|
|
188534
185986
|
cwd: input.outDir,
|
|
188535
185987
|
encoding: "utf8"
|
|
188536
185988
|
});
|
|
188537
|
-
if (
|
|
188538
|
-
throw new Error(
|
|
185989
|
+
if (extract.status !== 0)
|
|
185990
|
+
throw new Error(extract.stderr.trim() || "tar extraction failed");
|
|
188539
185991
|
return true;
|
|
188540
185992
|
} finally {
|
|
188541
185993
|
rmSync(path5.dirname(tarPath), { recursive: true, force: true });
|
|
@@ -193516,18 +190968,18 @@ async function init(name, opts) {
|
|
|
193516
190968
|
if (existsSync13(target) && readdirSync4(target).length > 0) {
|
|
193517
190969
|
throw new Error(`Target directory ${relative2(process.cwd(), target)} exists and is not empty.`);
|
|
193518
190970
|
}
|
|
193519
|
-
let
|
|
190971
|
+
let template;
|
|
193520
190972
|
if (opts.template) {
|
|
193521
190973
|
if (!isTemplateName(opts.template)) {
|
|
193522
190974
|
throw new Error(`Unknown template "${opts.template}". Available: ${TEMPLATE_NAMES.join(", ")}.`);
|
|
193523
190975
|
}
|
|
193524
|
-
|
|
190976
|
+
template = opts.template;
|
|
193525
190977
|
} else if (opts.yes || !process.stdin.isTTY) {
|
|
193526
|
-
|
|
190978
|
+
template = "blank";
|
|
193527
190979
|
} else {
|
|
193528
|
-
|
|
190980
|
+
template = await promptForTemplate();
|
|
193529
190981
|
}
|
|
193530
|
-
const sourceRoot = join7(resolveTemplatesRoot(),
|
|
190982
|
+
const sourceRoot = join7(resolveTemplatesRoot(), template);
|
|
193531
190983
|
if (!existsSync13(sourceRoot)) {
|
|
193532
190984
|
throw new Error(`Template directory missing on disk: ${sourceRoot}`);
|
|
193533
190985
|
}
|