KnowledgeSystem constructor
KnowledgeSystem({
- required KnowledgeConfig config,
- KnowledgePorts? ports,
- FactGraphRuntime? factGraph,
- SkillRuntime? skillRuntime,
- ProfileRuntime? profileRuntime,
- PhilosophyEngine? philosophyEngine,
- OpsRuntime? opsRuntime,
- KnowledgeEventBus? eventBus,
Create a new knowledge system.
L0 FactGraph is required. When factGraph is null, a default
FactGraphRuntime.inMemory() is auto-wired so the system works
with zero external adapters out of the box.
L1 Skill / L2 Profile / L3 Philosophy / Ops are opt-in. Pass only
the runtimes for layers in scope. Inactive layer facades will throw
StateError when invoked.
Implementation
KnowledgeSystem({
required this.config,
KnowledgePorts? ports,
FactGraphRuntime? factGraph,
this.skillRuntime,
this.profileRuntime,
this.philosophyEngine,
this.opsRuntime,
KnowledgeEventBus? eventBus,
}) : ports = ports ?? const KnowledgePorts(),
factGraph = factGraph ?? FactGraphRuntime.inMemory(
defaultWorkspaceId: config.workspaceId,
),
eventBus = eventBus ?? KnowledgeEventBus() {
_initialize();
}