Data Model¶
The DBML model defines the core entities for an agentic system: agents, tasks, artifacts, and memory.
The model is normalized around tasks and artifacts rather than agent ownership. An agent does not own an artifact; it transforms it as part of a task. This makes provenance, retries, and audit explicit: every artifact records which task produced it, and every task records which agent ran it.
DBML conventions in this model: Table blocks define entities, columns list a type and optional settings in square brackets (pk, increment, not null, default), and relationships are declared inline with ref: > or as standalone Ref: statements using < (one-to-many), > (many-to-one), - (one-to-one), and <> (many-to-many) [DBML, n.d.].
The schema maps the baseline's task-and-artifact model: an agents table records role and system prompt; a tasks table references the executing agent and links input/output artifacts; an artifacts table stores versioned payload objects; and a memory table holds scoped key-value state per agent. Because tasks reference artifacts rather than agents owning them, every transformation is traceable: an artifact records the task that produced it, and a task records the agent that ran it. This supports provenance, retries, and audit.