export declare const SUBMISSION_ISSUE_CODES: readonly ["submission_missing", "submission_malformed", "submission_contract_invalid", "submission_rejected", "duplicate_submission_id"]; export type SubmissionIssueCode = (typeof SUBMISSION_ISSUE_CODES)[number]; /** * One classified failure. `TCode` widens for a draw that adds its own domain * codes; the base parameterization is the shared vocabulary above — see * `RemediationIssueCode` and the audit ingest's `AuditIngestIssueCode`, each of * which extends this union on its own side rather than pulling its vocabulary * in here. * * Two optional locators, because a submission is identified differently on the * two lanes it can arrive through: an expected-set member is named by * `submission_id` + `submission_path`, and a host work item by `work_item_id` + * `result_path` (the field name its own persisted contract already uses). */ export interface SubmissionIssue { readonly code: TCode; readonly message: string; readonly submission_id?: string; readonly submission_path?: string; readonly work_item_id?: string; readonly result_path?: string; } /** The three-way read every gate narrows on — never a throw out of one lane. */ export type SubmissionReadOutcome = { readonly kind: "missing"; } | { readonly kind: "malformed"; readonly detail: string; } | { readonly kind: "value"; readonly value: unknown; }; /** * Read the bytes at a bound path and classify the outcome. A file that is not * there and a file that will not parse are DIFFERENT answers; every other IO * failure reads as malformed rather than escaping, so one unreadable lane can * never destroy a sibling lane's already-consumed work. */ export declare function readSubmissionDocument(absolutePath: string): Promise; /** Where a classified read came from, for the issue's message and locators. */ export interface SubmissionReadContext { readonly submissionId: string; readonly lane: string; readonly submissionPath: string; } /** * Turn a non-`value` read into the issue that names it, or `null` when the * submission arrived. Lane vocabulary throughout: a member is a lane. */ export declare function classifyRead(outcome: SubmissionReadOutcome, context: SubmissionReadContext): SubmissionIssue | null; //# sourceMappingURL=submissionClassifier.d.ts.map