@eigenpal/cli 0.10.0 → 0.10.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/dist/cli.js +204 -20
- package/dist/skill/reference/workflow-yaml.md +3 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @eigenpal/cli
|
|
2
2
|
|
|
3
|
+
## 0.10.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- ca9ae4f: Workflow inputs can declare an external file `source` (single-tenant on-prem). A `type: file` input with `source: <name>` (e.g. `gpfs`) is provided as a plain string id at run time; the worker resolves it to a file artifact via the configured source before the workflow executes.
|
|
8
|
+
|
|
3
9
|
## 0.9.0
|
|
4
10
|
|
|
5
11
|
### Minor Changes
|
package/dist/cli.js
CHANGED
|
@@ -17158,6 +17158,7 @@ var init_common = __esm(() => {
|
|
|
17158
17158
|
AGENT_EMAIL_ALIAS: "aea",
|
|
17159
17159
|
AGENT_EMAIL_INVOCATION: "aei",
|
|
17160
17160
|
AUTOMATION_TRIGGER: "atr",
|
|
17161
|
+
FILE_SOURCE_CONFIG: "fsc",
|
|
17161
17162
|
SANDBOX_WS_TOKEN: "sws"
|
|
17162
17163
|
};
|
|
17163
17164
|
TimestampSchema = exports_external.union([exports_external.date(), exports_external.string().datetime()]).transform((val) => {
|
|
@@ -18867,6 +18868,13 @@ function resolveEffectiveMimeType(filename, declaredMimeType) {
|
|
|
18867
18868
|
const extensionMime = EXTENSION_TO_MIME[ext];
|
|
18868
18869
|
return extensionMime ?? declaredMimeType;
|
|
18869
18870
|
}
|
|
18871
|
+
function mimeTypeForExtension(extension) {
|
|
18872
|
+
return EXTENSION_TO_MIME[extension.replace(/^\./, "").toLowerCase()];
|
|
18873
|
+
}
|
|
18874
|
+
function extensionForMimeType(mimeType) {
|
|
18875
|
+
const base = mimeType.split(";")[0]?.trim().toLowerCase();
|
|
18876
|
+
return base ? MIME_TO_EXTENSION[base] : undefined;
|
|
18877
|
+
}
|
|
18870
18878
|
function getParserCategory(mimeType) {
|
|
18871
18879
|
const normalized = mimeType.toLowerCase().trim();
|
|
18872
18880
|
if (ParserCategory.PLAINTEXT.includes(normalized)) {
|
|
@@ -18891,7 +18899,7 @@ function getSupportedFormatsLabel() {
|
|
|
18891
18899
|
const labels = [...new Set(allMimes.map((m) => MIME_TO_LABEL[m] ?? m))];
|
|
18892
18900
|
return labels.join(", ");
|
|
18893
18901
|
}
|
|
18894
|
-
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_LABEL;
|
|
18902
|
+
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;
|
|
18895
18903
|
var init_parser = __esm(() => {
|
|
18896
18904
|
init_zod();
|
|
18897
18905
|
OFFICE_MIME_TYPES = [
|
|
@@ -19103,6 +19111,11 @@ var init_parser = __esm(() => {
|
|
|
19103
19111
|
docbook: "application/docbook+xml",
|
|
19104
19112
|
fb2: "application/x-fictionbook+xml"
|
|
19105
19113
|
};
|
|
19114
|
+
MIME_TO_EXTENSION = Object.entries(EXTENSION_TO_MIME).reduce((acc, [ext, mime]) => {
|
|
19115
|
+
if (!(mime in acc))
|
|
19116
|
+
acc[mime] = ext;
|
|
19117
|
+
return acc;
|
|
19118
|
+
}, {});
|
|
19106
19119
|
MIME_TO_LABEL = {
|
|
19107
19120
|
"application/vnd.openxmlformats-officedocument.wordprocessingml.document": "DOCX",
|
|
19108
19121
|
"application/msword": "DOC",
|
|
@@ -26346,6 +26359,9 @@ var init_ajv = __esm(() => {
|
|
|
26346
26359
|
});
|
|
26347
26360
|
|
|
26348
26361
|
// ../types/src/validation/input.ts
|
|
26362
|
+
function inputsWithSource(inputs) {
|
|
26363
|
+
return (inputs ?? []).filter((i) => Boolean(i.source));
|
|
26364
|
+
}
|
|
26349
26365
|
function workflowInputsToJsonSchema(inputs) {
|
|
26350
26366
|
const properties = {};
|
|
26351
26367
|
const required2 = [];
|
|
@@ -26363,6 +26379,9 @@ function workflowInputsToJsonSchema(inputs) {
|
|
|
26363
26379
|
return schema;
|
|
26364
26380
|
}
|
|
26365
26381
|
function workflowInputTypeToJsonSchema(def) {
|
|
26382
|
+
if (def.source && def.type === "file") {
|
|
26383
|
+
return { type: "string", minLength: 1 };
|
|
26384
|
+
}
|
|
26366
26385
|
switch (def.type) {
|
|
26367
26386
|
case "string":
|
|
26368
26387
|
return { type: "string" };
|
|
@@ -65008,7 +65027,47 @@ var init_workflow = __esm(() => {
|
|
|
65008
65027
|
items: exports_external.object({
|
|
65009
65028
|
type: exports_external.string(),
|
|
65010
65029
|
values: exports_external.array(exports_external.string()).optional()
|
|
65011
|
-
}).optional()
|
|
65030
|
+
}).optional(),
|
|
65031
|
+
source: exports_external.string().min(1).optional(),
|
|
65032
|
+
mimeType: exports_external.string().min(1).optional(),
|
|
65033
|
+
extension: exports_external.string().min(1).optional()
|
|
65034
|
+
}).superRefine((def, ctx) => {
|
|
65035
|
+
if (def.source && def.type !== "file") {
|
|
65036
|
+
ctx.addIssue({
|
|
65037
|
+
code: exports_external.ZodIssueCode.custom,
|
|
65038
|
+
path: ["source"],
|
|
65039
|
+
message: `"source" is only valid on a file input; input "${def.name}" has type "${def.type}"`
|
|
65040
|
+
});
|
|
65041
|
+
}
|
|
65042
|
+
const hasHint = def.mimeType !== undefined || def.extension !== undefined;
|
|
65043
|
+
if (hasHint && !(def.type === "file" && def.source)) {
|
|
65044
|
+
ctx.addIssue({
|
|
65045
|
+
code: exports_external.ZodIssueCode.custom,
|
|
65046
|
+
path: [def.mimeType !== undefined ? "mimeType" : "extension"],
|
|
65047
|
+
message: `"mimeType"/"extension" hints are only valid on a file input with a "source"; input "${def.name}" is not.`
|
|
65048
|
+
});
|
|
65049
|
+
}
|
|
65050
|
+
if (def.mimeType !== undefined && def.extension !== undefined) {
|
|
65051
|
+
ctx.addIssue({
|
|
65052
|
+
code: exports_external.ZodIssueCode.custom,
|
|
65053
|
+
path: ["extension"],
|
|
65054
|
+
message: `Set at most one of "mimeType" or "extension" on input "${def.name}".`
|
|
65055
|
+
});
|
|
65056
|
+
}
|
|
65057
|
+
if (def.mimeType !== undefined && !/^[a-z0-9.+-]+\/[a-z0-9.+-]+$/i.test(def.mimeType.trim())) {
|
|
65058
|
+
ctx.addIssue({
|
|
65059
|
+
code: exports_external.ZodIssueCode.custom,
|
|
65060
|
+
path: ["mimeType"],
|
|
65061
|
+
message: `"mimeType" on input "${def.name}" must look like "application/pdf".`
|
|
65062
|
+
});
|
|
65063
|
+
}
|
|
65064
|
+
if (def.extension !== undefined && !/^\.?[a-z0-9]+$/i.test(def.extension.trim())) {
|
|
65065
|
+
ctx.addIssue({
|
|
65066
|
+
code: exports_external.ZodIssueCode.custom,
|
|
65067
|
+
path: ["extension"],
|
|
65068
|
+
message: `"extension" on input "${def.name}" must be a bare extension like "pdf".`
|
|
65069
|
+
});
|
|
65070
|
+
}
|
|
65012
65071
|
});
|
|
65013
65072
|
ManualTriggerMethodSchema = exports_external.object({
|
|
65014
65073
|
type: exports_external.literal("manual"),
|
|
@@ -65371,6 +65430,121 @@ var init_workflow2 = __esm(() => {
|
|
|
65371
65430
|
init_execution2();
|
|
65372
65431
|
});
|
|
65373
65432
|
|
|
65433
|
+
// ../types/src/file-source/descriptor.ts
|
|
65434
|
+
function getBuiltinFileSourceDescriptor(name) {
|
|
65435
|
+
return BUILTIN_FILE_SOURCE_DESCRIPTORS.find((d) => d.name === name);
|
|
65436
|
+
}
|
|
65437
|
+
function validateFileSourceConfig(descriptor, raw) {
|
|
65438
|
+
const value = {};
|
|
65439
|
+
const errors3 = [];
|
|
65440
|
+
for (const field of descriptor.configFields) {
|
|
65441
|
+
const provided = raw[field.key];
|
|
65442
|
+
const isEmpty = provided === undefined || provided === null || provided === "";
|
|
65443
|
+
if (isEmpty) {
|
|
65444
|
+
if (field.default !== undefined) {
|
|
65445
|
+
value[field.key] = field.default;
|
|
65446
|
+
} else if (field.required) {
|
|
65447
|
+
errors3.push({ key: field.key, message: `${field.label} is required` });
|
|
65448
|
+
}
|
|
65449
|
+
continue;
|
|
65450
|
+
}
|
|
65451
|
+
switch (field.type) {
|
|
65452
|
+
case "number": {
|
|
65453
|
+
const n = typeof provided === "number" ? provided : Number(provided);
|
|
65454
|
+
if (!Number.isFinite(n)) {
|
|
65455
|
+
errors3.push({ key: field.key, message: `${field.label} must be a number` });
|
|
65456
|
+
} else {
|
|
65457
|
+
value[field.key] = n;
|
|
65458
|
+
}
|
|
65459
|
+
break;
|
|
65460
|
+
}
|
|
65461
|
+
case "boolean": {
|
|
65462
|
+
value[field.key] = typeof provided === "boolean" ? provided : provided === "true" || provided === "1";
|
|
65463
|
+
break;
|
|
65464
|
+
}
|
|
65465
|
+
case "string":
|
|
65466
|
+
case "secret": {
|
|
65467
|
+
value[field.key] = String(provided);
|
|
65468
|
+
break;
|
|
65469
|
+
}
|
|
65470
|
+
}
|
|
65471
|
+
}
|
|
65472
|
+
return { ok: errors3.length === 0, value, errors: errors3 };
|
|
65473
|
+
}
|
|
65474
|
+
function redactFileSourceSecrets(descriptor, config2) {
|
|
65475
|
+
const secretKeys = new Set(descriptor.configFields.filter((f) => f.type === "secret").map((f) => f.key));
|
|
65476
|
+
const out = {};
|
|
65477
|
+
for (const [key, val] of Object.entries(config2)) {
|
|
65478
|
+
if (!secretKeys.has(key))
|
|
65479
|
+
out[key] = val;
|
|
65480
|
+
}
|
|
65481
|
+
for (const key of secretKeys) {
|
|
65482
|
+
const val = config2[key];
|
|
65483
|
+
out[key] = val !== undefined && val !== null && val !== "";
|
|
65484
|
+
}
|
|
65485
|
+
return out;
|
|
65486
|
+
}
|
|
65487
|
+
var GPFS_FILE_SOURCE_NAME = "gpfs", GPFS_FILE_SOURCE_DESCRIPTOR, BUILTIN_FILE_SOURCE_DESCRIPTORS;
|
|
65488
|
+
var init_descriptor = __esm(() => {
|
|
65489
|
+
GPFS_FILE_SOURCE_DESCRIPTOR = {
|
|
65490
|
+
name: GPFS_FILE_SOURCE_NAME,
|
|
65491
|
+
label: "GPFS file registry",
|
|
65492
|
+
description: "Fetch documents by id from a GPFS/GFR HTTP file registry.",
|
|
65493
|
+
configFields: [
|
|
65494
|
+
{
|
|
65495
|
+
key: "baseUrl",
|
|
65496
|
+
label: "Base URL",
|
|
65497
|
+
type: "string",
|
|
65498
|
+
required: true,
|
|
65499
|
+
description: "Base URL of the registry. The file id is appended to fetch each file.",
|
|
65500
|
+
placeholder: "https://files.example.com/registry"
|
|
65501
|
+
},
|
|
65502
|
+
{
|
|
65503
|
+
key: "authToken",
|
|
65504
|
+
label: "Bearer token",
|
|
65505
|
+
type: "secret",
|
|
65506
|
+
required: false,
|
|
65507
|
+
description: "Bearer token for the registry, if it requires one."
|
|
65508
|
+
},
|
|
65509
|
+
{
|
|
65510
|
+
key: "insecureSkipTlsVerify",
|
|
65511
|
+
label: "Skip TLS verification",
|
|
65512
|
+
type: "boolean",
|
|
65513
|
+
required: false,
|
|
65514
|
+
description: "Only for registries with self-signed or legacy certificates.",
|
|
65515
|
+
default: false,
|
|
65516
|
+
advanced: true
|
|
65517
|
+
},
|
|
65518
|
+
{
|
|
65519
|
+
key: "timeoutMs",
|
|
65520
|
+
label: "Timeout (ms)",
|
|
65521
|
+
type: "number",
|
|
65522
|
+
required: false,
|
|
65523
|
+
description: "How long to wait for the registry before giving up.",
|
|
65524
|
+
default: 30000,
|
|
65525
|
+
advanced: true
|
|
65526
|
+
},
|
|
65527
|
+
{
|
|
65528
|
+
key: "maxFileBytes",
|
|
65529
|
+
label: "Max file size (bytes)",
|
|
65530
|
+
type: "number",
|
|
65531
|
+
required: false,
|
|
65532
|
+
description: "Reject files larger than this.",
|
|
65533
|
+
default: 50 * 1024 * 1024,
|
|
65534
|
+
advanced: true
|
|
65535
|
+
}
|
|
65536
|
+
]
|
|
65537
|
+
};
|
|
65538
|
+
BUILTIN_FILE_SOURCE_DESCRIPTORS = [
|
|
65539
|
+
GPFS_FILE_SOURCE_DESCRIPTOR
|
|
65540
|
+
];
|
|
65541
|
+
});
|
|
65542
|
+
|
|
65543
|
+
// ../types/src/file-source/index.ts
|
|
65544
|
+
var init_file_source = __esm(() => {
|
|
65545
|
+
init_descriptor();
|
|
65546
|
+
});
|
|
65547
|
+
|
|
65374
65548
|
// ../types/src/eval/compare-output.ts
|
|
65375
65549
|
function isPlainObject2(value) {
|
|
65376
65550
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
@@ -67862,6 +68036,7 @@ __export(exports_src, {
|
|
|
67862
68036
|
validateSourcePackageRequiredFiles: () => validateSourcePackageRequiredFiles,
|
|
67863
68037
|
validateOutput: () => validateOutput,
|
|
67864
68038
|
validateInput: () => validateInput,
|
|
68039
|
+
validateFileSourceConfig: () => validateFileSourceConfig,
|
|
67865
68040
|
validateConfig: () => validateConfig,
|
|
67866
68041
|
triggersFromWorkflowDefinition: () => triggersFromWorkflowDefinition,
|
|
67867
68042
|
triggersFromGitManifest: () => triggersFromGitManifest,
|
|
@@ -67887,6 +68062,7 @@ __export(exports_src, {
|
|
|
67887
68062
|
resolveEffectiveMimeType: () => resolveEffectiveMimeType,
|
|
67888
68063
|
resolveAgentOriginalSourceRef: () => resolveAgentOriginalSourceRef,
|
|
67889
68064
|
requiresSpecializedParser: () => requiresSpecializedParser,
|
|
68065
|
+
redactFileSourceSecrets: () => redactFileSourceSecrets,
|
|
67890
68066
|
publicExecutionFailure: () => publicExecutionFailure,
|
|
67891
68067
|
projectAgentInputFiles: () => projectAgentInputFiles,
|
|
67892
68068
|
pathToDottedPackageName: () => pathToDottedPackageName,
|
|
@@ -67901,6 +68077,7 @@ __export(exports_src, {
|
|
|
67901
68077
|
parseAutomationTarget: () => parseAutomationTarget,
|
|
67902
68078
|
parseAgentRerunVersion: () => parseAgentRerunVersion,
|
|
67903
68079
|
noopTracingContext: () => noopTracingContext,
|
|
68080
|
+
mimeTypeForExtension: () => mimeTypeForExtension,
|
|
67904
68081
|
matchS3Path: () => matchS3Path,
|
|
67905
68082
|
mapOCRAttributes: () => mapOCRAttributes,
|
|
67906
68083
|
mapLLMAttributes: () => mapLLMAttributes,
|
|
@@ -67923,6 +68100,7 @@ __export(exports_src, {
|
|
|
67923
68100
|
isFileOutput: () => isFileOutput,
|
|
67924
68101
|
isAutomationTriggerEnabled: () => isAutomationTriggerEnabled,
|
|
67925
68102
|
isAgentEmailExplicitlyDisabled: () => isAgentEmailExplicitlyDisabled,
|
|
68103
|
+
inputsWithSource: () => inputsWithSource,
|
|
67926
68104
|
hasTriggerMethod: () => hasTriggerMethod,
|
|
67927
68105
|
goldenFileSatisfiedInResult: () => goldenFileSatisfiedInResult,
|
|
67928
68106
|
getTriggerMethods: () => getTriggerMethods,
|
|
@@ -67936,6 +68114,7 @@ __export(exports_src, {
|
|
|
67936
68114
|
getConfigSchema: () => getConfigSchema,
|
|
67937
68115
|
getConfigFieldMetadata: () => getConfigFieldMetadata,
|
|
67938
68116
|
getConfigDefaults: () => getConfigDefaults,
|
|
68117
|
+
getBuiltinFileSourceDescriptor: () => getBuiltinFileSourceDescriptor,
|
|
67939
68118
|
getAllSupportedMimeTypes: () => getAllSupportedMimeTypes,
|
|
67940
68119
|
getAllStepJsonSchemas: () => getAllStepJsonSchemas,
|
|
67941
68120
|
getAllProcessorJsonSchemas: () => getAllProcessorJsonSchemas,
|
|
@@ -67949,6 +68128,7 @@ __export(exports_src, {
|
|
|
67949
68128
|
fileFieldNamesFromJsonSchema: () => fileFieldNamesFromJsonSchema,
|
|
67950
68129
|
fieldStemFromGoldenName: () => fieldStemFromGoldenName,
|
|
67951
68130
|
extractFieldMetadata: () => extractFieldMetadata,
|
|
68131
|
+
extensionForMimeType: () => extensionForMimeType,
|
|
67952
68132
|
executionWallClockMs: () => executionWallClockMs,
|
|
67953
68133
|
executionPhaseLabel: () => executionPhaseLabel,
|
|
67954
68134
|
executionPhaseDurationMs: () => executionPhaseDurationMs,
|
|
@@ -68129,6 +68309,8 @@ __export(exports_src, {
|
|
|
68129
68309
|
ID_PREFIXES: () => ID_PREFIXES,
|
|
68130
68310
|
HttpMethodSchema: () => HttpMethodSchema,
|
|
68131
68311
|
GenAI: () => GenAI,
|
|
68312
|
+
GPFS_FILE_SOURCE_NAME: () => GPFS_FILE_SOURCE_NAME,
|
|
68313
|
+
GPFS_FILE_SOURCE_DESCRIPTOR: () => GPFS_FILE_SOURCE_DESCRIPTOR,
|
|
68132
68314
|
ForeachStepSchema: () => ForeachStepSchema,
|
|
68133
68315
|
FilePathDescriptorSchema: () => FilePathDescriptorSchema,
|
|
68134
68316
|
FailStepSchema: () => FailStepSchema,
|
|
@@ -68224,6 +68406,7 @@ __export(exports_src, {
|
|
|
68224
68406
|
BoundingRegionSchema: () => BoundingRegionSchema,
|
|
68225
68407
|
BlockStepSchema: () => BlockStepSchema,
|
|
68226
68408
|
BaseEntitySchema: () => BaseEntitySchema,
|
|
68409
|
+
BUILTIN_FILE_SOURCE_DESCRIPTORS: () => BUILTIN_FILE_SOURCE_DESCRIPTORS,
|
|
68227
68410
|
AutomationTargetSchema: () => AutomationTargetSchema,
|
|
68228
68411
|
ApiTriggerMethodSchema: () => ApiTriggerMethodSchema,
|
|
68229
68412
|
AiParseOutputSchema: () => AiParseOutputSchema,
|
|
@@ -68253,6 +68436,7 @@ var init_src = __esm(() => {
|
|
|
68253
68436
|
init_s3_paths();
|
|
68254
68437
|
init_validation();
|
|
68255
68438
|
init_workflow2();
|
|
68439
|
+
init_file_source();
|
|
68256
68440
|
init_eval();
|
|
68257
68441
|
init_git_source();
|
|
68258
68442
|
init_triggers();
|
|
@@ -166080,11 +166264,11 @@ function closestMatch(target, candidates, options8) {
|
|
|
166080
166264
|
}
|
|
166081
166265
|
return best;
|
|
166082
166266
|
}
|
|
166083
|
-
function getDescription(key2, value, expected,
|
|
166267
|
+
function getDescription(key2, value, expected, descriptor2) {
|
|
166084
166268
|
return [
|
|
166085
|
-
`Invalid ${import_picocolors22.default.red(
|
|
166269
|
+
`Invalid ${import_picocolors22.default.red(descriptor2.key(key2))} value.`,
|
|
166086
166270
|
`Expected ${import_picocolors22.default.blue(expected)},`,
|
|
166087
|
-
`but received ${value === VALUE_NOT_EXIST ? import_picocolors22.default.gray("nothing") : import_picocolors22.default.red(
|
|
166271
|
+
`but received ${value === VALUE_NOT_EXIST ? import_picocolors22.default.gray("nothing") : import_picocolors22.default.red(descriptor2.value(value))}.`
|
|
166088
166272
|
].join(" ");
|
|
166089
166273
|
}
|
|
166090
166274
|
function getListDescription({ text, list }, printWidth) {
|
|
@@ -169333,17 +169517,17 @@ function normalizeOptions(options8, optionInfos, {
|
|
|
169333
169517
|
isCLI = false,
|
|
169334
169518
|
passThrough = false,
|
|
169335
169519
|
FlagSchema,
|
|
169336
|
-
descriptor
|
|
169520
|
+
descriptor: descriptor2
|
|
169337
169521
|
} = {}) {
|
|
169338
169522
|
if (isCLI) {
|
|
169339
169523
|
if (!FlagSchema) {
|
|
169340
169524
|
throw new Error("'FlagSchema' option is required.");
|
|
169341
169525
|
}
|
|
169342
|
-
if (!
|
|
169526
|
+
if (!descriptor2) {
|
|
169343
169527
|
throw new Error("'descriptor' option is required.");
|
|
169344
169528
|
}
|
|
169345
169529
|
} else {
|
|
169346
|
-
|
|
169530
|
+
descriptor2 = apiDescriptor;
|
|
169347
169531
|
}
|
|
169348
169532
|
const unknown2 = !passThrough ? (key2, value, options9) => {
|
|
169349
169533
|
const {
|
|
@@ -169366,7 +169550,7 @@ function normalizeOptions(options8, optionInfos, {
|
|
|
169366
169550
|
const normalizer = new Normalizer(schemas3, {
|
|
169367
169551
|
logger,
|
|
169368
169552
|
unknown: unknown2,
|
|
169369
|
-
descriptor
|
|
169553
|
+
descriptor: descriptor2
|
|
169370
169554
|
});
|
|
169371
169555
|
const shouldSuppressDuplicateDeprecationWarnings = logger !== false;
|
|
169372
169556
|
if (shouldSuppressDuplicateDeprecationWarnings && hasDeprecationWarned) {
|
|
@@ -170944,12 +171128,12 @@ var require3, __filename2, __dirname2, __create2, __defProp3, __getOwnPropDesc,
|
|
|
170944
171128
|
}
|
|
170945
171129
|
return components;
|
|
170946
171130
|
}
|
|
170947
|
-
}, LineDiff, lineDiff, ArrayDiff, arrayDiff, import_fast_glob, array2, characterCodeCache, import_picocolors5, apiDescriptor, import_picocolors2, commonDeprecatedHandler = (keyOrPair, redirectTo, { descriptor }) => {
|
|
171131
|
+
}, LineDiff, lineDiff, ArrayDiff, arrayDiff, import_fast_glob, array2, characterCodeCache, import_picocolors5, apiDescriptor, import_picocolors2, commonDeprecatedHandler = (keyOrPair, redirectTo, { descriptor: descriptor2 }) => {
|
|
170948
171132
|
const messages2 = [
|
|
170949
|
-
`${import_picocolors2.default.yellow(typeof keyOrPair === "string" ?
|
|
171133
|
+
`${import_picocolors2.default.yellow(typeof keyOrPair === "string" ? descriptor2.key(keyOrPair) : descriptor2.pair(keyOrPair))} is deprecated`
|
|
170950
171134
|
];
|
|
170951
171135
|
if (redirectTo) {
|
|
170952
|
-
messages2.push(`we now treat it as ${import_picocolors2.default.blue(typeof redirectTo === "string" ?
|
|
171136
|
+
messages2.push(`we now treat it as ${import_picocolors2.default.blue(typeof redirectTo === "string" ? descriptor2.key(redirectTo) : descriptor2.pair(redirectTo))}`);
|
|
170953
171137
|
}
|
|
170954
171138
|
return messages2.join("; ") + ".";
|
|
170955
171139
|
}, import_picocolors22, VALUE_NOT_EXIST, VALUE_UNCHANGED, INDENTATION, commonInvalidHandler = (key2, value, utils2) => {
|
|
@@ -170963,13 +171147,13 @@ var require3, __filename2, __dirname2, __create2, __defProp3, __getOwnPropDesc,
|
|
|
170963
171147
|
`));
|
|
170964
171148
|
}
|
|
170965
171149
|
return chooseDescription(descriptions, utils2.loggerPrintWidth);
|
|
170966
|
-
}, import_picocolors3, levenUnknownHandler = (key2, value, { descriptor, logger, schemas: schemas3 }) => {
|
|
171150
|
+
}, import_picocolors3, levenUnknownHandler = (key2, value, { descriptor: descriptor2, logger, schemas: schemas3 }) => {
|
|
170967
171151
|
const messages2 = [
|
|
170968
|
-
`Ignored unknown option ${import_picocolors3.default.yellow(
|
|
171152
|
+
`Ignored unknown option ${import_picocolors3.default.yellow(descriptor2.pair({ key: key2, value }))}.`
|
|
170969
171153
|
];
|
|
170970
171154
|
const suggestion = closestMatch(key2, Object.keys(schemas3), { maxDistance: 3 });
|
|
170971
171155
|
if (suggestion) {
|
|
170972
|
-
messages2.push(`Did you mean ${import_picocolors3.default.blue(
|
|
171156
|
+
messages2.push(`Did you mean ${import_picocolors3.default.blue(descriptor2.key(suggestion))}?`);
|
|
170973
171157
|
}
|
|
170974
171158
|
logger.warn(messages2.join(" "));
|
|
170975
171159
|
}, HANDLER_KEYS, Schema = class {
|
|
@@ -171008,9 +171192,9 @@ var require3, __filename2, __dirname2, __create2, __defProp3, __getOwnPropDesc,
|
|
|
171008
171192
|
}
|
|
171009
171193
|
}, AliasSchema, AnySchema, ArraySchema, BooleanSchema, ChoiceSchema, NumberSchema, IntegerSchema, StringSchema, defaultDescriptor, defaultUnknownHandler, defaultInvalidHandler, defaultDeprecatedHandler, Normalizer = class {
|
|
171010
171194
|
constructor(schemas3, opts) {
|
|
171011
|
-
const { logger = console, loggerPrintWidth = 80, descriptor = defaultDescriptor, unknown: unknown2 = defaultUnknownHandler, invalid = defaultInvalidHandler, deprecated = defaultDeprecatedHandler, missing = () => false, required: required2 = () => false, preprocess: preprocess2 = (x10) => x10, postprocess = () => VALUE_UNCHANGED } = opts || {};
|
|
171195
|
+
const { logger = console, loggerPrintWidth = 80, descriptor: descriptor2 = defaultDescriptor, unknown: unknown2 = defaultUnknownHandler, invalid = defaultInvalidHandler, deprecated = defaultDeprecatedHandler, missing = () => false, required: required2 = () => false, preprocess: preprocess2 = (x10) => x10, postprocess = () => VALUE_UNCHANGED } = opts || {};
|
|
171012
171196
|
this._utils = {
|
|
171013
|
-
descriptor,
|
|
171197
|
+
descriptor: descriptor2,
|
|
171014
171198
|
logger: logger || { warn: () => {} },
|
|
171015
171199
|
loggerPrintWidth,
|
|
171016
171200
|
schemas: recordFromArray(schemas3, "name"),
|
|
@@ -180295,8 +180479,8 @@ globstar while`, file2, fr10, pattern, pr8, swallowee);
|
|
|
180295
180479
|
super(parameters);
|
|
180296
180480
|
this._choices = mapFromArray(parameters.choices.map((choice) => choice && typeof choice === "object" ? choice : { value: choice }), "value");
|
|
180297
180481
|
}
|
|
180298
|
-
expected({ descriptor }) {
|
|
180299
|
-
const choiceDescriptions = Array.from(this._choices.keys()).map((value) => this._choices.get(value)).filter(({ hidden }) => !hidden).map((choiceInfo) => choiceInfo.value).sort(comparePrimitive).map(
|
|
180482
|
+
expected({ descriptor: descriptor2 }) {
|
|
180483
|
+
const choiceDescriptions = Array.from(this._choices.keys()).map((value) => this._choices.get(value)).filter(({ hidden }) => !hidden).map((choiceInfo) => choiceInfo.value).sort(comparePrimitive).map(descriptor2.value);
|
|
180300
180484
|
const head = choiceDescriptions.slice(0, -2);
|
|
180301
180485
|
const tail = choiceDescriptions.slice(-2);
|
|
180302
180486
|
const message = head.concat(tail.join(" or ")).join(", ");
|
|
@@ -189893,7 +190077,7 @@ import { fileURLToPath as fileURLToPath8 } from "url";
|
|
|
189893
190077
|
// package.json
|
|
189894
190078
|
var package_default = {
|
|
189895
190079
|
name: "@eigenpal/cli",
|
|
189896
|
-
version: "0.10.
|
|
190080
|
+
version: "0.10.2",
|
|
189897
190081
|
description: "Eigenpal CLI — author and run document workflows from your terminal. Agent-ready.",
|
|
189898
190082
|
keywords: [
|
|
189899
190083
|
"eigenpal",
|
|
@@ -490,4 +490,7 @@ _Generated from `WorkflowDefinitionSchema` in `@eigenpal/types/src/workflow/work
|
|
|
490
490
|
| `default` | unknown | no | | |
|
|
491
491
|
| `values` | array<string> | no | | |
|
|
492
492
|
| `items` | object | no | | |
|
|
493
|
+
| `source` | string | no | | |
|
|
494
|
+
| `mimeType` | string | no | | |
|
|
495
|
+
| `extension` | string | no | | |
|
|
493
496
|
<!-- GENERATED:WORKFLOW_REFERENCE END -->
|