@docmana/sdk 0.36.0-hitl.2 → 0.37.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 +19 -0
- package/LICENSE +21 -21
- package/README.md +27 -1
- package/dist/cli.mjs +33 -6
- package/dist/cli.mjs.map +1 -1
- package/dist/errors.d.ts +17 -5
- package/dist/index.d.ts +2 -1
- package/dist/index.js +33 -6
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +33 -6
- package/dist/index.mjs.map +1 -1
- package/dist/reviews.d.ts +27 -1
- package/package.json +1 -1
package/dist/reviews.d.ts
CHANGED
|
@@ -62,6 +62,18 @@ export interface ReviewItem {
|
|
|
62
62
|
nodeName: string;
|
|
63
63
|
field: string;
|
|
64
64
|
value: unknown;
|
|
65
|
+
origin?: "proposed" | "confirmed" | "corrected";
|
|
66
|
+
originalValue?: unknown;
|
|
67
|
+
}
|
|
68
|
+
/** Captured node outputs. Downstream and dossier results are read-only. */
|
|
69
|
+
export interface ReviewStep {
|
|
70
|
+
nodeId: string;
|
|
71
|
+
nodeName: string | null;
|
|
72
|
+
nodeType: string;
|
|
73
|
+
documentType?: string;
|
|
74
|
+
status: "provisional" | "failed" | "notExecuted";
|
|
75
|
+
score?: number;
|
|
76
|
+
items?: ReviewItem[];
|
|
65
77
|
}
|
|
66
78
|
export interface ReviewDocument {
|
|
67
79
|
docKey: string;
|
|
@@ -78,7 +90,9 @@ export interface ReviewDocument {
|
|
|
78
90
|
pagesComplete?: boolean;
|
|
79
91
|
contentUrl?: string;
|
|
80
92
|
items?: ReviewItem[];
|
|
93
|
+
/** Upstream fields/classifications may be corrected via continue; Core validates eligibility. */
|
|
81
94
|
context?: ReviewItem[];
|
|
95
|
+
downstream?: ReviewStep[];
|
|
82
96
|
/** Read-only evidence from the frozen pause; absent on older backends. */
|
|
83
97
|
assessments?: ReviewAssessment[];
|
|
84
98
|
}
|
|
@@ -107,10 +121,16 @@ export interface ReviewSummary {
|
|
|
107
121
|
nodeType: string | null;
|
|
108
122
|
instructions?: string;
|
|
109
123
|
};
|
|
110
|
-
|
|
124
|
+
/** The pending-list envelope omits document data. Read the selected task for it. */
|
|
125
|
+
documents?: ReviewDocument[];
|
|
111
126
|
level?: "dossier";
|
|
127
|
+
priority?: "low" | "normal" | "high" | "urgent" | null;
|
|
128
|
+
waitingSince?: string | null;
|
|
112
129
|
}
|
|
113
130
|
export interface ReviewTask extends ReviewSummary {
|
|
131
|
+
documents: ReviewDocument[];
|
|
132
|
+
dossierContext?: Record<string, unknown>;
|
|
133
|
+
dossierResults?: ReviewStep[];
|
|
114
134
|
/** Explicit frozen field signals. Missing/empty keeps legacy UI and global confirmation. */
|
|
115
135
|
findings?: ReviewFinding[];
|
|
116
136
|
/** Native lifecycle timestamps, absent on older backends; never inferred from callbacks. */
|
|
@@ -130,10 +150,15 @@ export interface ReviewDecision {
|
|
|
130
150
|
decision: "continue" | "exclude" | "rerun" | "reject";
|
|
131
151
|
reviewer: string;
|
|
132
152
|
version: number;
|
|
153
|
+
/** Current items or upstream context fields/classifications, never downstream/status items. */
|
|
133
154
|
corrections?: Array<{
|
|
134
155
|
itemId: string;
|
|
135
156
|
value: unknown;
|
|
157
|
+
reason?: string;
|
|
136
158
|
}>;
|
|
159
|
+
/** Confirmations are limited to the current node's items. */
|
|
160
|
+
confirmations?: string[];
|
|
161
|
+
durationSeconds?: number;
|
|
137
162
|
excludedDocuments?: string[];
|
|
138
163
|
rerunDocuments?: string[];
|
|
139
164
|
hint?: string;
|
|
@@ -160,6 +185,7 @@ export declare class Reviews {
|
|
|
160
185
|
/** Published formula structure only. Compare its version with the review's flowVersion. */
|
|
161
186
|
outline(flowId: string, options: ReviewReadOptions): Promise<ReviewFlowOutline>;
|
|
162
187
|
list(options: ReviewReadOptions & {
|
|
188
|
+
/** The native API serves pending only. Other values are retained for older POC callers. */
|
|
163
189
|
status?: "pending" | "submitted" | "resuming";
|
|
164
190
|
cursor?: string;
|
|
165
191
|
limit?: number;
|