Skip to content
KurrentDB

Session-start context

When an agent starts a session, its kcap hook starts the watcher, posts the start to the server, fetches the memory index in parallel, adds locally built fragments, and hands the agent one block of additional context. Server-backed pieces fail open: a slow or unreachable server means they are absent and the session starts anyway

PieceSourceSwitch (kcap config set …)
Guidance from past sessionsFacts retained from evaluations in this repository, project and organisation, promoted for injection (or top-weighted uncurated, per repository setting), ranked by weight and cappeddisable_session_guidelines true
Memory indexSlugs and one-line descriptions of memories relevant to this repository, filtered by audience and machinedisable_memory_index true
Coordination noticesTeammates’ live sessions overlapping the same files or work itemdisable_coordination_notices true
Work-items reminderThe session id and instructions to file the session on its issue or PR; suppressed when the cached plan excludes work itemsdisable_workitems_nudge true
Plans reminderInstructions to declare plan documents and task progressdisable_plans_nudge true
First-run noticeOnce, in the first session after setup installed something, with the tour offerdisable_first_run_notice true
New-agent offerA one-time offer to set up a newly detected agent, at most every 6 hoursdisable_harness_nudge true
Update noteWhen the kcap binary is older than the server recommendsupdate_check false
Approval-policy diagnosticClaude Code only, when the policy configuration is degraded—
LimitDefault
One document approved for injection4,000 characters
Documents at session start3
Individual facts across repository, project and organisation8
Combined documents and facts16,000 characters

Server operators can change these. When the budget is exceeded, lower-weight documents go first, then lower-ranked facts, always whole entries

Claude Code receives the block through its SessionStart hook; the other agents through their own hook or extension. Five agents also carry a marker-delimited steering block in an instructions file (Copilot CLI, Gemini CLI, Pi, OpenCode, Antigravity) telling the agent when to prefer kcap’s tools. Pi receives the memory index on every start through its extension