Session start
Skill ClydeShen/harness-skill/skills/engineering/session-start
10 Claude Code skills for compound engineering workflows — session discipline, harness auditing, phase governance, and issue pipeline
npx -y skills add ClydeShen/harness-skill --skill session-startAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
What its author says it does
Copied from the file, not written here
Briefs the current session by reading session state, handoff doc, and memory to determine the active phase, task, and context budget. Outputs a structured briefing and detects whether the phase should be skipped or reverted based on observable artifacts. Use at the start of every long-running agent session, or when user says "start session", "what are we working on", "resume", "pick up where we left off", "what's the active task".
SKILL.md
5.6 KB, as published. Nobody here has run it
Session Start
Explore → Evaluate → Brief. Never ask questions before reading available state.
State file
Session state lives in .harness/state.json. Schema:
{
"version": "1.0",
"session": {
"status": "idle",
"started_at": "ISO 8601",
"last_session": "ISO 8601"
},
"position": {
"phase": "01-discuss",
"active_task": "task title string",
"resume_file": ".harness/phases/01-discuss/.continue-here.json",
"stopped_at": "brief description of last action"
}
}
session.status: "idle" (clean close) | "in_progress" (active or interrupted).
Execution sequence
-
1. EXPLORE — if the
SessionStarthook ran, state fields are already in your context window viaadditionalContext— use them directly. Otherwise read:.harness/state.json→session.status,session.last_active,position.*.harness/config.json→ GitHub owner, repo, project board ID (harness key).harness/phases/XX-name/.continue-here.json→ path fromposition.resume_file.git/config→ remote origin (fallback if config.json absent)CLAUDE.md/AGENTS.md→## Agent skillsblock present? (setup indicator).harness/phases/01-discuss/→ anyCONTEXT.mdfiles? (phase skip signal).harness/phases/02-plan/→ anyPLAN.mdfiles? (phase skip signal)MEMORY.mdor top-3 memory entries relevant to active task.claude/handoff.md→ legacy fallback if .continue-here.json absent (deprecated)
Note:
session.statusandsession.started_atare set automatically by theSessionStarthook before this skill runs. No manual state write needed. -
2. RESUME CONTEXT — determine if this is a clean resume or interrupted recovery:
Detect interrupted session: if
session.statusis"in_progress"ANDsession.last_activeis >5 minutes old → interrupted session. Output a Recovery briefing (see Step 5b).If
last_activeis absent (hook not configured), fall back to:session.started_at>30 minutes old.Clean resume chain (
session.status: "idle"or absent):- a.
.harness/phases/XX/.continue-here.json— primary. Readnext_action,completed_work,remaining_work. - b. Memory system query — query active memory system for entries relevant to the active task. No GitHub required. If roam MCP tools are available (
roam_contextorroam_retrieve), callroam_retrieve <active_task>and include the architecture snapshot in the briefing output. - c. Mid-session recovery (.continue-here.json stale or absent):
git log --oneline -20+ recent GitHub per-AC progress comments (gh api repos/{owner}/{repo}/issues/{N}/comments --jq '[.[] | select(.body | startswith("Progress"))] | .[-5:]'). - d. Legacy
.claude/handoff.md— use only if .continue-here.json absent and no migration has run. - e. Cold start — nothing found.
- a.
-
3. EVALUATE — apply phase skip/revert (observable checks only):
Condition Action .harness/phases/01-discuss/contains aCONTEXT.mdSkip discuss → set phase to plan .harness/phases/02-plan/contains aPLAN.mdSkip discuss + plan → set phase to execute position.phaseis02-planbut no CONTEXT.md in01-discuss/Revert to discuss position.phaseis03-executebut no PLAN.md in02-plan/Revert to plan Log skip/revert in the briefing: "Phase advanced to execute — found PLAN.md in 02-plan and approved CONTEXT.md."
-
4. COLD-START — if all of the above yield nothing (no config.json, state.json, .continue-here.json, GitHub issues):
- Output: "No prior session state found."
- Present what WAS found (e.g., "Found CLAUDE.md with no ## Agent skills block")
- Suggest: "Run
/setup-harness-skillsto initialize .harness/ or describe what you'd like to work on." - Do NOT default to any phase. Wait for user input.
-
5. OUTPUT — emit one of two briefing formats:
5a. Clean resume briefing:
## Session briefing Phase: [discuss / plan / execute / verify] (0N-name) Active task: #N — [title] Effort remaining: ~N context window(s) (token budget: 1 = ~150K–200K tokens) Pick up from: [<next_action> from .continue-here.json] Budget for this session: [phase-specific table from context-handover/phase-budgets.md] Run /context-handover when approaching 80% usage.5b. Recovery briefing (interrupted session detected):
## Recovery briefing — interrupted session detected Last active: [session.last_active] — no context-handover was recorded. Phase: [position.phase] Active task: [position.active_task] Last known intent: [position.stopped_at, or next_action from stale .continue-here.json] ## What changed since interruption (git log) [output of: git log --after="<session.last_active>" --oneline] ## What to do Review the git log above. If work is partially complete, continue from the last commit. If the session left code in an inconsistent state, run lint+build before proceeding. Run /context-handover when approaching 80% usage.
Phase budget tables live in ../context-handover/phase-budgets.md.