Interface: DiagnosisCertificate
@kortexya/reasoninglayer / DiagnosisCertificate
Interface: DiagnosisCertificate
Section titled “Interface: DiagnosisCertificate”Defined in: src/types/inference.ts:965
A sealed diagnosis: compact, deterministic, and re-verifiable against its evidence.
Remarks
Section titled “Remarks”Wire encoding, verbatim. Unlike the other SDK types, the keys are the engine’s snake_case keys: a third party re-verifies the certificate by deserializing exactly these bytes. Hashes are lowercase hex SHA-256.
Two certificates are “the same” when they seal the same derivation: compare
id (content-derived), not the whole object — metadata is annotation and
signature is a detached attestation.
Properties
Section titled “Properties”candidate_count
Section titled “candidate_count”candidate_count:
number
Defined in: src/types/inference.ts:979
How many candidates the differential returned.
derivation_root
Section titled “derivation_root”derivation_root:
string|null
Defined in: src/types/inference.ts:983
Merkle root over the per-candidate derivations; null only for an empty differential.
differential_hash
Section titled “differential_hash”differential_hash:
string
Defined in: src/types/inference.ts:977
Hash of the ranked differential (order-sensitive).
id:
string
Defined in: src/types/inference.ts:969
Content-derived identity (UUID): re-sealing identical evidence yields the same id.
issued_at
Section titled “issued_at”issued_at:
number
Defined in: src/types/inference.ts:971
Issue time, Unix seconds.
kb_data_version
Section titled “kb_data_version”kb_data_version:
string
Defined in: src/types/inference.ts:993
Ontology-data identity, in the clear (the request’s kbDataVersion, or "unattested").
knowledge_hash
Section titled “knowledge_hash”knowledge_hash:
string
Defined in: src/types/inference.ts:989
Hash that binds the rule-program and ontology-data identities.
matched_count
Section titled “matched_count”matched_count:
number
Defined in: src/types/inference.ts:985
Total antecedents witnessed across all candidates.
metadata
Section titled “metadata”metadata:
Record<string,string>
Defined in: src/types/inference.ts:995
Free-form provenance (for example tenant_id, goal_sort).
observation_count
Section titled “observation_count”observation_count:
number
Defined in: src/types/inference.ts:975
How many distinct observations were asserted.
observations_hash
Section titled “observations_hash”observations_hash:
string
Defined in: src/types/inference.ts:973
Hash of the sorted, de-duplicated observations.
residuated_count
Section titled “residuated_count”residuated_count:
number
Defined in: src/types/inference.ts:987
Total antecedents that residuated across all candidates.
rule_program_version
Section titled “rule_program_version”rule_program_version:
string
Defined in: src/types/inference.ts:991
Rule-program identity, in the clear.
signature
Section titled “signature”signature:
DiagnosisCertificateSignature|null
Defined in: src/types/inference.ts:997
Optional detached signature over the certificate’s content hash.
top_candidate
Section titled “top_candidate”top_candidate:
string|null
Defined in: src/types/inference.ts:981
The rank-1 candidate, in the clear, or null for an empty differential.
version
Section titled “version”version:
string
Defined in: src/types/inference.ts:967
Canonical-encoding version (currently "1.0"). It governs this encoding.