Session lifecycle management for autonomous coding. Use when starting new coding sessions, resuming work, detecting session type (init vs continue), or managing auto-continuation between sessions.
64
78%
Does it follow best practices?
Run evals on this skill
Adds up to 20 points to the overall score
View guide
Passed
No findings from the security scan
Fix and improve this skill with Tessl
tessl review fix ./.claude/skills/autonomous-session-manager/SKILL.mdThe canonical home for this skill is autonomous-session-manager in fernandezbaptiste/Skrillz
Manages session lifecycle for autonomous coding operations - creation, resumption, detection, and auto-continuation.
from scripts.session_detector import detect_session_type, SessionType
session_type = detect_session_type(project_dir)
if session_type == SessionType.INIT:
# First run - need to initialize
pass
else:
# Continuation - resume previous work
passfrom scripts.session_manager import SessionManager
async with SessionManager(project_dir, model="claude-sonnet-4-5-20250929") as session:
result = await session.run(prompt)from scripts.auto_continue import auto_continue
# Automatically start next session after 3 second delay
await auto_continue(delay_seconds=3)┌─────────────────────────────────────────────────────────────┐
│ SESSION LIFECYCLE │
├─────────────────────────────────────────────────────────────┤
│ │
│ 1. DETECT SESSION TYPE │
│ ├─ Check for feature_list.json │
│ ├─ If missing → INIT session │
│ └─ If exists → CONTINUE session │
│ │
│ 2. CREATE SESSION │
│ ├─ Initialize SDK client │
│ ├─ Configure tools and permissions │
│ └─ Set working directory │
│ │
│ 3. RUN SESSION │
│ ├─ Execute prompt (initializer or coding) │
│ ├─ Handle tool calls │
│ └─ Capture results │
│ │
│ 4. END SESSION │
│ ├─ Save state │
│ ├─ Check completion status │
│ └─ Trigger auto-continue or shutdown │
│ │
└─────────────────────────────────────────────────────────────┘| Feature | Description |
|---|---|
| Session Detection | Automatically determines if INIT or CONTINUE |
| State Restoration | Reads progress files at session start |
| Auto-Continue | Configurable delay between sessions |
| Graceful Shutdown | Saves state before termination |
| Iteration Tracking | Counts sessions for limits |
# Session configuration
SESSION_CONFIG = {
"model": "claude-sonnet-4-5-20250929",
"max_turns": 1000,
"continue_delay": 3, # seconds
"max_iterations": None, # None = unlimited
}references/SESSION-LIFECYCLE.md - Detailed lifecycle documentationreferences/CONFIGURATION.md - Configuration optionsscripts/session_manager.py - Core SessionManager classscripts/session_detector.py - Session type detectionscripts/auto_continue.py - Auto-continuation logic93ed392
Canonical home
since Sep 12, 2026
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.