arrow_back Back to Catalog
workflows Beginner

Workflow /end

Closes a working session by logging accomplishments, syncing Hot Lane tasks, detecting strategy/roadmap changes, and checking plan progress.

The /end workflow closes a working session by summarizing accomplishments and logging them to the correct PARA location. It ensures context is preserved for the next session.

Important: /end does NOT perform any Git operations (commit, push, tag). Use /push for that.

Commands Overview

/end [project-name]          # Close session for a specific project
/end all                     # Close session for all modified projects
/end workspace               # Close session for workspace-level work
/end [project-name] done     # Close + clean up completed plan
OptionDescription
project-nameTarget project to close
allClose all projects with changes in the current session
workspaceLog to Areas/Workspace/sessions/ instead of a project
doneIf active_plan is 100% complete, remove the field from project.md

Session Close Flow

Pre-flight → Classify → Log → Sync queue → Strategy/Roadmap detection
→ Brainstorm follow-up → Hot Lane Sync → Plan progress → Roadmap sync → Master index

0. Rules Pre-flight (v1.5.4)

Before any step executes, the agent re-reads .agent/rules.md from disk to restore rule context. This is part of the Defense-in-Depth Layer 3 protection — ensuring rules survive context truncation in long sessions.

1. Classify & Identify Changes

Determines whether work belongs to a specific Project or to Workspace/Learning:

TypeCriteriaLog Destination
Project WorkDevelopment, bug fixes, project docsProjects/[name]/sessions/YYYY-MM-DD.md
Workspace & LearningStructure refactoring, learning, standardsAreas/Workspace/sessions/YYYY-MM-DD.md

2. Log Session

Creates or appends to the session log file. Uses “Session N” headers when multiple topics are covered in one day.

Required sections:

  • What was done — completed items (bullet list)
  • Pending TODOs — carry-forward items for next session
  • Downstream Impact — if changes affect other projects

3. Cross-Project Sync Queue

If project.md declares downstream dependencies, appends a row to Areas/Workspace/SYNC.md:

| YYYY-MM-DD | [source] | [version] | [downstream] | [action needed] | 🔴 Pending |

Skipped if no downstream dependencies exist.

@prefix resolution (v1.6.0+): When resolving active_plan paths, supports cross-project @{ecosystem}/ prefix. Skip git suggestions for type: ecosystem projects.

3.2. Strategy/Roadmap Change Detection (v1.6.3)

Detects if the current session modified strategy or roadmap documents via field-gated detection (project.md -> strategy and roadmap fields):

  • If the active strategy document changed → creates SYNC entry for downstream
  • If the active roadmap document changed → logs roadmap update in session

3.3. Brainstorm Follow-up (v1.6.1)

If a brainstorm was created or updated during the session, suggests next steps:

  • Pending decision💭 Brainstorm [topic] needs decision. Run /brainstorm to continue.
  • Decided✅ Brainstorm [topic] decided. Run /plan to formalize or /docs to publish.

3.5. Hot Lane Sync (v1.5.3)

Rule: hybrid-3-file-integrity.md C5 — /end is the sole sync point.

Step A: Process Quick Tasks from sprint-current.md:

  • [x] items → append to done.md with #session tag
  • [ ] items → ask user: keep for next session or promote to backlog?
  • Clean sprint-current.md (remove completed, keep pending)

Step B: Smart Suggest Strategic Tasks from session log:

  • Extract mentioned task IDs (FEAT-XX, BUG-XX) from session log
  • Cross-reference with active backlog items
  • Suggest to user: “Mark these as Done?”
  • Confirmed items → update backlog, append to done.md with #backlog tag

4. Check Plan Phase Progress

Only runs if project.md has a non-empty active_plan field.

  1. Extracts the current phase from the plan file
  2. Counts ✅ Done items for that phase against the backlog
  3. Logs phase status in the session file

When using the done keyword:

  • Plan 100% complete → asks for confirmation before archiving:
    📦 Archive completed plan?
       [plan-name] → plans/done/[plan-name].md
       Y → Move to archive (recommended)
       N → Keep in place
    If confirmed → moves plan to plans/done/, removes active_plan from project.md
  • Phase complete → announces next phase is ready

4.5. Roadmap Status Sync (v1.6.3)

Checks the roadmap field in project.md. If a roadmap is defined, auto-updates its phase status after the plan progress check. When a detail plan completes, marks the corresponding roadmap phase as ✅ Done.

5. Update Master Index

Appends a one-line summary to Areas/Workspace/SESSION_LOG.md:

| YYYY-MM-DD | [project-name] | [brief summary] |

What /end Does NOT Do

Does notUse instead
Commit code/push
Push to remote/push
Run build/test/push --test
Create releases/release
Review code/verify
Work → /push (commit & push) → /end (log session) → /open (next day)

Updated in v1.6.3. Field-gated detection for Strategy and Roadmap changes.

→ Workflow /open — Start session with context loading → Learn: Hybrid 3-File Architecture → Learn: Strategy → Plan Flow