cognet.config.ts

Identity only. Pure data, no logic, no lifecycle. Behaviour lives in src/main.ts, and the compile step composes the two.

export default defineCognet({
    name: "zero",
    version: "0.1.0",
    abi: "9",

    mode: { kind: "invocation" },

    // runaway guard: a wake that hasn't converged in this many
    // render→infer→act ticks is a loop bug or a stuck model, not progress
    maxTicksPerWake: 32,
})

Fields

FieldRequiredWhat it declares
nameyesThe cognet's own name. Its private store is namespaced by this.
versionyesArtifact version.
abiyesThe kernel ABI this cognet was built against.
modeyesHow the scheduler wakes it.
wakeOnnoDefault wake mask. Absent means wake on everything.
maxTicksPerWakenoHard safety bound for one wake. Defaults to 8.

abi — the compatibility contract

abi: "9"

A cognet is versioned against the kernel the way a binary is versioned against syscalls. This declares which contract it was written for.

axon prepare checks it against the kernel the installed Axon provides and fails there, naming both versions and the file to edit. A cognet built for an older ABI never half-loads.

This matters more now that cognets version independently of the CLI: an agent can pin @you/my-cognet@0.1.0 while its Axon moves forward. The check is what turns that from a mysterious runtime failure into a clear prepare-time one.

mode — invocation or continuous

Part of the cognet's own declared identity, deliberately not blueprint-overridable. Same trust direction as abi: a cognet written for stimulus-driven wakes was never written to tolerate an empty-stimuli tick, so an agent author can't flip it from outside.

Invocation — woken once per admitted stimulus arrival, handed the full diff accumulated since the last wake. If several stimuli arrived while the previous wake was running, they arrive together.

mode: { kind: "invocation" }

Continuous — woken on a fixed clock regardless of whether anything arrived. An empty diff is the ordinary steady state, not an edge case.

mode: { kind: "continuous", tickMs: 8 }   // 125Hz

Continuous mode is declared but not yet implemented — selecting it throws today. See The Loop.

wakeOn — the wake mask

wakeOn: ["cognet:stimulus:text", "cognet:stimulus:field"]

Which entry types should wake this cognet. Absent means everything.

This is the cognet's default, and unlike mode it is overridable by the agent's blueprint — the cognet declares what it was built to handle, the agent narrows it for its own deployment.

maxTicksPerWake — the runaway guard

maxTicksPerWake: 32

A hard bound, not a scheduling mechanism. A wake that hasn't converged in this many ticks is a loop bug or a stuck model, not progress, and the host throws rather than spinning.

Strategy may stop earlier and usually does — zero typically converges in two or three ticks. Defaults to 8 when omitted.

What isn't here

No engine selection, no model, no prompt, no policy, no paths. Those belong to the agent, in axon.config.ts.

A cognet cannot read any of them. It declares who it is and how it wants to be woken; everything about the environment it runs in is on the other side of the kernel contract.