Skip to content

Interface: ConformanceViolationDto

@kortexya/reasoninglayer


@kortexya/reasoninglayer / ConformanceViolationDto

Defined in: src/types/conformance.ts:112

One domain/range violation POST /api/v1/conformance/check detected.

The engine publishes it as its own ConformanceViolationDto component. It is not the generation area’s ViolationDto (description, relatedFactId, severity), with which it shares no key.

const violation: ConformanceViolationDto = {
subject: 'urn:osfkb:cef5152a-…',
object: 'urn:osfkb:b4b76306-…',
feature: 'worksFor',
subjectSort: 'Company',
objectSort: 'Person',
kind: 'v1-inversion',
suggestedFixes: [{ action: 'swap' }],
};

feature: string

Defined in: src/types/conformance.ts:118

The feature (predicate) whose declared domain/range was violated.


kind: string

Defined in: src/types/conformance.ts:135

The diagnosed pattern — v1-inversion, v2-wrong-feature or v3-underspecified-type.

Typed as an open string, not a closed union: a kind the engine adds later must reach the caller rather than be refused by the SDK.

Note the HYPHENS. ViolationCountsDto keys the same three kinds with underscores (v1_inversion on the wire), because they are object keys there and a value here.


object: string

Defined in: src/types/conformance.ts:116

Identity of the violating triple’s object.


objectSort: string

Defined in: src/types/conformance.ts:122

The sort the object actually has.


subject: string

Defined in: src/types/conformance.ts:114

Identity of the violating triple’s subject.


subjectSort: string

Defined in: src/types/conformance.ts:120

The sort the subject actually has.


suggestedFixes: SuggestedFix[]

Defined in: src/types/conformance.ts:142

What the engine proposes to do about it. Switch on action.

The engine’s SuggestedFixDto; see SuggestedFix.