session-boot

session-boot is a cursor rule for coding agents from robertsfeir/atelier-pipeline. It costs 2,073 tokens per session, scanned A, original, Apache-2.0.

A set of startup rules for coordinating multiple coding agents in a Claude Code project. It checks project state, available agents, execution settings, and quality-control signals at the beginning of a session.

In plain words
What is it for?
Use it when running wave-based, multi-agent development workflows with persistent project memory and automated quality gates.
Why use it?
It gives a multi-agent workflow shared context and checks, helping agents continue work from the right phase instead of starting with missing information.

Cursor rule

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/robertsfeir/atelier-pipeline/session-boot
Clone the repo
git clone --depth 1 https://github.com/robertsfeir/atelier-pipeline

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for session-boot

README.md
[![agentmods](https://agentmods.dev/badge/rules/robertsfeir/atelier-pipeline/session-boot.svg)](https://agentmods.dev/rules/robertsfeir/atelier-pipeline/session-boot)
Your own site
<a href="https://agentmods.dev/rules/robertsfeir/atelier-pipeline/session-boot"><img src="https://agentmods.dev/badge/rules/robertsfeir/atelier-pipeline/session-boot.svg" alt="Measured on agentmods" height="20"></a>
Per session 2,073 This file is loaded in full into every session.
When invoked 2,073 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.02073 $0.02073
Opus 5 $0.01037 $0.01037
Sonnet 5 $0.00415 $0.00415
Haiku 4.5 $0.00207 $0.00207

Measured 4d ago against content hash 944e0110a687, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

session-boot scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor-plugin/rules/session-boot.mdc · 128 lines

How it starts

The opening of the file, as written. The whole thing — 128 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Session Boot Sequence (run on every new session)

Steps 1-3d: Parse session-boot.sh output. The session-boot.sh SessionStart hook reads pipeline-state.md, context-brief.md, error-patterns.md, pipeline-config.json, counts custom agents, and checks the CLAUDE_AGENT_TEAMS env var. It outputs structured JSON with: pipeline_active, phase, feature, stale_context, warn_agents[], branching_strategy, agent_teams_enabled, agent_teams_env, custom_agent_count, ci_watch_enabled, darwin_enabled, dashboard_mode, project_name, sentinel_enabled, deps_agent_enabled, token_budget_warning_threshold (number or null; absent key treated as null -- no budget gate for Medium, Large-only estimate with hard pause), stop_reason (present when a previous terminal pipeline has a recorded stop reason, or inferred as "session_crashed" when a stale pipeline is detected -- see session_crashed inference rule below). Eva parses this JSON to populate session state. Derive agent_teams_available from agent_teams_enabled && agent_teams_env.

Eva must parse state_dir from the boot JSON and use it as the value for docs/pipeline for the duration of the session. All reads and writes to session-specific files (pipeline-state.md, context-brief.md, investigation-ledger.md, last-qa-report.md) must use this resolved path. error-patterns.md always stays at docs/pipeline/error-patterns.md regardless of state_dir. If state_dir is absent or empty, fall back to docs/pipeline/.

session_crashed inference rule: When session-boot detects a stale pipeline (stale_context: true OR pipeline_active: true with a non-idle phase), AND the PIPELINE_STATUS JSON in pipeline-state.md has no stop_reason key (or its value is null), session-boot includes "stop_reason": "session_crashed" in its JSON output. Eva uses this inferred stop reason when announcing the stale pipeline to the user and when capturing T3 telemetry retroactively (if applicable). The session_crashed value is inferred -- it is never written to pipeline-state.md by Eva directly (Eva cannot write during a crash). Eva may write session_crashed to pipeline-state.md after boot only when she is explicitly recovering a stale pipeline and choosing to record the inferred stop reason for posterity.

  1. Brain health check -- call atelier_stats. Two gates:
    • Gate 1: Is the tool available? (If not → brain not configured, skip)
    • Gate 2: Does it return brain_enabled: true? (If not → brain disabled by user)
    • Both pass → set brain_available: true in pipeline state
    • Either fails → set brain_available: false, log reason, proceed baseline

4b. Telemetry hydration (if brain_available: true) -- call atelier_hydrate with the project sessions path. Derive the path from CLAUDE_PROJECT_DIR using the same convention session-hydrate.sh used: ~/.claude/projects/-{CLAUDE_PROJECT_DIR with / replaced by -} (leading / becomes -). Example: CLAUDE_PROJECT_DIR=/Users/alice/projects/myapp~/.claude/projects/-Users-alice-projects-myapp. Non-blocking: atelier_hydrate returns {status: "queued"} immediately. Do not await the result. Move directly to step 5 without waiting for hydration to complete. When brain_available: false: skip this step entirely.

  1. Brain context retrieval (if brain_available: true) -- call agent_search with query derived from current feature area. Inject results alongside context-brief.md. 5b. Telemetry trend query (OPTIONAL -- skip unless a pipeline is about to start or the user explicitly asks about pipeline trends) -- if brain_available: true, call agent_search with query "telemetry pipeline summary", filter: { telemetry_tier: 3 }, limit 10. Filter results client-side: keep only records where source_phase == 'telemetry'.

Read the full file on GitHub · 128 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 128 lines · 2,073 tokens per session scan A 944e0110a687

Subscribe to this mod's changes

session-boot is a cursor rule published in the GitHub repository robertsfeir/atelier-pipeline (25 stars, last pushed 2mo ago), licensed Apache-2.0. It adds 2,073 tokens to every session, about $0.0104 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.