@eigenpal/cli 0.10.37 → 0.10.38
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 +348 -154
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -17330,7 +17330,8 @@ var init_common = __esm(() => {
|
|
|
17330
17330
|
WEBHOOK_ATTEMPT: "what",
|
|
17331
17331
|
PAID_ALLOWANCE_GRANT: "pag",
|
|
17332
17332
|
PAID_ALLOWANCE_ADJUSTMENT: "paa",
|
|
17333
|
-
OCR_EXTRACTION_PIPELINE: "
|
|
17333
|
+
OCR_EXTRACTION_PIPELINE: "oppl",
|
|
17334
|
+
OCR_JOB: "opj",
|
|
17334
17335
|
SANDBOX_WS_TOKEN: "sws"
|
|
17335
17336
|
};
|
|
17336
17337
|
TimestampSchema = exports_external.union([exports_external.date(), exports_external.string().datetime()]).transform((val) => {
|
|
@@ -69263,6 +69264,14 @@ var init_parsed_document = __esm(() => {
|
|
|
69263
69264
|
});
|
|
69264
69265
|
});
|
|
69265
69266
|
|
|
69267
|
+
// ../types/src/ocr/job-id.ts
|
|
69268
|
+
var OCR_JOB_ID_PREFIX = "opj", OCR_JOB_ID_PATTERN, JobIdSchema;
|
|
69269
|
+
var init_job_id = __esm(() => {
|
|
69270
|
+
init_zod();
|
|
69271
|
+
OCR_JOB_ID_PATTERN = /^opj_[A-Za-z0-9_-]+$/;
|
|
69272
|
+
JobIdSchema = exports_external.string().regex(OCR_JOB_ID_PATTERN, "job id must be an opj_… id").max(128);
|
|
69273
|
+
});
|
|
69274
|
+
|
|
69266
69275
|
// ../types/src/ocr/grounding.ts
|
|
69267
69276
|
var EXTRACTION_GROUNDING_MODES, ExtractionGroundingModeSchema, EXTRACTION_CITATION_GRANULARITIES, ExtractionCitationGranularitySchema, CitationSourceTypeSchema, ExtractionCitationSchema, ExtractionGroundingFieldSchema, ExtractionGroundingResultSchema;
|
|
69268
69277
|
var init_grounding = __esm(() => {
|
|
@@ -69519,6 +69528,7 @@ var EXTRACTION_ATTEMPT_KINDS, ExtractionAttemptKindSchema, EXTRACTION_ATTEMPT_ST
|
|
|
69519
69528
|
var init_extraction = __esm(() => {
|
|
69520
69529
|
init_zod();
|
|
69521
69530
|
init_grounding();
|
|
69531
|
+
init_job_id();
|
|
69522
69532
|
init_llm_models();
|
|
69523
69533
|
init_parsed_document();
|
|
69524
69534
|
EXTRACTION_ATTEMPT_KINDS = ["primary", "repair"];
|
|
@@ -69544,7 +69554,7 @@ var init_extraction = __esm(() => {
|
|
|
69544
69554
|
output: exports_external.unknown(),
|
|
69545
69555
|
parsed_document: ParsedDocumentSchema,
|
|
69546
69556
|
llm_model: LlmModelSchema,
|
|
69547
|
-
parse_job_id:
|
|
69557
|
+
parse_job_id: JobIdSchema.optional(),
|
|
69548
69558
|
reasoning_effort: OcrLlmReasoningEffortSchema.nullable().optional(),
|
|
69549
69559
|
attempts: exports_external.array(ExtractionAttemptSchema).min(1),
|
|
69550
69560
|
usage: ExtractionUsageTotalsSchema.optional(),
|
|
@@ -69552,6 +69562,298 @@ var init_extraction = __esm(() => {
|
|
|
69552
69562
|
}).strict();
|
|
69553
69563
|
});
|
|
69554
69564
|
|
|
69565
|
+
// ../types/src/ocr/model-options.ts
|
|
69566
|
+
function applyPaddleOcrOptionDefaults(requested) {
|
|
69567
|
+
const source = requested && typeof requested === "object" ? requested : undefined;
|
|
69568
|
+
return {
|
|
69569
|
+
image_block_ocr: typeof source?.image_block_ocr === "boolean" ? source.image_block_ocr : PADDLE_OCR_OPTION_DEFAULTS.image_block_ocr,
|
|
69570
|
+
chart_recognition: typeof source?.chart_recognition === "boolean" ? source.chart_recognition : PADDLE_OCR_OPTION_DEFAULTS.chart_recognition,
|
|
69571
|
+
merge_layout_blocks: typeof source?.merge_layout_blocks === "boolean" ? source.merge_layout_blocks : PADDLE_OCR_OPTION_DEFAULTS.merge_layout_blocks
|
|
69572
|
+
};
|
|
69573
|
+
}
|
|
69574
|
+
var OcrFigureAssetsModeSchema, PaddleOcrOptionsRequestSchema, PaddleOcrOptionsEffectiveSchema, PADDLE_OCR_OPTION_DEFAULTS, OcrOptionsRequestSchema, OcrOptionsEffectiveSchema, LlmOptionsRequestSchema, LlmOptionsStoredSchema, OcrModelOptionCapabilitySchema;
|
|
69575
|
+
var init_model_options = __esm(() => {
|
|
69576
|
+
init_zod();
|
|
69577
|
+
init_llm_models();
|
|
69578
|
+
OcrFigureAssetsModeSchema = exports_external.enum(["none", "stored"]);
|
|
69579
|
+
PaddleOcrOptionsRequestSchema = exports_external.object({
|
|
69580
|
+
image_block_ocr: exports_external.boolean().optional(),
|
|
69581
|
+
chart_recognition: exports_external.boolean().optional(),
|
|
69582
|
+
merge_layout_blocks: exports_external.boolean().optional().describe("Merge nearby cross-column or staggered text regions before recognition. Defaults to false to preserve one-to-one text and bounding-box alignment.")
|
|
69583
|
+
}).strict();
|
|
69584
|
+
PaddleOcrOptionsEffectiveSchema = exports_external.object({
|
|
69585
|
+
image_block_ocr: exports_external.boolean(),
|
|
69586
|
+
chart_recognition: exports_external.boolean(),
|
|
69587
|
+
merge_layout_blocks: exports_external.boolean()
|
|
69588
|
+
}).strict();
|
|
69589
|
+
PADDLE_OCR_OPTION_DEFAULTS = {
|
|
69590
|
+
image_block_ocr: false,
|
|
69591
|
+
chart_recognition: true,
|
|
69592
|
+
merge_layout_blocks: false
|
|
69593
|
+
};
|
|
69594
|
+
OcrOptionsRequestSchema = PaddleOcrOptionsRequestSchema;
|
|
69595
|
+
OcrOptionsEffectiveSchema = PaddleOcrOptionsEffectiveSchema;
|
|
69596
|
+
LlmOptionsRequestSchema = exports_external.object({ reasoning_effort: OcrLlmReasoningEffortRequestSchema.optional() }).strict();
|
|
69597
|
+
LlmOptionsStoredSchema = exports_external.object({ reasoning_effort: OcrLlmReasoningEffortRequestSchema.nullable() }).strict();
|
|
69598
|
+
OcrModelOptionCapabilitySchema = exports_external.object({
|
|
69599
|
+
image_block_ocr: exports_external.boolean(),
|
|
69600
|
+
chart_recognition: exports_external.boolean(),
|
|
69601
|
+
merge_layout_blocks: exports_external.boolean()
|
|
69602
|
+
}).strict();
|
|
69603
|
+
});
|
|
69604
|
+
|
|
69605
|
+
// ../types/src/ocr/pipeline-extraction-schema.ts
|
|
69606
|
+
function isPlainObject3(value) {
|
|
69607
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
69608
|
+
}
|
|
69609
|
+
function typeList(schema) {
|
|
69610
|
+
if (typeof schema.type === "string")
|
|
69611
|
+
return [schema.type];
|
|
69612
|
+
if (Array.isArray(schema.type)) {
|
|
69613
|
+
return schema.type.filter((t) => typeof t === "string");
|
|
69614
|
+
}
|
|
69615
|
+
return [];
|
|
69616
|
+
}
|
|
69617
|
+
function isObjectRootSchema(schema) {
|
|
69618
|
+
const types = typeList(schema);
|
|
69619
|
+
if (types.includes("object"))
|
|
69620
|
+
return true;
|
|
69621
|
+
return types.length === 0 && isPlainObject3(schema.properties);
|
|
69622
|
+
}
|
|
69623
|
+
function pipelineExtractionSchemaRootPropertyCount(schema) {
|
|
69624
|
+
if (!isPlainObject3(schema))
|
|
69625
|
+
return null;
|
|
69626
|
+
if (!isObjectRootSchema(schema))
|
|
69627
|
+
return null;
|
|
69628
|
+
if (!isPlainObject3(schema.properties))
|
|
69629
|
+
return null;
|
|
69630
|
+
return Object.keys(schema.properties).length;
|
|
69631
|
+
}
|
|
69632
|
+
function hasPipelineExtractionSchemaProperties(schema) {
|
|
69633
|
+
const count = pipelineExtractionSchemaRootPropertyCount(schema);
|
|
69634
|
+
return count !== null && count > 0;
|
|
69635
|
+
}
|
|
69636
|
+
function refinePipelineExtractionSchema(schema, ctx, path = ["schema"]) {
|
|
69637
|
+
if (!isPlainObject3(schema)) {
|
|
69638
|
+
ctx.addIssue({
|
|
69639
|
+
code: "custom",
|
|
69640
|
+
message: "schema must be an object",
|
|
69641
|
+
path
|
|
69642
|
+
});
|
|
69643
|
+
return;
|
|
69644
|
+
}
|
|
69645
|
+
const count = pipelineExtractionSchemaRootPropertyCount(schema);
|
|
69646
|
+
if (count === null) {
|
|
69647
|
+
ctx.addIssue({
|
|
69648
|
+
code: "custom",
|
|
69649
|
+
message: "schema root must be an object schema with explicit properties",
|
|
69650
|
+
path
|
|
69651
|
+
});
|
|
69652
|
+
return;
|
|
69653
|
+
}
|
|
69654
|
+
if (count === 0) {
|
|
69655
|
+
ctx.addIssue({
|
|
69656
|
+
code: "custom",
|
|
69657
|
+
message: PIPELINE_EXTRACTION_SCHEMA_EMPTY_PROPERTIES_MESSAGE,
|
|
69658
|
+
path
|
|
69659
|
+
});
|
|
69660
|
+
}
|
|
69661
|
+
}
|
|
69662
|
+
var PIPELINE_EXTRACTION_SCHEMA_EMPTY_PROPERTIES_MESSAGE = "extraction pipeline schema must include at least one named property";
|
|
69663
|
+
|
|
69664
|
+
// ../types/src/ocr/pipelines.ts
|
|
69665
|
+
function refineExtractPipelineXor(value, ctx, options) {
|
|
69666
|
+
const hasPipeline = value.pipeline_id !== undefined;
|
|
69667
|
+
const presentInline = EXTRACT_INLINE_CONFIG_KEYS.filter((key) => value[key] !== undefined);
|
|
69668
|
+
const requireOcrModel = options?.requireOcrModel !== false;
|
|
69669
|
+
if (hasPipeline && presentInline.length > 0) {
|
|
69670
|
+
ctx.addIssue({
|
|
69671
|
+
code: "custom",
|
|
69672
|
+
message: "pipeline_inline_conflict",
|
|
69673
|
+
path: ["pipeline_id"]
|
|
69674
|
+
});
|
|
69675
|
+
return;
|
|
69676
|
+
}
|
|
69677
|
+
if (hasPipeline)
|
|
69678
|
+
return;
|
|
69679
|
+
if (requireOcrModel && value.ocr_model === undefined) {
|
|
69680
|
+
ctx.addIssue({ code: "custom", message: "Required", path: ["ocr_model"] });
|
|
69681
|
+
}
|
|
69682
|
+
if (value.llm_model === undefined) {
|
|
69683
|
+
ctx.addIssue({ code: "custom", message: "Required", path: ["llm_model"] });
|
|
69684
|
+
}
|
|
69685
|
+
if (value.schema === undefined) {
|
|
69686
|
+
ctx.addIssue({ code: "custom", message: "Required", path: ["schema"] });
|
|
69687
|
+
}
|
|
69688
|
+
}
|
|
69689
|
+
var ExtractionPipelineIdSchema, ExtractionPipelineNameSchema, ExtractionPipelineSlugSchema, PipelineExtractionSchemaObjectSchema, PipelineConfigFields, CreateExtractionPipelineRequestSchema, UpdateExtractionPipelineRequestSchema, ExtractionPipelineSchema, ExtractionPipelineListResponseSchema, DeleteExtractionPipelineResponseSchema, EXTRACT_INLINE_CONFIG_KEYS;
|
|
69690
|
+
var init_pipelines = __esm(() => {
|
|
69691
|
+
init_zod();
|
|
69692
|
+
init_extraction();
|
|
69693
|
+
init_grounding();
|
|
69694
|
+
init_model_options();
|
|
69695
|
+
ExtractionPipelineIdSchema = exports_external.string().regex(/^oppl_[A-Za-z0-9_-]+$/, "pipeline_id must be an oppl_… id").max(128);
|
|
69696
|
+
ExtractionPipelineNameSchema = exports_external.string().trim().min(1).max(128);
|
|
69697
|
+
ExtractionPipelineSlugSchema = exports_external.string().trim().min(1).max(128).regex(/^[a-z0-9][a-z0-9_-]*$/, "slug must be lowercase alphanumeric with _ or -");
|
|
69698
|
+
PipelineExtractionSchemaObjectSchema = exports_external.record(exports_external.string(), exports_external.unknown()).superRefine((schema, ctx) => refinePipelineExtractionSchema(schema, ctx));
|
|
69699
|
+
PipelineConfigFields = {
|
|
69700
|
+
ocr_model: exports_external.string().min(1).max(128),
|
|
69701
|
+
ocr_options: OcrOptionsRequestSchema.optional(),
|
|
69702
|
+
llm_model: LlmModelSchema,
|
|
69703
|
+
llm_options: LlmOptionsRequestSchema.optional(),
|
|
69704
|
+
schema: PipelineExtractionSchemaObjectSchema,
|
|
69705
|
+
repair_attempts: exports_external.number().int().min(0).max(2).optional(),
|
|
69706
|
+
grounding: ExtractionGroundingModeSchema.optional()
|
|
69707
|
+
};
|
|
69708
|
+
CreateExtractionPipelineRequestSchema = exports_external.object({
|
|
69709
|
+
name: ExtractionPipelineNameSchema,
|
|
69710
|
+
slug: ExtractionPipelineSlugSchema.optional(),
|
|
69711
|
+
...PipelineConfigFields
|
|
69712
|
+
}).strict();
|
|
69713
|
+
UpdateExtractionPipelineRequestSchema = exports_external.object({
|
|
69714
|
+
name: ExtractionPipelineNameSchema.optional(),
|
|
69715
|
+
slug: ExtractionPipelineSlugSchema.nullable().optional(),
|
|
69716
|
+
ocr_model: PipelineConfigFields.ocr_model.optional(),
|
|
69717
|
+
ocr_options: OcrOptionsRequestSchema.nullable().optional(),
|
|
69718
|
+
llm_model: PipelineConfigFields.llm_model.optional(),
|
|
69719
|
+
llm_options: LlmOptionsRequestSchema.nullable().optional(),
|
|
69720
|
+
schema: PipelineExtractionSchemaObjectSchema.optional(),
|
|
69721
|
+
repair_attempts: exports_external.number().int().min(0).max(2).optional(),
|
|
69722
|
+
grounding: ExtractionGroundingModeSchema.optional()
|
|
69723
|
+
}).strict().superRefine((value, ctx) => {
|
|
69724
|
+
if (Object.keys(value).length === 0) {
|
|
69725
|
+
ctx.addIssue({
|
|
69726
|
+
code: "custom",
|
|
69727
|
+
message: "at least one field is required"
|
|
69728
|
+
});
|
|
69729
|
+
}
|
|
69730
|
+
});
|
|
69731
|
+
ExtractionPipelineSchema = exports_external.object({
|
|
69732
|
+
id: ExtractionPipelineIdSchema,
|
|
69733
|
+
name: ExtractionPipelineNameSchema,
|
|
69734
|
+
slug: ExtractionPipelineSlugSchema.nullable(),
|
|
69735
|
+
version: exports_external.number().int().min(1),
|
|
69736
|
+
ocr_model: exports_external.string().min(1).max(128),
|
|
69737
|
+
ocr_options: OcrOptionsEffectiveSchema,
|
|
69738
|
+
llm_model: LlmModelSchema,
|
|
69739
|
+
llm_options: LlmOptionsStoredSchema,
|
|
69740
|
+
schema: PipelineExtractionSchemaObjectSchema,
|
|
69741
|
+
repair_attempts: exports_external.number().int().min(0).max(2),
|
|
69742
|
+
grounding: ExtractionGroundingModeSchema,
|
|
69743
|
+
created_at: exports_external.string().datetime(),
|
|
69744
|
+
updated_at: exports_external.string().datetime()
|
|
69745
|
+
}).strict();
|
|
69746
|
+
ExtractionPipelineListResponseSchema = exports_external.object({
|
|
69747
|
+
items: exports_external.array(ExtractionPipelineSchema)
|
|
69748
|
+
}).strict();
|
|
69749
|
+
DeleteExtractionPipelineResponseSchema = exports_external.object({
|
|
69750
|
+
deleted: exports_external.literal(true),
|
|
69751
|
+
id: ExtractionPipelineIdSchema
|
|
69752
|
+
}).strict();
|
|
69753
|
+
EXTRACT_INLINE_CONFIG_KEYS = [
|
|
69754
|
+
"ocr_model",
|
|
69755
|
+
"ocr_options",
|
|
69756
|
+
"llm_model",
|
|
69757
|
+
"llm_options",
|
|
69758
|
+
"schema",
|
|
69759
|
+
"repair_attempts",
|
|
69760
|
+
"grounding"
|
|
69761
|
+
];
|
|
69762
|
+
});
|
|
69763
|
+
|
|
69764
|
+
// ../types/src/ocr/id-compat.ts
|
|
69765
|
+
function migratedOcrJobIdFromUuid(uuid3) {
|
|
69766
|
+
return `opj_${uuid3.toLowerCase().replace(/-/g, "")}`;
|
|
69767
|
+
}
|
|
69768
|
+
function legacyUuidFromMigratedOcrJobId(jobId) {
|
|
69769
|
+
const match = /^opj_([0-9a-f]{32})$/.exec(jobId);
|
|
69770
|
+
if (!match)
|
|
69771
|
+
return null;
|
|
69772
|
+
const hex3 = match[1];
|
|
69773
|
+
return `${hex3.slice(0, 8)}-${hex3.slice(8, 12)}-${hex3.slice(12, 16)}-${hex3.slice(16, 20)}-${hex3.slice(20)}`;
|
|
69774
|
+
}
|
|
69775
|
+
function normalizeOcrJobIdInput(id) {
|
|
69776
|
+
const trimmed = id.trim();
|
|
69777
|
+
if (LEGACY_OCR_JOB_UUID_PATTERN.test(trimmed)) {
|
|
69778
|
+
return migratedOcrJobIdFromUuid(trimmed);
|
|
69779
|
+
}
|
|
69780
|
+
return trimmed;
|
|
69781
|
+
}
|
|
69782
|
+
function ocrJobIdLookupCandidates(id) {
|
|
69783
|
+
const trimmed = id.trim();
|
|
69784
|
+
const canonical = normalizeOcrJobIdInput(trimmed);
|
|
69785
|
+
const out = new Set;
|
|
69786
|
+
if (trimmed.length > 0)
|
|
69787
|
+
out.add(trimmed);
|
|
69788
|
+
if (canonical.length > 0)
|
|
69789
|
+
out.add(canonical);
|
|
69790
|
+
const legacy = legacyUuidFromMigratedOcrJobId(canonical);
|
|
69791
|
+
if (legacy)
|
|
69792
|
+
out.add(legacy);
|
|
69793
|
+
return [...out];
|
|
69794
|
+
}
|
|
69795
|
+
function isOcrJobIdInput(id) {
|
|
69796
|
+
return JobIdInputSchema.safeParse(id).success;
|
|
69797
|
+
}
|
|
69798
|
+
function isPreferredOcrJobId(id) {
|
|
69799
|
+
return OCR_JOB_ID_PATTERN.test(id);
|
|
69800
|
+
}
|
|
69801
|
+
function normalizeOcrPipelineIdInput(id) {
|
|
69802
|
+
const trimmed = id.trim();
|
|
69803
|
+
if (trimmed.startsWith(LEGACY_OCR_PIPELINE_ID_PREFIX)) {
|
|
69804
|
+
return `oppl_${trimmed.slice(LEGACY_OCR_PIPELINE_ID_PREFIX.length)}`;
|
|
69805
|
+
}
|
|
69806
|
+
return trimmed;
|
|
69807
|
+
}
|
|
69808
|
+
function legacyOepFromMigratedOcrPipelineId(pipelineId) {
|
|
69809
|
+
if (!pipelineId.startsWith("oppl_"))
|
|
69810
|
+
return null;
|
|
69811
|
+
return `${LEGACY_OCR_PIPELINE_ID_PREFIX}${pipelineId.slice("oppl_".length)}`;
|
|
69812
|
+
}
|
|
69813
|
+
function ocrPipelineIdLookupCandidates(id) {
|
|
69814
|
+
const trimmed = id.trim();
|
|
69815
|
+
const canonical = normalizeOcrPipelineIdInput(trimmed);
|
|
69816
|
+
const out = new Set;
|
|
69817
|
+
if (trimmed.length > 0)
|
|
69818
|
+
out.add(trimmed);
|
|
69819
|
+
if (canonical.length > 0)
|
|
69820
|
+
out.add(canonical);
|
|
69821
|
+
const legacy = legacyOepFromMigratedOcrPipelineId(canonical);
|
|
69822
|
+
if (legacy)
|
|
69823
|
+
out.add(legacy);
|
|
69824
|
+
return [...out];
|
|
69825
|
+
}
|
|
69826
|
+
var LEGACY_OCR_JOB_UUID_PATTERN, JobIdInputSchema, LEGACY_OCR_PIPELINE_ID_PREFIX = "oep_", ExtractionPipelineIdInputSchema;
|
|
69827
|
+
var init_id_compat = __esm(() => {
|
|
69828
|
+
init_zod();
|
|
69829
|
+
init_job_id();
|
|
69830
|
+
init_pipelines();
|
|
69831
|
+
LEGACY_OCR_JOB_UUID_PATTERN = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
|
|
69832
|
+
JobIdInputSchema = exports_external.string().max(128).transform((value, ctx) => {
|
|
69833
|
+
const normalized = normalizeOcrJobIdInput(value);
|
|
69834
|
+
if (!OCR_JOB_ID_PATTERN.test(normalized)) {
|
|
69835
|
+
ctx.addIssue({
|
|
69836
|
+
code: "custom",
|
|
69837
|
+
message: "job id must be an opj_… id"
|
|
69838
|
+
});
|
|
69839
|
+
return exports_external.NEVER;
|
|
69840
|
+
}
|
|
69841
|
+
return normalized;
|
|
69842
|
+
});
|
|
69843
|
+
ExtractionPipelineIdInputSchema = exports_external.string().max(128).transform((value, ctx) => {
|
|
69844
|
+
const normalized = normalizeOcrPipelineIdInput(value);
|
|
69845
|
+
const parsed = ExtractionPipelineIdSchema.safeParse(normalized);
|
|
69846
|
+
if (!parsed.success) {
|
|
69847
|
+
ctx.addIssue({
|
|
69848
|
+
code: "custom",
|
|
69849
|
+
message: "pipeline_id must be an oppl_… id"
|
|
69850
|
+
});
|
|
69851
|
+
return exports_external.NEVER;
|
|
69852
|
+
}
|
|
69853
|
+
return parsed.data;
|
|
69854
|
+
});
|
|
69855
|
+
});
|
|
69856
|
+
|
|
69555
69857
|
// ../types/src/ocr/raw-result.ts
|
|
69556
69858
|
var OCR_OUTPUT_FORMATS, OcrOutputFormatSchema, PaddleRawProfileSchema, RawParseResultSchema;
|
|
69557
69859
|
var init_raw_result = __esm(() => {
|
|
@@ -69585,10 +69887,12 @@ var SUGGEST_SCHEMA_HINT_MAX_CHARS = 500, SUGGEST_SCHEMA_PREVIEW_MAX_PAGES = 2, S
|
|
|
69585
69887
|
var init_suggest_schema = __esm(() => {
|
|
69586
69888
|
init_zod();
|
|
69587
69889
|
init_extraction();
|
|
69890
|
+
init_id_compat();
|
|
69891
|
+
init_job_id();
|
|
69588
69892
|
init_llm_models();
|
|
69589
69893
|
SuggestSchemaHintSchema = exports_external.string().min(1).max(SUGGEST_SCHEMA_HINT_MAX_CHARS);
|
|
69590
69894
|
SuggestSchemaRequestSchema = exports_external.object({
|
|
69591
|
-
parse_job_id:
|
|
69895
|
+
parse_job_id: JobIdInputSchema,
|
|
69592
69896
|
hint: SuggestSchemaHintSchema.optional()
|
|
69593
69897
|
}).strict();
|
|
69594
69898
|
SuggestSchemaResponseSchema = exports_external.object({
|
|
@@ -69604,7 +69908,7 @@ var init_suggest_schema = __esm(() => {
|
|
|
69604
69908
|
SuggestSchemaTerminalResultSchema = exports_external.object({
|
|
69605
69909
|
name: exports_external.string().min(1).max(200),
|
|
69606
69910
|
schema: exports_external.record(exports_external.string(), exports_external.unknown()),
|
|
69607
|
-
parse_job_id:
|
|
69911
|
+
parse_job_id: JobIdSchema,
|
|
69608
69912
|
llm_model: LlmModelSchema,
|
|
69609
69913
|
reasoning_effort: OcrLlmReasoningEffortSchema.nullable().optional(),
|
|
69610
69914
|
hint: SuggestSchemaHintSchema.optional(),
|
|
@@ -69615,13 +69919,16 @@ var init_suggest_schema = __esm(() => {
|
|
|
69615
69919
|
});
|
|
69616
69920
|
|
|
69617
69921
|
// ../types/src/ocr/jobs.ts
|
|
69618
|
-
var OCR_OPENAPI_RELATIVE_PATH = "docs/OCR_API_OPENAPI.yaml", OCR_JOB_STATUSES, JobStatusSchema, OCR_JOB_OPERATIONS, JobOperationSchema, OCR_JOB_HISTORY_OPERATIONS, JobHistoryOperationSchema,
|
|
69922
|
+
var OCR_OPENAPI_RELATIVE_PATH = "docs/OCR_API_OPENAPI.yaml", OCR_JOB_STATUSES, JobStatusSchema, OCR_JOB_OPERATIONS, JobOperationSchema, OCR_JOB_HISTORY_OPERATIONS, JobHistoryOperationSchema, JobFailureSchema, JobAcceptedSchema, BatchJobAcceptedSchema, BatchChildSummarySchema, BatchChildPageSchema, BatchSummaryCountsSchema, JobProgressSchema, RelatedExtractionSummarySchema, JobSchema, OCR_JOB_LIST_DEFAULT_LIMIT = 25, OCR_JOB_LIST_MAX_LIMIT = 100, JobSummarySchema, JobListResponseSchema, JobListQuerySchema, ErrorBodySchema, ErrorResponseSchema, OCR_SYNC_STATUS_CODES;
|
|
69619
69923
|
var init_jobs = __esm(() => {
|
|
69620
69924
|
init_zod();
|
|
69621
69925
|
init_extraction();
|
|
69926
|
+
init_job_id();
|
|
69622
69927
|
init_parsed_document();
|
|
69928
|
+
init_pipelines();
|
|
69623
69929
|
init_raw_result();
|
|
69624
69930
|
init_suggest_schema();
|
|
69931
|
+
init_job_id();
|
|
69625
69932
|
OCR_JOB_STATUSES = [
|
|
69626
69933
|
"queued",
|
|
69627
69934
|
"running",
|
|
@@ -69645,7 +69952,6 @@ var init_jobs = __esm(() => {
|
|
|
69645
69952
|
"extract_batch"
|
|
69646
69953
|
];
|
|
69647
69954
|
JobHistoryOperationSchema = exports_external.enum(OCR_JOB_HISTORY_OPERATIONS);
|
|
69648
|
-
JobIdSchema = exports_external.string().uuid();
|
|
69649
69955
|
JobFailureSchema = exports_external.object({
|
|
69650
69956
|
code: exports_external.string().min(1),
|
|
69651
69957
|
message: exports_external.string().min(1),
|
|
@@ -69724,7 +70030,10 @@ var init_jobs = __esm(() => {
|
|
|
69724
70030
|
source_media_type: exports_external.string().min(1).nullable().optional(),
|
|
69725
70031
|
source_parse_job_id: JobIdSchema.nullable().optional(),
|
|
69726
70032
|
related_extractions: exports_external.array(RelatedExtractionSummarySchema).optional(),
|
|
69727
|
-
extraction_schema: exports_external.record(exports_external.string(), exports_external.unknown()).optional()
|
|
70033
|
+
extraction_schema: exports_external.record(exports_external.string(), exports_external.unknown()).optional(),
|
|
70034
|
+
ocr_model: exports_external.string().min(1).nullable().optional(),
|
|
70035
|
+
pipeline_id: ExtractionPipelineIdSchema.nullable(),
|
|
70036
|
+
pipeline_version: exports_external.number().int().min(1).nullable()
|
|
69728
70037
|
}).strict();
|
|
69729
70038
|
JobSummarySchema = exports_external.object({
|
|
69730
70039
|
id: JobIdSchema,
|
|
@@ -69739,7 +70048,9 @@ var init_jobs = __esm(() => {
|
|
|
69739
70048
|
error: JobFailureSchema.optional(),
|
|
69740
70049
|
has_result: exports_external.boolean(),
|
|
69741
70050
|
url: exports_external.string().min(1),
|
|
69742
|
-
has_source: exports_external.boolean().optional()
|
|
70051
|
+
has_source: exports_external.boolean().optional(),
|
|
70052
|
+
pipeline_id: ExtractionPipelineIdSchema.nullable(),
|
|
70053
|
+
pipeline_version: exports_external.number().int().min(1).nullable()
|
|
69743
70054
|
}).strict();
|
|
69744
70055
|
JobListResponseSchema = exports_external.object({
|
|
69745
70056
|
data: exports_external.array(JobSummarySchema),
|
|
@@ -69769,46 +70080,6 @@ var init_jobs = __esm(() => {
|
|
|
69769
70080
|
};
|
|
69770
70081
|
});
|
|
69771
70082
|
|
|
69772
|
-
// ../types/src/ocr/model-options.ts
|
|
69773
|
-
function applyPaddleOcrOptionDefaults(requested) {
|
|
69774
|
-
const source = requested && typeof requested === "object" ? requested : undefined;
|
|
69775
|
-
return {
|
|
69776
|
-
image_block_ocr: typeof source?.image_block_ocr === "boolean" ? source.image_block_ocr : PADDLE_OCR_OPTION_DEFAULTS.image_block_ocr,
|
|
69777
|
-
chart_recognition: typeof source?.chart_recognition === "boolean" ? source.chart_recognition : PADDLE_OCR_OPTION_DEFAULTS.chart_recognition,
|
|
69778
|
-
merge_layout_blocks: typeof source?.merge_layout_blocks === "boolean" ? source.merge_layout_blocks : PADDLE_OCR_OPTION_DEFAULTS.merge_layout_blocks
|
|
69779
|
-
};
|
|
69780
|
-
}
|
|
69781
|
-
var OcrFigureAssetsModeSchema, PaddleOcrOptionsRequestSchema, PaddleOcrOptionsEffectiveSchema, PADDLE_OCR_OPTION_DEFAULTS, OcrOptionsRequestSchema, OcrOptionsEffectiveSchema, LlmOptionsRequestSchema, LlmOptionsStoredSchema, OcrModelOptionCapabilitySchema;
|
|
69782
|
-
var init_model_options = __esm(() => {
|
|
69783
|
-
init_zod();
|
|
69784
|
-
init_llm_models();
|
|
69785
|
-
OcrFigureAssetsModeSchema = exports_external.enum(["none", "stored"]);
|
|
69786
|
-
PaddleOcrOptionsRequestSchema = exports_external.object({
|
|
69787
|
-
image_block_ocr: exports_external.boolean().optional(),
|
|
69788
|
-
chart_recognition: exports_external.boolean().optional(),
|
|
69789
|
-
merge_layout_blocks: exports_external.boolean().optional().describe("Merge nearby cross-column or staggered text regions before recognition. Defaults to false to preserve one-to-one text and bounding-box alignment.")
|
|
69790
|
-
}).strict();
|
|
69791
|
-
PaddleOcrOptionsEffectiveSchema = exports_external.object({
|
|
69792
|
-
image_block_ocr: exports_external.boolean(),
|
|
69793
|
-
chart_recognition: exports_external.boolean(),
|
|
69794
|
-
merge_layout_blocks: exports_external.boolean()
|
|
69795
|
-
}).strict();
|
|
69796
|
-
PADDLE_OCR_OPTION_DEFAULTS = {
|
|
69797
|
-
image_block_ocr: false,
|
|
69798
|
-
chart_recognition: true,
|
|
69799
|
-
merge_layout_blocks: false
|
|
69800
|
-
};
|
|
69801
|
-
OcrOptionsRequestSchema = PaddleOcrOptionsRequestSchema;
|
|
69802
|
-
OcrOptionsEffectiveSchema = PaddleOcrOptionsEffectiveSchema;
|
|
69803
|
-
LlmOptionsRequestSchema = exports_external.object({ reasoning_effort: OcrLlmReasoningEffortRequestSchema.optional() }).strict();
|
|
69804
|
-
LlmOptionsStoredSchema = exports_external.object({ reasoning_effort: OcrLlmReasoningEffortRequestSchema.nullable() }).strict();
|
|
69805
|
-
OcrModelOptionCapabilitySchema = exports_external.object({
|
|
69806
|
-
image_block_ocr: exports_external.boolean(),
|
|
69807
|
-
chart_recognition: exports_external.boolean(),
|
|
69808
|
-
merge_layout_blocks: exports_external.boolean()
|
|
69809
|
-
}).strict();
|
|
69810
|
-
});
|
|
69811
|
-
|
|
69812
70083
|
// ../types/src/ocr/ocr-models.ts
|
|
69813
70084
|
function getDefaultOcrModelId() {
|
|
69814
70085
|
const defaults = OCR_MODEL_CATALOG.filter((entry) => entry.is_default);
|
|
@@ -69889,105 +70160,6 @@ var init_ocr_models = __esm(() => {
|
|
|
69889
70160
|
];
|
|
69890
70161
|
});
|
|
69891
70162
|
|
|
69892
|
-
// ../types/src/ocr/pipelines.ts
|
|
69893
|
-
function refineExtractPipelineXor(value, ctx, options) {
|
|
69894
|
-
const hasPipeline = value.pipeline_id !== undefined;
|
|
69895
|
-
const presentInline = EXTRACT_INLINE_CONFIG_KEYS.filter((key) => value[key] !== undefined);
|
|
69896
|
-
const requireOcrModel = options?.requireOcrModel !== false;
|
|
69897
|
-
if (hasPipeline && presentInline.length > 0) {
|
|
69898
|
-
ctx.addIssue({
|
|
69899
|
-
code: "custom",
|
|
69900
|
-
message: "pipeline_inline_conflict",
|
|
69901
|
-
path: ["pipeline_id"]
|
|
69902
|
-
});
|
|
69903
|
-
return;
|
|
69904
|
-
}
|
|
69905
|
-
if (hasPipeline)
|
|
69906
|
-
return;
|
|
69907
|
-
if (requireOcrModel && value.ocr_model === undefined) {
|
|
69908
|
-
ctx.addIssue({ code: "custom", message: "Required", path: ["ocr_model"] });
|
|
69909
|
-
}
|
|
69910
|
-
if (value.llm_model === undefined) {
|
|
69911
|
-
ctx.addIssue({ code: "custom", message: "Required", path: ["llm_model"] });
|
|
69912
|
-
}
|
|
69913
|
-
if (value.schema === undefined) {
|
|
69914
|
-
ctx.addIssue({ code: "custom", message: "Required", path: ["schema"] });
|
|
69915
|
-
}
|
|
69916
|
-
}
|
|
69917
|
-
var ExtractionPipelineIdSchema, ExtractionPipelineNameSchema, ExtractionPipelineSlugSchema, PipelineConfigFields, CreateExtractionPipelineRequestSchema, UpdateExtractionPipelineRequestSchema, ExtractionPipelineSchema, ExtractionPipelineListResponseSchema, DeleteExtractionPipelineResponseSchema, EXTRACT_INLINE_CONFIG_KEYS;
|
|
69918
|
-
var init_pipelines = __esm(() => {
|
|
69919
|
-
init_zod();
|
|
69920
|
-
init_extraction();
|
|
69921
|
-
init_grounding();
|
|
69922
|
-
init_model_options();
|
|
69923
|
-
ExtractionPipelineIdSchema = exports_external.string().regex(/^oep_[A-Za-z0-9_-]+$/, "pipeline_id must be an oep_… id").max(128);
|
|
69924
|
-
ExtractionPipelineNameSchema = exports_external.string().trim().min(1).max(128);
|
|
69925
|
-
ExtractionPipelineSlugSchema = exports_external.string().trim().min(1).max(128).regex(/^[a-z0-9][a-z0-9_-]*$/, "slug must be lowercase alphanumeric with _ or -");
|
|
69926
|
-
PipelineConfigFields = {
|
|
69927
|
-
ocr_model: exports_external.string().min(1).max(128),
|
|
69928
|
-
ocr_options: OcrOptionsRequestSchema.optional(),
|
|
69929
|
-
llm_model: LlmModelSchema,
|
|
69930
|
-
llm_options: LlmOptionsRequestSchema.optional(),
|
|
69931
|
-
schema: exports_external.record(exports_external.string(), exports_external.unknown()),
|
|
69932
|
-
repair_attempts: exports_external.number().int().min(0).max(2).optional(),
|
|
69933
|
-
grounding: ExtractionGroundingModeSchema.optional()
|
|
69934
|
-
};
|
|
69935
|
-
CreateExtractionPipelineRequestSchema = exports_external.object({
|
|
69936
|
-
name: ExtractionPipelineNameSchema,
|
|
69937
|
-
slug: ExtractionPipelineSlugSchema.optional(),
|
|
69938
|
-
...PipelineConfigFields
|
|
69939
|
-
}).strict();
|
|
69940
|
-
UpdateExtractionPipelineRequestSchema = exports_external.object({
|
|
69941
|
-
name: ExtractionPipelineNameSchema.optional(),
|
|
69942
|
-
slug: ExtractionPipelineSlugSchema.nullable().optional(),
|
|
69943
|
-
ocr_model: PipelineConfigFields.ocr_model.optional(),
|
|
69944
|
-
ocr_options: OcrOptionsRequestSchema.nullable().optional(),
|
|
69945
|
-
llm_model: PipelineConfigFields.llm_model.optional(),
|
|
69946
|
-
llm_options: LlmOptionsRequestSchema.nullable().optional(),
|
|
69947
|
-
schema: PipelineConfigFields.schema.optional(),
|
|
69948
|
-
repair_attempts: exports_external.number().int().min(0).max(2).optional(),
|
|
69949
|
-
grounding: ExtractionGroundingModeSchema.optional()
|
|
69950
|
-
}).strict().superRefine((value, ctx) => {
|
|
69951
|
-
if (Object.keys(value).length === 0) {
|
|
69952
|
-
ctx.addIssue({
|
|
69953
|
-
code: "custom",
|
|
69954
|
-
message: "at least one field is required"
|
|
69955
|
-
});
|
|
69956
|
-
}
|
|
69957
|
-
});
|
|
69958
|
-
ExtractionPipelineSchema = exports_external.object({
|
|
69959
|
-
id: ExtractionPipelineIdSchema,
|
|
69960
|
-
name: ExtractionPipelineNameSchema,
|
|
69961
|
-
slug: ExtractionPipelineSlugSchema.nullable(),
|
|
69962
|
-
version: exports_external.number().int().min(1),
|
|
69963
|
-
ocr_model: exports_external.string().min(1).max(128),
|
|
69964
|
-
ocr_options: OcrOptionsEffectiveSchema,
|
|
69965
|
-
llm_model: LlmModelSchema,
|
|
69966
|
-
llm_options: LlmOptionsStoredSchema,
|
|
69967
|
-
schema: exports_external.record(exports_external.string(), exports_external.unknown()),
|
|
69968
|
-
repair_attempts: exports_external.number().int().min(0).max(2),
|
|
69969
|
-
grounding: ExtractionGroundingModeSchema,
|
|
69970
|
-
created_at: exports_external.string().datetime(),
|
|
69971
|
-
updated_at: exports_external.string().datetime()
|
|
69972
|
-
}).strict();
|
|
69973
|
-
ExtractionPipelineListResponseSchema = exports_external.object({
|
|
69974
|
-
items: exports_external.array(ExtractionPipelineSchema)
|
|
69975
|
-
}).strict();
|
|
69976
|
-
DeleteExtractionPipelineResponseSchema = exports_external.object({
|
|
69977
|
-
deleted: exports_external.literal(true),
|
|
69978
|
-
id: ExtractionPipelineIdSchema
|
|
69979
|
-
}).strict();
|
|
69980
|
-
EXTRACT_INLINE_CONFIG_KEYS = [
|
|
69981
|
-
"ocr_model",
|
|
69982
|
-
"ocr_options",
|
|
69983
|
-
"llm_model",
|
|
69984
|
-
"llm_options",
|
|
69985
|
-
"schema",
|
|
69986
|
-
"repair_attempts",
|
|
69987
|
-
"grounding"
|
|
69988
|
-
];
|
|
69989
|
-
});
|
|
69990
|
-
|
|
69991
70163
|
// ../types/src/ocr/contracts.ts
|
|
69992
70164
|
function requireExactlyOneSource(item, ctx) {
|
|
69993
70165
|
const hasIndex = item.file_index !== undefined;
|
|
@@ -70014,6 +70186,7 @@ var init_contracts = __esm(() => {
|
|
|
70014
70186
|
init_zod();
|
|
70015
70187
|
init_extraction();
|
|
70016
70188
|
init_grounding();
|
|
70189
|
+
init_id_compat();
|
|
70017
70190
|
init_jobs();
|
|
70018
70191
|
init_llm_models();
|
|
70019
70192
|
init_model_options();
|
|
@@ -70035,7 +70208,7 @@ var init_contracts = __esm(() => {
|
|
|
70035
70208
|
output_format: OcrOutputFormatSchema.default("openparser@1")
|
|
70036
70209
|
}).strict();
|
|
70037
70210
|
ExtractRequestSchema = exports_external.object({
|
|
70038
|
-
pipeline_id:
|
|
70211
|
+
pipeline_id: ExtractionPipelineIdInputSchema.optional(),
|
|
70039
70212
|
ocr_model: OcrModelSchema.optional(),
|
|
70040
70213
|
ocr_options: OcrOptionsRequestSchema.optional(),
|
|
70041
70214
|
llm_model: LlmModelSchema.optional(),
|
|
@@ -70044,7 +70217,7 @@ var init_contracts = __esm(() => {
|
|
|
70044
70217
|
repair_attempts: exports_external.number().int().min(0).max(2).optional(),
|
|
70045
70218
|
grounding: ExtractionGroundingModeSchema.optional(),
|
|
70046
70219
|
file_id: OcrFileIdSchema.optional(),
|
|
70047
|
-
parse_job_id:
|
|
70220
|
+
parse_job_id: JobIdInputSchema.optional(),
|
|
70048
70221
|
output_format: OcrOutputFormatSchema.default("openparser@1")
|
|
70049
70222
|
}).strict().superRefine((value, ctx) => {
|
|
70050
70223
|
if (value.file_id !== undefined && value.parse_job_id !== undefined) {
|
|
@@ -70101,7 +70274,7 @@ var init_contracts = __esm(() => {
|
|
|
70101
70274
|
client_item_id: exports_external.string().min(1).max(128),
|
|
70102
70275
|
file_index: exports_external.number().int().min(0).optional(),
|
|
70103
70276
|
file_id: OcrFileIdSchema.optional(),
|
|
70104
|
-
pipeline_id:
|
|
70277
|
+
pipeline_id: ExtractionPipelineIdInputSchema.optional(),
|
|
70105
70278
|
ocr_model: OcrModelSchema.optional(),
|
|
70106
70279
|
ocr_options: OcrOptionsRequestSchema.optional(),
|
|
70107
70280
|
llm_model: LlmModelSchema.optional(),
|
|
@@ -70600,6 +70773,7 @@ var init_request_examples = __esm(() => {
|
|
|
70600
70773
|
// ../types/src/ocr/index.ts
|
|
70601
70774
|
var init_ocr = __esm(() => {
|
|
70602
70775
|
init_parsed_document();
|
|
70776
|
+
init_id_compat();
|
|
70603
70777
|
init_contracts();
|
|
70604
70778
|
init_llm_models();
|
|
70605
70779
|
init_model_options();
|
|
@@ -71011,10 +71185,12 @@ __export(exports_src, {
|
|
|
71011
71185
|
resolveAgentOriginalSourceRef: () => resolveAgentOriginalSourceRef,
|
|
71012
71186
|
requiresSpecializedParser: () => requiresSpecializedParser,
|
|
71013
71187
|
requireOcrModelUsdPerPage: () => requireOcrModelUsdPerPage,
|
|
71188
|
+
refinePipelineExtractionSchema: () => refinePipelineExtractionSchema,
|
|
71014
71189
|
refineExtractPipelineXor: () => refineExtractPipelineXor,
|
|
71015
71190
|
redactFileSourceSecrets: () => redactFileSourceSecrets,
|
|
71016
71191
|
publicExecutionFailure: () => publicExecutionFailure,
|
|
71017
71192
|
projectAgentInputFiles: () => projectAgentInputFiles,
|
|
71193
|
+
pipelineExtractionSchemaRootPropertyCount: () => pipelineExtractionSchemaRootPropertyCount,
|
|
71018
71194
|
pathToDottedPackageName: () => pathToDottedPackageName,
|
|
71019
71195
|
parseWorkflowRerunVersion: () => parseWorkflowRerunVersion,
|
|
71020
71196
|
parseStepType: () => parseStepType,
|
|
@@ -71026,10 +71202,15 @@ __export(exports_src, {
|
|
|
71026
71202
|
parseFailureEnvelope: () => parseFailureEnvelope,
|
|
71027
71203
|
parseAutomationTarget: () => parseAutomationTarget,
|
|
71028
71204
|
parseAgentRerunVersion: () => parseAgentRerunVersion,
|
|
71205
|
+
ocrPipelineIdLookupCandidates: () => ocrPipelineIdLookupCandidates,
|
|
71206
|
+
ocrJobIdLookupCandidates: () => ocrJobIdLookupCandidates,
|
|
71207
|
+
normalizeOcrPipelineIdInput: () => normalizeOcrPipelineIdInput,
|
|
71208
|
+
normalizeOcrJobIdInput: () => normalizeOcrJobIdInput,
|
|
71029
71209
|
normalizeLegacyFileIdInput: () => normalizeLegacyFileIdInput,
|
|
71030
71210
|
normalizeExtractInputToText: () => normalizeExtractInputToText,
|
|
71031
71211
|
noopTracingContext: () => noopTracingContext,
|
|
71032
71212
|
mimeTypeForExtension: () => mimeTypeForExtension,
|
|
71213
|
+
migratedOcrJobIdFromUuid: () => migratedOcrJobIdFromUuid,
|
|
71033
71214
|
matchS3Path: () => matchS3Path,
|
|
71034
71215
|
mapOCRAttributes: () => mapOCRAttributes,
|
|
71035
71216
|
mapLLMAttributes: () => mapLLMAttributes,
|
|
@@ -71037,6 +71218,8 @@ __export(exports_src, {
|
|
|
71037
71218
|
listStepTypesByCategory: () => listStepTypesByCategory,
|
|
71038
71219
|
listStepTypes: () => listStepTypes,
|
|
71039
71220
|
listProcessorIds: () => listProcessorIds,
|
|
71221
|
+
legacyUuidFromMigratedOcrJobId: () => legacyUuidFromMigratedOcrJobId,
|
|
71222
|
+
legacyOepFromMigratedOcrPipelineId: () => legacyOepFromMigratedOcrPipelineId,
|
|
71040
71223
|
judgeScoreJson: () => judgeScoreJson,
|
|
71041
71224
|
judgeLabelJson: () => judgeLabelJson,
|
|
71042
71225
|
isWorkflowResult: () => isWorkflowResult,
|
|
@@ -71049,7 +71232,9 @@ __export(exports_src, {
|
|
|
71049
71232
|
isRunInSampleRank: () => isRunInSampleRank,
|
|
71050
71233
|
isRunExpandSection: () => isRunExpandSection,
|
|
71051
71234
|
isResolvedProcessorFile: () => isResolvedProcessorFile,
|
|
71235
|
+
isPreferredOcrJobId: () => isPreferredOcrJobId,
|
|
71052
71236
|
isOutputSchemaUnknown: () => isOutputSchemaUnknown,
|
|
71237
|
+
isOcrJobIdInput: () => isOcrJobIdInput,
|
|
71053
71238
|
isNonSuccessTerminalExecutionStatus: () => isNonSuccessTerminalExecutionStatus,
|
|
71054
71239
|
isManualTriggerEnabled: () => isManualTriggerEnabled,
|
|
71055
71240
|
isLocalAgentResourcePath: () => isLocalAgentResourcePath,
|
|
@@ -71063,6 +71248,7 @@ __export(exports_src, {
|
|
|
71063
71248
|
isAgentEmailExplicitlyDisabled: () => isAgentEmailExplicitlyDisabled,
|
|
71064
71249
|
inputsWithSource: () => inputsWithSource,
|
|
71065
71250
|
hasTriggerMethod: () => hasTriggerMethod,
|
|
71251
|
+
hasPipelineExtractionSchemaProperties: () => hasPipelineExtractionSchemaProperties,
|
|
71066
71252
|
hasDeclaredOutput: () => hasDeclaredOutput,
|
|
71067
71253
|
goldenFileSatisfiedInResult: () => goldenFileSatisfiedInResult,
|
|
71068
71254
|
getWebhookDestinationUrlError: () => getWebhookDestinationUrlError,
|
|
@@ -71315,6 +71501,7 @@ __export(exports_src, {
|
|
|
71315
71501
|
PositionedTextSchema: () => PositionedTextSchema,
|
|
71316
71502
|
PolygonSchema: () => PolygonSchema,
|
|
71317
71503
|
PointSchema: () => PointSchema,
|
|
71504
|
+
PipelineExtractionSchemaObjectSchema: () => PipelineExtractionSchemaObjectSchema,
|
|
71318
71505
|
PdfEmbedderOutputSchema: () => PdfEmbedderOutputSchema,
|
|
71319
71506
|
PdfEmbedderInputSchema: () => PdfEmbedderInputSchema,
|
|
71320
71507
|
PdfEmbedderConfigSchema: () => PdfEmbedderConfigSchema,
|
|
@@ -71341,6 +71528,7 @@ __export(exports_src, {
|
|
|
71341
71528
|
PROVIDER_LOGO_DATA: () => PROVIDER_LOGO_DATA,
|
|
71342
71529
|
PROCESSOR_SCHEMAS: () => PROCESSOR_SCHEMAS,
|
|
71343
71530
|
PROCESSOR_IDS: () => PROCESSOR_IDS,
|
|
71531
|
+
PIPELINE_EXTRACTION_SCHEMA_EMPTY_PROPERTIES_MESSAGE: () => PIPELINE_EXTRACTION_SCHEMA_EMPTY_PROPERTIES_MESSAGE,
|
|
71344
71532
|
PENDING_FILE_REF: () => PENDING_FILE_REF,
|
|
71345
71533
|
PARSER_IDS: () => PARSER_IDS,
|
|
71346
71534
|
PAGE_BLOCK_KINDS: () => PAGE_BLOCK_KINDS,
|
|
@@ -71399,6 +71587,8 @@ __export(exports_src, {
|
|
|
71399
71587
|
OCR_JOB_OPERATIONS: () => OCR_JOB_OPERATIONS,
|
|
71400
71588
|
OCR_JOB_LIST_MAX_LIMIT: () => OCR_JOB_LIST_MAX_LIMIT,
|
|
71401
71589
|
OCR_JOB_LIST_DEFAULT_LIMIT: () => OCR_JOB_LIST_DEFAULT_LIMIT,
|
|
71590
|
+
OCR_JOB_ID_PREFIX: () => OCR_JOB_ID_PREFIX,
|
|
71591
|
+
OCR_JOB_ID_PATTERN: () => OCR_JOB_ID_PATTERN,
|
|
71402
71592
|
OCR_JOB_HISTORY_OPERATIONS: () => OCR_JOB_HISTORY_OPERATIONS,
|
|
71403
71593
|
NON_SUCCESS_TERMINAL_EXECUTION_STATUSES: () => NON_SUCCESS_TERMINAL_EXECUTION_STATUSES,
|
|
71404
71594
|
MergeOutputSchema: () => MergeOutputSchema,
|
|
@@ -71420,6 +71610,8 @@ __export(exports_src, {
|
|
|
71420
71610
|
LayoutElementSchema: () => LayoutElementSchema,
|
|
71421
71611
|
LLM_JUDGE_PROMPT_MIN_LENGTH: () => LLM_JUDGE_PROMPT_MIN_LENGTH,
|
|
71422
71612
|
LEGACY_RUN_EXPAND_MIGRATION: () => LEGACY_RUN_EXPAND_MIGRATION,
|
|
71613
|
+
LEGACY_OCR_PIPELINE_ID_PREFIX: () => LEGACY_OCR_PIPELINE_ID_PREFIX,
|
|
71614
|
+
LEGACY_OCR_JOB_UUID_PATTERN: () => LEGACY_OCR_JOB_UUID_PATTERN,
|
|
71423
71615
|
LEGACY_FILE_REF_COMPATIBILITY: () => LEGACY_FILE_REF_COMPATIBILITY,
|
|
71424
71616
|
JudgeModeSchema: () => JudgeModeSchema,
|
|
71425
71617
|
JsonSchemaSchema: () => JsonSchemaSchema,
|
|
@@ -71431,6 +71623,7 @@ __export(exports_src, {
|
|
|
71431
71623
|
JobListResponseSchema: () => JobListResponseSchema,
|
|
71432
71624
|
JobListQuerySchema: () => JobListQuerySchema,
|
|
71433
71625
|
JobIdSchema: () => JobIdSchema,
|
|
71626
|
+
JobIdInputSchema: () => JobIdInputSchema,
|
|
71434
71627
|
JobHistoryOperationSchema: () => JobHistoryOperationSchema,
|
|
71435
71628
|
JobFailureSchema: () => JobFailureSchema,
|
|
71436
71629
|
JobAcceptedSchema: () => JobAcceptedSchema,
|
|
@@ -71458,6 +71651,7 @@ __export(exports_src, {
|
|
|
71458
71651
|
ExtractionPipelineNameSchema: () => ExtractionPipelineNameSchema,
|
|
71459
71652
|
ExtractionPipelineListResponseSchema: () => ExtractionPipelineListResponseSchema,
|
|
71460
71653
|
ExtractionPipelineIdSchema: () => ExtractionPipelineIdSchema,
|
|
71654
|
+
ExtractionPipelineIdInputSchema: () => ExtractionPipelineIdInputSchema,
|
|
71461
71655
|
ExtractionJsonSchemaObjectSchema: () => ExtractionJsonSchemaObjectSchema,
|
|
71462
71656
|
ExtractionGroundingResultSchema: () => ExtractionGroundingResultSchema,
|
|
71463
71657
|
ExtractionGroundingModeSchema: () => ExtractionGroundingModeSchema,
|
|
@@ -186344,7 +186538,7 @@ import { fileURLToPath as fileURLToPath9 } from "url";
|
|
|
186344
186538
|
// package.json
|
|
186345
186539
|
var package_default = {
|
|
186346
186540
|
name: "@eigenpal/cli",
|
|
186347
|
-
version: "0.10.
|
|
186541
|
+
version: "0.10.38",
|
|
186348
186542
|
description: "Eigenpal CLI — author and run document workflows from your terminal. Agent-ready.",
|
|
186349
186543
|
keywords: [
|
|
186350
186544
|
"eigenpal",
|
|
@@ -191250,7 +191444,7 @@ function preview(value) {
|
|
|
191250
191444
|
text = String(value);
|
|
191251
191445
|
return text.length > MAX_VALUE_LEN ? `${text.slice(0, MAX_VALUE_LEN)}…` : text;
|
|
191252
191446
|
}
|
|
191253
|
-
function
|
|
191447
|
+
function isPlainObject4(value) {
|
|
191254
191448
|
return value !== null && typeof value === "object" && !Array.isArray(value);
|
|
191255
191449
|
}
|
|
191256
191450
|
function joinPath(path15, key2) {
|
|
@@ -191271,8 +191465,8 @@ function walk(expected, actual, path15, diffs) {
|
|
|
191271
191465
|
}
|
|
191272
191466
|
return;
|
|
191273
191467
|
}
|
|
191274
|
-
if (
|
|
191275
|
-
if (!
|
|
191468
|
+
if (isPlainObject4(expected)) {
|
|
191469
|
+
if (!isPlainObject4(actual)) {
|
|
191276
191470
|
diffs.push(`${path15 || "(root)"}: expected object, got ${preview(actual)}`);
|
|
191277
191471
|
return;
|
|
191278
191472
|
}
|