Skip to content

Interface: CoherenceAnalyzeRequest

@kortexya/reasoninglayer


@kortexya/reasoninglayer / CoherenceAnalyzeRequest

Defined in: src/types/coherence.ts:59

Request to analyze the coherence of a set of claims.

The claims are sourced by exactly one of, in descending precedence: termIds (explicit claim Ψ-term ids, in reading order), documentId (an already-ingested document), or document (inline content to ingest first).

Any rulesOsfql is compiled into an ephemeral analysis KB — never into the tenant KB.

const request: CoherenceAnalyzeRequest = {
documentId: '3f2b1c00-0000-0000-0000-000000000000',
enableDerivation: true,
matchThreshold: 0.7,
};

optional document?: CoherenceInlineDocumentDto | null

Defined in: src/types/coherence.ts:63

…or inline content to ingest first (clause extraction needs an LLM).


optional documentId?: string | null

Defined in: src/types/coherence.ts:61

Already-ingested document id whose clause Ψ-terms are analyzed.


optional enableDerivation?: boolean

Defined in: src/types/coherence.ts:75

Run the rule-derivation layer (chains and proofs).

true

optional matchThreshold?: number | null

Defined in: src/types/coherence.ts:70

Pairwise co-reference threshold (clamped server-side to 0.1..=1.0).

0.7

optional rulesOsfql?: string | null

Defined in: src/types/coherence.ts:80

Extra inline OSFQL (DERIVE … WHEN …;, optional DEFINE/INSERT), compiled into the ephemeral analysis KB — never into the tenant KB.


optional termIds?: string[] | null

Defined in: src/types/coherence.ts:65

Explicit claim term ids, in reading order (highest precedence).


optional useTenantRules?: boolean

Defined in: src/types/coherence.ts:86

Consult the tenant KB’s homoiconic rules in the derivation layer. Rules ARE the tenant’s declared constraints; an empty rule set degrades gracefully.

true

optional withEmbeddings?: boolean

Defined in: src/types/coherence.ts:92

Compute claim embeddings server-side for the ADVISORY layer (cosine scores on links; never certifying). Costs one embed_batch call.

false