Skip to content

Interface: DocumentResult

@kortexya/reasoninglayer


@kortexya/reasoninglayer / DocumentResult

Defined in: src/types/documents.ts:177

Per-document analysis result.

complianceScore: number | null

Defined in: src/types/documents.ts:192

Compliance score for this document (0.0-1.0): the passed share of its applicable rules.

null when no applicable rule was evaluated, and null when the document was truncated (DocumentEvaluatedText.truncated): no pass can stand on a truncated window, so a passed share there measures nothing.


optional detectedType?: string | null

Defined in: src/types/documents.ts:181

Detected document type (sort name in the KB), if any.


documentName: string

Defined in: src/types/documents.ts:179

Document name.


optional evaluatedText?: DocumentEvaluatedText

Defined in: src/types/documents.ts:208

The part of the document that extraction and every rule evaluation read. Absent from an engine that predates it. When truncated is true, show that only the first evaluatedChars of totalChars characters were read.


extractedEntities: DocumentExtractedEntity[]

Defined in: src/types/documents.ts:196

Entities extracted from the document.


ruleResults: DocumentRuleResult[]

Defined in: src/types/documents.ts:194

Per-rule results.


summary: string

Defined in: src/types/documents.ts:202

The engine’s deterministic summary of the result: the count of rules per status, the withheld verdicts, the critical failures and the reason for the score. No LLM writes it.