Session Sunset
Agent Buildingsession-sunsetSession Sunset is an Agent Skill for agent building published in the neomjs/neo repository on GitHub: a SKILL.md instruction file an AI agent can load to do this task.
Authoritative protocol for gracefully terminating an agent session. Mandates structured handover comments, mental-model states, and memory persistence to prevent Zero-State Amnesia. Triggers: When concluding a long-running session, executing the Sunset Protocol, handing over work for the next agent, or terminating an agent cycle.
How to use this skill
Bring this guide into your coding agent with a prompt tailored to the tool you use.
- Open your project in Codex.
- Copy and paste the prompt below.
- Review files and risks before approving any action.
Inspect the Agent Skill at https://github.com/neomjs/neo/blob/HEAD/.agents/skills/session-sunset/SKILL.md and all supporting files. Report provenance, permissions, scripts, dependencies, and security risks. Propose an exact installation into .agents/skills/session-sunset, but wait for my approval before writing files or running scripts.
Copying this prompt does not install or run the skill. Review third-party files before use.
Session Sunset Skill
🛑 ANTI-TRIGGERS (Completion Bias Guard) 🛑 Task Completion ≠ Session Sunset. You must halt and wait for the next turn (do NOT sunset) if you are:
- Halting for Peer Review: Waiting for cross-family PR review or human feedback. This is an active lifecycle state, not a boundary.
- Single Task Completion: Finishing one ticket/task while your context window is still healthy. Pick up the next task.
- Asynchronous Delays: Waiting for CI, test results, or A2A responses.
Sunsets are strictly reserved for Context Window Exhaustion (>75% full/forgetfulness), Macro-Semantic Pivots, or Explicit Human Directives.
If you meet a valid sunset condition, you MUST immediately use the view_file tool to read and strictly adhere to .agents/skills/session-sunset/references/session-sunset-workflow.md before terminating. This prevents Zero-State Amnesia.