@docmana/sdk 0.37.0 → 0.39.0
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 +9 -0
- package/README.md +24 -0
- package/dist/authoring.d.ts +20 -0
- package/dist/cli.mjs +14 -0
- package/dist/cli.mjs.map +1 -1
- package/dist/index.d.ts +3 -3
- package/dist/index.js +14 -0
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +14 -0
- package/dist/index.mjs.map +1 -1
- package/dist/models/docmana-extraction-result.model.d.ts +30 -1
- package/dist/reviews.d.ts +14 -0
- package/dist/types.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,3 +1,32 @@
|
|
|
1
|
-
import { DocmanaNodeResult } from "./docmana-node-result.model.js";
|
|
1
|
+
import type { DocmanaNodeResult } from "./docmana-node-result.model.js";
|
|
2
|
+
export type GroundingOrigin = "LITERAL" | "DERIVED" | "INFERRED" | "UNSUPPORTED" | "UNVERIFIED" | "HUMAN_CORRECTED";
|
|
3
|
+
/** Page fractions, measured from the top left. */
|
|
4
|
+
export type GroundingBox = [x0: number, y0: number, x1: number, y1: number];
|
|
5
|
+
export interface DocmanaGroundingEvidence {
|
|
6
|
+
/** One-based page of the submitted file, or of the PDF generated for grouped images. */
|
|
7
|
+
page: number;
|
|
8
|
+
boxes: GroundingBox[];
|
|
9
|
+
}
|
|
10
|
+
export interface DocmanaGroundingTool {
|
|
11
|
+
tool: string;
|
|
12
|
+
/** Zero-based call index within the extraction step. */
|
|
13
|
+
call: number;
|
|
14
|
+
}
|
|
15
|
+
export interface DocmanaGroundingField {
|
|
16
|
+
/** JSON Pointer into the extraction step's data. */
|
|
17
|
+
path: string;
|
|
18
|
+
origin: GroundingOrigin;
|
|
19
|
+
probability: number | null;
|
|
20
|
+
evidence: DocmanaGroundingEvidence[];
|
|
21
|
+
/** Absent on older servers. A tool-only value can have no page evidence. */
|
|
22
|
+
tools?: DocmanaGroundingTool[];
|
|
23
|
+
}
|
|
24
|
+
export interface DocmanaGrounding {
|
|
25
|
+
version: number;
|
|
26
|
+
error: string | null;
|
|
27
|
+
fields: DocmanaGroundingField[];
|
|
28
|
+
}
|
|
2
29
|
export interface DocmanaExtractionResult extends DocmanaNodeResult {
|
|
30
|
+
/** Present when the server produced grounding for this extraction step. */
|
|
31
|
+
grounding?: DocmanaGrounding;
|
|
3
32
|
}
|
package/dist/reviews.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { HttpClient } from "./http/http-client.js";
|
|
2
|
+
import type { GroundingBox, GroundingOrigin } from "./models/docmana-extraction-result.model.js";
|
|
2
3
|
import type { ExecutionStatus } from "./models/execution-status.enum.js";
|
|
3
4
|
export interface ReviewCalculation {
|
|
4
5
|
executionResultId: string;
|
|
@@ -176,6 +177,19 @@ export interface ReviewDocumentOptions extends ReviewReadOptions {
|
|
|
176
177
|
ifNoneMatch?: string;
|
|
177
178
|
ifModifiedSince?: string;
|
|
178
179
|
}
|
|
180
|
+
export interface ReviewLocation {
|
|
181
|
+
/** JSON Pointer relative to the item value, or empty for the value itself. */
|
|
182
|
+
path: string;
|
|
183
|
+
origin: Exclude<GroundingOrigin, "HUMAN_CORRECTED">;
|
|
184
|
+
probability: number | null;
|
|
185
|
+
/** One-based page of the reviewed document, as used by the preview images. */
|
|
186
|
+
page: number;
|
|
187
|
+
boxes: GroundingBox[];
|
|
188
|
+
}
|
|
189
|
+
export interface ReviewLocationsResponse {
|
|
190
|
+
/** Locations keyed by review item ID. Items without page evidence are omitted. */
|
|
191
|
+
locations: Record<string, ReviewLocation[]>;
|
|
192
|
+
}
|
|
179
193
|
/** Human review of a formula execution. Independent of pipelines and final callbacks. */
|
|
180
194
|
export declare class Reviews {
|
|
181
195
|
private readonly http;
|
package/dist/types.d.ts
CHANGED
|
@@ -277,7 +277,7 @@ export type { DocmanaCrossValidationResult } from "./models/docmana-cross-valida
|
|
|
277
277
|
export type { DocmanaConclusionResult } from "./models/docmana-conclusion-result.model.js";
|
|
278
278
|
export type { DocmanaClassificationResult } from "./models/docmana-classification-result.model.js";
|
|
279
279
|
export type { DocmanaMetadataExtractionResult } from "./models/docmana-metadata-extraction-result.model.js";
|
|
280
|
-
export type { DocmanaExtractionResult } from "./models/docmana-extraction-result.model.js";
|
|
280
|
+
export type { DocmanaExtractionResult, DocmanaGrounding, DocmanaGroundingEvidence, DocmanaGroundingField, DocmanaGroundingTool, GroundingBox, GroundingOrigin, } from "./models/docmana-extraction-result.model.js";
|
|
281
281
|
export type { DocmanaValidationResult } from "./models/docmana-validation-result.model.js";
|
|
282
282
|
export type { DocmanaPreprocessingResult } from "./models/docmana-preprocessing-result.model.js";
|
|
283
283
|
export type { PartialExecutionFlowVersion, PartialExecutionMetadata, PartialExecutionScope, } from "./models/partial-execution-metadata.model.js";
|