| name | continue |
| description | Pick up unfinished work from where the last session left off |
| argument-hint | [task description or context] |
Continue
Reconstruct context from the last session and continue unfinished work. Use when a previous session ended mid-task due to context limits, interruption, or session timeout.
DO NOT STOP UNTIL THE RECONSTRUCTED TASK IS COMPLETE.
Arguments
$ARGUMENTS - Optional context about what was being done. If empty, reconstruct from git state.
Phase 1: Reconstruct Context (Parallel)
Launch four agents in parallel to gather all state simultaneously:
Agent 1 — Git State:
git status
git branch --show-current
git stash list
BASE=$(gh repo view --json defaultBranchRef -q .defaultBranchRef.name 2>/dev/null || git symbolic-ref refs/remotes/origin/HEAD 2>/dev/null | sed 's@^refs/remotes/origin/@@')
echo "BASE=$BASE"
git log $BASE..HEAD --oneline 2>/dev/null || git log --oneline -10
Agent 2 — Uncommitted Work:
git diff --stat
git diff --cached --stat
git diff
git diff --cached
Agent 3 — Recent Changes:
git log --oneline -10 --all
git diff $BASE...HEAD --name-only 2>/dev/null
git diff $BASE...HEAD --stat 2>/dev/null
Agent 4 — Failing State:
Run the project's test/build/lint commands to find what's currently broken:
if [ -f "composer.json" ]; then composer test 2>&1 | tail -30; fi
if [ -f "build.gradle" ] || [ -f "build.gradle.kts" ]; then ./gradlew test 2>&1 | tail -30; fi
if [ -f "package.json" ]; then npm test 2>&1 | tail -30; fi
if [ -f "Cargo.toml" ]; then cargo test 2>&1 | tail -30; fi
if [ -f "go.mod" ]; then go test ./... 2>&1 | tail -30; fi
Phase 2: Diagnose What's Unfinished
From Phase 1 results, determine:
- Branch state — Are we on a feature branch? How far ahead of base?
- Uncommitted changes — Is there work in progress that needs committing?
- Stashed work — Is there stashed work that needs popping?
- Test/build state — Are tests passing? Is the build clean?
- Incomplete patterns — Are there TODO markers, placeholder code, empty test bodies, or unimplemented methods?
Search for incomplete markers:
grep -rn "TODO\|FIXME\|HACK\|XXX\|PLACEHOLDER\|NotImplemented\|throw.*not.*implement" --include="*.php" --include="*.kt" --include="*.java" --include="*.ts" --include="*.js" --include="*.rs" --include="*.go" --include="*.py" . 2>/dev/null | grep -v node_modules | grep -v vendor | head -20
If $ARGUMENTS is provided, use it to narrow focus. Otherwise, infer the task from:
- Branch name (e.g.,
feat/add-auth tells you what was being built)
- Commit messages (what's already been done)
- Uncommitted changes (what's in progress)
- Failing tests (what's broken)
Phase 3: Plan Remaining Work
Based on the diagnosis, create a plan:
- List what's already done (from commits and code state)
- List what's remaining (from failures, TODOs, uncommitted work)
- Prioritize: fix broken things first, then complete unfinished work
Phase 4: Execute
Based on complexity of remaining work:
If simple (1-2 files, clear fix):
Fix directly, verify, commit.
If moderate (multiple files, one domain):
Launch an architect agent to complete the work, then verify.
If complex (cross-cutting, multiple domains):
Invoke the consolidation skill (Skill(skill="skills:consolidation", args="...")) with the remaining work plan. You become the conductor and dispatch the planner → verifier → parallel architects → consolidator → reviewer → verifier cycle.
Phase 5: Verify & Commit
- Run full test suite — all tests must pass
- Run lint — must be clean
- Run build — must succeed
- Commit any remaining changes:
Skill(skill="skills:commit-all")
Phase 6: Report
## Continuation Summary
- **Picked up from:** <branch name, last commit>
- **State found:** <clean/dirty/failing>
- **Work completed:**
- <item 1>
- <item 2>
- **Tests:** pass
- **Build:** pass
- **Commits created:** N
Hard Rules
- DO NOT ASK what was being done if it can be inferred from git state — just continue
- DO NOT START OVER — build on existing work, don't redo it
- FIX EVERYTHING — if tests are failing, fix them regardless of whether they're "yours"
- COMMIT INCREMENTALLY — don't accumulate a huge uncommitted diff
- VERIFY BEFORE REPORTING — run tests/build/lint before claiming completion