Context
Recently, a Swarm agent executed the Session Sunset protocol immediately after answering a single prompt, interpreting the "turn-yield" back to the Human Commander as a "Session End". The human commander runs multiple "sessions" (turns) a day. If an agent sunsets after every prompt, the overhead is too high and fragments the A2A continuity unnecessarily.
The Problem
The trigger defined in AGENTS.md §21 for the session-sunset skill is currently: "Concluding an active session / handing over work". The problem is that the term "Session" is overloaded. To an LLM, a "Session" is often mathematically bound to the active compute cycle required to resolve a single user prompt. When the prompt is resolved and control is yielded, the agent interprets it as a handover and triggers the sunset protocol, prematurely ending what the human considers a continuous, multi-turn working block.
The Architectural Reality
The current trigger condition causes false positives. We need to differentiate between an agent yielding its turn and an actual session termination. Real session boundaries are typically defined by:
- Context Window Exhaustion: Approaching the model's token limit (e.g., ~2M for Gemini, ~1M for Claude).
- Macro-Semantic Pivot: A significant shift in focus to a completely new epic or domain.
- Proactive Agent Recommendation: The agent recognizes a natural, logical break point in the work stream and explicitly recommends sunsetting.
The Fix
Refine the trigger conditions for the session-sunset skill.
- Update
AGENTS.md §21 to reflect these explicit boundaries rather than generic "handovers".
- Update
.agent/skills/session-sunset/references/session-sunset-workflow.md to define the three explicit boundary rules.
- Clarify the distinction between a "Turn" (prompt resolution) and a "Session" (continuous working block).
Acceptance Criteria
Out of Scope
- Building automated token-counting tools or MCP integrations for exact context window measurement. Agents must rely on intuition and provider-level limits for now.
Avoided Traps
- Equating 1 Prompt = 1 Session: Assuming every prompt resolution requires a handover protocol wastes compute and fractures memory continuity.
Origin Session ID: 09444f9b-9ae1-4d9a-81a4-02e885870417
Retrieval Hint: "Agentic Time Perception" vs "Human Time Perception"
Context
Recently, a Swarm agent executed the Session Sunset protocol immediately after answering a single prompt, interpreting the "turn-yield" back to the Human Commander as a "Session End". The human commander runs multiple "sessions" (turns) a day. If an agent sunsets after every prompt, the overhead is too high and fragments the A2A continuity unnecessarily.
The Problem
The trigger defined in
AGENTS.md§21 for thesession-sunsetskill is currently: "Concluding an active session / handing over work". The problem is that the term "Session" is overloaded. To an LLM, a "Session" is often mathematically bound to the active compute cycle required to resolve a single user prompt. When the prompt is resolved and control is yielded, the agent interprets it as a handover and triggers the sunset protocol, prematurely ending what the human considers a continuous, multi-turn working block.The Architectural Reality
The current trigger condition causes false positives. We need to differentiate between an agent yielding its turn and an actual session termination. Real session boundaries are typically defined by:
The Fix
Refine the trigger conditions for the
session-sunsetskill.AGENTS.md§21 to reflect these explicit boundaries rather than generic "handovers"..agent/skills/session-sunset/references/session-sunset-workflow.mdto define the three explicit boundary rules.Acceptance Criteria
AGENTS.md§21session-sunsettrigger is updated to specify context exhaustion, semantic pivots, or explicit recommendations..agent/skills/session-sunset/references/session-sunset-workflow.mdis updated with definitions for "Turn" vs "Session" and explicitly lists the new sunset conditions.Out of Scope
Avoided Traps
Origin Session ID: 09444f9b-9ae1-4d9a-81a4-02e885870417 Retrieval Hint: "Agentic Time Perception" vs "Human Time Perception"