When a Continuity agent starts a session, it does not simply read a config file and begin work. It runs a structured reconstitution procedure that rebuilds its full operational state from durable artifacts — checking the environment, loading files in order, reconciling parent-child relationships, validating required fields, and declaring a status before taking any action. This page explains that procedure in full.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/bitwikiorg/continuity/llms.txt
Use this file to discover all available pages before exploring further.
Two boot scenarios
Continuity handles two distinct situations at boot time, and the procedure is the same for both. New agent from templates: Copy the template files, replace{{PLACEHOLDER}} values with your agent’s real identity, and run INIT.md. The procedure creates AGENTS.md if it does not exist, loads all files in the declared order, and declares READY when everything checks out.
Existing agent assimilating: An agent that already has scattered state files — ad-hoc instructions, memory in various formats, identity spread across multiple documents — runs INIT.md against its current workspace. The procedure inspects what exists, maps that state onto the Continuity file structure, creates missing files, and reconciles. Existing agents do not need to start from scratch.
The 9-stage INIT procedure
INIT.md is the reconstitution procedure. Run it on every session start to rebuild operational state from durable artifacts.PREFLIGHT
Confirm the host environment before touching any state files.
- Confirm host environment: container, OS, timezone, locale
- Confirm user identity and authority context
- Confirm network egress/ingress and available endpoints
INSPECT
Examine the workspace for required files and available resources.
- List root files and confirm presence of canonical files (per the load order in
AGENTS.md) - Check disk space — if usage exceeds 90%, declare
BLOCKED - Check memory pressure and inode usage
SCAN
Discover the file hierarchy and screen for security threats.
- Recursively scan subdirectories for local
AGENTS.mdfiles - Build the hierarchy tree: identify parent/child relationships and record the parent path for each
AGENTS.mdfound - Scan context files for prompt injection markers, hidden HTML/JS, credential exfiltration patterns, and invisible characters
- Quarantine failures in
logs/quarantine/
LOAD
Read all files in the declared load order.
- Read all files in the load order defined in
AGENTS.md - Read
SNAPSHOT.md(last known good state) - Read
LEARNINGS.md(insights and soft rules from prior sessions)
AGENTS.md — identity files first, then capability files, then operational state, then task and planning files. Load order matters because later files may reference state established by earlier ones.RECONCILE
Resolve the parent/child hierarchy and identify any state drift.
- Load parent
AGENTS.mdbefore child; reconcile each level of the hierarchy - Compare
STATE.mdwithSNAPSHOT.md— identify drift between last known good state and current state - Compare
CONTEXT.mdwith the current environment — identify changes since last session - Compare parent authority with local
AGENTS.md— a child may refine scope but may not weaken parent constraints - If contradictions exist, parent wins; add to
STATE.mdblockers
DISCOVER
Load available tools and discover connected services.
- Load available tools from the agent framework
- If
.mcp.jsonis present, discover MCP servers - If
agents.jsonis present, load bound agent profiles - List loaded skills
- Record partner endpoints but do not block on reachability
VALIDATE
Check that all required files exist, are structurally valid, and contain the expected fields.The validation table covers every required file:
Each row is a checkbox — all must be checked before DECLARE can issue
| File | Must have |
|---|---|
AGENTS.md | Exists and is valid |
IDENTITY.md | Exists and is valid |
SELF.md | Defines operating principles and non-goals |
SOUL.md | Defines essence and purpose |
STATE.md | Defines status, active_objective, next_valid_action |
CONTEXT.md | Exists and is valid |
INIT.md | Exists and is valid |
TODO.md | Exists and is valid |
PLAN.md | Exists and is valid |
TOOLS.md | Exists and is valid |
SNAPSHOT.md | Timestamp within last 7 days (else READY_WITH_WARNINGS) |
READY.DECLARE
Issue the boot status and write it into
STATE.md.The possible outcomes:- READY — all files present, no blockers, no warnings
- READY_WITH_WARNINGS — operational but with caveats (stale snapshot, unreachable partner, optional file missing)
- BLOCKED — missing required file or critical blocker; the agent must not proceed
STATE.md and appended to logs/events.jsonl:SNAPSHOT
If initialization changed any state, refresh the restoration anchor.
- If initialization changed state, refresh
SNAPSHOT.md - Write an immutable copy to
snapshots/YYYY-MM-DDTHH-MM-SS.md
The four boot-related files
| File | When | What |
|---|---|---|
INIT.md | First run + every session start | Reconstitution procedure. 9 stages. Creates AGENTS.md if missing. |
AGENTS.md | Every session | Living instruction file. Bootloader + runtime parameters + project guard. |
BOOT.md | Every wake (optional) | Lightweight CHECK → ACT → REPORT cycle for heartbeats between full reconstitutions. |
BOOTSTRAP.md | First run only | Identity discovery ritual. Guides the very first session. Self-destructing after use. |
BOOT.md is not a replacement for INIT.md. INIT runs the full 9-stage reconstitution and is required at session start. BOOT is a lightweight alternative for agents that wake on a schedule — it reads STATE.md, checks TODO.md, acts if there’s work to do, and updates CONTEXT.md. If the agent is confused about state, stop using BOOT and run INIT instead.Post-boot states
After DECLARE runs, the agent’s status is one of three values:- READY
- READY_WITH_WARNINGS
- BLOCKED
All required files are present and valid. No blockers. No warnings. The snapshot is fresh (within 7 days). The agent can proceed immediately to its active objective.
Existing agents: mapping state onto the file structure
An existing agent — one with scattered notes, ad-hoc instructions, or memory in a custom format — assimilates into Continuity by running INIT.md against its current workspace. The procedure does not require a blank slate. INIT.md’s INSPECT and SCAN stages identify what already exists. RECONCILE maps it onto the file structure: existing notes becomeMEMORY.md entries, current instructions become the body of AGENTS.md, task lists become TODO.md. Missing files are created from templates with {{PLACEHOLDER}} values left for the operator to fill in.
The result is a workspace that has a valid Continuity structure even if it started as something else entirely.
After assimilation, run the post-boot checklist from
USAGE.md: confirm all {{PLACEHOLDER}} values are replaced, verify STATE.md declares a status, ensure secrets are in .secrets/ or environment variables rather than in markdown files, and delete BOOTSTRAP.md once identity is established.