session-bootstrap
Universal AgentOps init prompt for starting or onboarding a fresh agent session.
What this skill does
# `ao session bootstrap` — the universal init prompt
> **One-line value:** every agent in the swarm starts with the same orientation report, regardless of model.
## When to invoke
**Every agent spawned into an AgentOps repository runs this first.** No exceptions. The bootstrap is the contract that makes the future fungibility charter (soc-vuu6.29) operational: identical starting frames let you swap Claude for Codex (or vice versa) on any bead without re-orienting.
Triggers:
- **Manual spawn** — operator just spawned a fresh agent into the repo: `ao session bootstrap`.
- **SessionStart hook (opt-in)** — AgentOps 3.0 ships no SessionStart hook. If you author one via the `hooks-authoring` skill, it can fail-open auto-fire `ao session bootstrap --robot` and discard the exit code.
- **Pipeline submit** — the orchestration substrate (the reference is NTM + MCP + managed-agents) and headless CI agents call `ao session bootstrap --json` before claiming work.
If you spawned without running it: stop, run it, then resume.
## What it does
Four fail-open substeps, each producing a field in the [session-bootstrap.v1 schema](../../schemas/session-bootstrap.v1.schema.json):
1. **Confirm tier-split AGENTS.md present** — checks `AGENTS.md` and the post-soc-vuu6.3 siblings (`AGENTS-WORKFLOW.md`, `AGENTS-CI.md`, `AGENTS-CODEX.md`, `AGENTS-RUNTIME.md`). Reports which exist. The agent reads them itself once oriented; the bootstrap just confirms presence.
2. **Invoke `onboard --auto`** — the future task-routed reading list subcommand under soc-vuu6.9. Currently P3 / not yet implemented: bootstrap falls back to `phase="skipped:not-implemented"` and continues without blocking.
3. **Count ready beads** — `bd ready --json` length. Surfaces what's immediately claimable. Fails to `null` if bd is missing or errors.
4. **Probe mcp-agent-mail** — soft, optional. Reports unread-count or `null`. Skipped with `--no-mail` or env `MCP_AGENT_MAIL_DISABLED=1`.
## Flags
| Flag | Effect |
|-------------|---------------------------------------------------------------------------------------|
| `--json` | Emit the full status object (machine-readable, matches the v1 schema) |
| `--robot` | Same as `--json` plus a tight exit-code contract for opt-in SessionStart hooks |
| `--no-mail` | Skip the mcp-agent-mail probe even when the MCP server is reachable |
Default (no flags): one-line human summary on stdout, plus a stderr warning if `AGENTS.md` is missing.
## Output shape
```json
{
"agents_md_read": true,
"agents_siblings_read": ["AGENTS-WORKFLOW.md", "AGENTS-CI.md", "AGENTS-CODEX.md", "AGENTS-RUNTIME.md"],
"onboard_phase": "skipped:not-implemented",
"ready_beads_count": 12,
"mail_unread_count": null,
"runtime": "claude-code",
"started_at": "2026-05-21T01:50:00Z",
"bootstrap_version": "v1"
}
```
Schema at [`schemas/session-bootstrap.v1.schema.json`](../../schemas/session-bootstrap.v1.schema.json) — every field is required; nullable fields carry `null` when the substep was skipped or errored.
## Why fungibility wants this
The [agent-fungibility-philosophy](https://github.com/boshu2/agentops/issues?q=label%3Afungibility-charter) mandates: *one init prompt for every agent regardless of type*. Today every operator hand-rolls orientation: "read AGENTS.md, check bd ready, register with the mail server, then start." Two agents spawned by two different operators don't have the same starting frame. That's anti-fungibility — the swarm can't safely swap them mid-bead.
`ao session bootstrap` is the operational primitive that closes the gap. It's deliberately tiny: ~50 LOC Go + a JSON schema. It does the same four things every time, in the same order, with the same fail-open semantics. Then the agent reads the orientation tier-split itself.
## What this is NOT
- **Not a long orientation document.** The bootstrap reports *status* (read/missing/skipped), not content. Agents still read `AGENTS.md` themselves.
- **Not a workflow engine.** It does not claim work, dispatch, or modify state. It's a status snapshot.
- **Not a hard gate.** Every substep is fail-open: a missing `bd` binary, an unavailable MCP server, or a deferred `onboard` produces a `null`/`skipped` marker and the command still exits 0. The agent decides what to do with degraded orientation.
## Composes with
- **soc-vuu6.3 (AGENTS.md tier split)** — bootstrap reports which sibling files were detected.
- **soc-vuu6.9 (the future `onboard --auto` subcommand)** — when implemented, bootstrap's onboard substep wires through automatically via subprocess shellout.
- **soc-vuu6.29 (Fungibility Charter)** — the doctrinal frame this primitive operationalizes.
- **mcp-agent-mail** — soft dependency; bootstrap surfaces unread count when present.
## CI guarantees
- `cli/cmd/ao/session_bootstrap_test.go` — 8 cases (full status, missing AGENTS.md, partial split, no-mail flag, runtime detection, human summary, JSON round-trip).
- `validate-skill-frontmatter` keeps the SKILL.md frontmatter contract intact.
- No new CI gate added for the schema yet; follow-up bead can add `validate-session-bootstrap-schema` if schema-drift becomes a concern.
## See also
- [`AGENTS.md`](../../AGENTS.md) — orientation entry-point that points here.
- [`AGENTS-WORKFLOW.md`](../../AGENTS-WORKFLOW.md) — what to do after bootstrap reports.
- [`schemas/session-bootstrap.v1.schema.json`](../../schemas/session-bootstrap.v1.schema.json) — full output contract.
## Reference Documents
- [references/session-bootstrap.feature](references/session-bootstrap.feature) — Executable spec: every agent runs first, identical model-fungible frame, fail-open opt-in SessionStart hook, --json for pipeline (soc-qk4b)
Related in AI Agents
skill-development
IncludedComprehensive meta-skill for creating, managing, validating, auditing, and distributing Claude Code skills and slash commands (unified in v2.1.3+). Provides skill templates, creation workflows, validation patterns, audit checklists, naming conventions, YAML frontmatter guidance, progressive disclosure examples, and best practices lookup. Use when creating new skills, validating existing skills, auditing skill quality, understanding skill architecture, needing skill templates, learning about YAML frontmatter requirements, progressive disclosure patterns, tool restrictions (allowed-tools), skill composition, skill naming conventions, troubleshooting skill activation issues, creating custom slash commands, configuring command frontmatter, using command arguments ($ARGUMENTS, $1, $2), bash execution in commands, file references in commands, command namespacing, plugin commands, MCP slash commands, Skill tool configuration, or deciding between skills vs slash commands. Delegates to docs-management skill for official documentation.
reprompter
IncludedTransform messy prompts into well-structured, effective prompts — single or multi-agent. Use when: "reprompt", "reprompt this", "clean up this prompt", "structure my prompt", rough text needing XML tags and best practices, "reprompter teams", "repromptception", "run with quality", "smart run", "smart agents", multi-agent tasks, audits, parallel work, anything going to agent teams. Don't use when: simple Q&A, pure chat, immediate execution-only tasks. See "Don't Use When" section for details. Outputs: Structured XML/Markdown prompt, quality score (before/after), optional team brief + per-agent sub-prompts, agent team output files. Success criteria: Single mode quality score ≥ 7/10; Repromptception per-agent prompt quality score 8+/10; all required sections present, actionable and specific.
adaptive-compaction
IncludedAdaptive add-on policy and recovery layer that decides WHEN to compact, prune, snapshot, or fork -- replacing fixed-percent auto-compaction across Claude Code, Codex, and MCP-capable hosts. Trigger on auto-compact timing or damage: "when should I compact", "is it safe to compact now or start a fresh session", "auto-compact fires too early/mid-task", "switching to an unrelated task but the window still has space", "context rot", "answers get worse the longer the session runs", "the agent forgot the plan or my decisions after it summarized", "add a layer on top that manages context without changing the agent", raising autoCompactWindow to give the policy room, or installing/tuning a cross-tool compaction policy or PreCompact hook -- even when "compaction" is never said but the problem is context-window pressure or post-summarization memory loss. Do NOT use to summarize a conversation, build RAG, write a summarization prompt (decides WHEN not HOW), or answer max-context-length trivia.
agent-skill-creator
IncludedCreate cross-platform agent skills from workflow descriptions. Activates when users ask to create an agent, automate a repetitive workflow, create a custom skill, or need advanced agent creation. Triggers on phrases like create agent for, automate workflow, create skill for, every day I have to, daily I need to, turn process into agent, need to automate, create a cross-platform skill, validate this skill, export this skill, migrate this skill. Supports single skills, multi-agent suites, transcript processing, template-based creation, interactive configuration, cross-platform export, and spec validation.
llm-wiki
IncludedUse when building or maintaining a persistent personal knowledge base (second brain) in Obsidian where an LLM incrementally ingests sources, updates entity/concept pages, maintains cross-references, and keeps a synthesis current. Triggers include "second brain", "Obsidian wiki", "personal knowledge management", "ingest this paper/article/book", "build a research wiki", "compound knowledge", "Memex", or whenever the user wants knowledge to accumulate across sessions instead of being re-derived by RAG on every query.
skill-master
IncludedAgent Skills authoring, evaluation, and optimization. Create, edit, validate, benchmark, and improve skills following the agentskills.io specification. Use when designing SKILL.md files, structuring skill folders (references, scripts, assets), ingesting external documentation into skills, running trigger evals, benchmarking skill quality, optimizing descriptions, or performing blind A/B comparisons. Keywords: agentskills.io, SKILL.md, skill authoring, eval, benchmark, trigger optimization.