Skip to main content

Module knowledge

Module knowledge 

Source
Expand description

Thread-safe in-memory knowledge base for evidence-driven reasoning.

§Runtime scope

  • Build: always/default.
  • Execution: Surface B uses the base as deterministic reasoning state. Surface A’s opt-in legacy runner also records bounded probe receipts and verifier-owned manual-review outcomes from phases 5, 7, 8, and 9.
  • Default termivar scan: yes, through Surface B; legacy knowledge writes require the explicit legacy-scan path and its acknowledgement flag.
  • Support: implemented and tested.

See docs/internals/runtime-map.md.

The base owns ontology, instance relationships, evidence, facts, and hypotheses, but deliberately contains no detection, scoring, planning, or persistence behavior. Producers can write observations in any order; referential integrity is therefore eventual so discovery modules remain independent from one another.

Structs§

KnowledgeBase
Thread-safe, indexed knowledge shared by evidence and decision engines.
KnowledgeBaseStats
Counts of records currently held by a KnowledgeBase.
KnowledgeSnapshot
Consistent, immutable knowledge for one subject at one point in time.

Enums§

KnowledgeBaseError
Errors raised when a knowledge record violates storage or identity invariants.
KnowledgeRecordKind
Record categories used in identity-conflict diagnostics.
KnowledgeWrite
Result of an idempotent write to the knowledge base.

Constants§

MAX_KNOWLEDGE_RELATION_ENTITY_ID_BYTES
Hard byte ceiling for either entity identifier on a stored relation.
MAX_KNOWLEDGE_RELATION_EVIDENCE_IDS
Hard ceiling for distinct evidence records backing one stored relation.
MAX_KNOWLEDGE_RELATION_EVIDENCE_ID_BYTES
Hard byte ceiling for each evidence identifier backing a stored relation.
MAX_KNOWLEDGE_RELATION_ID_BYTES
Hard byte ceiling for one stored knowledge-relation identifier.
MAX_KNOWLEDGE_RELATION_KIND_BYTES
Hard byte ceiling for a stored custom relation-kind identifier.

Type Aliases§

KnowledgeStoreDeprecated
Compatibility alias for the original storage-oriented name.
KnowledgeStoreErrorDeprecated
Compatibility alias for KnowledgeBaseError.
KnowledgeStoreStatsDeprecated
Compatibility alias for KnowledgeBaseStats.