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:
/enddoes NOT perform any Git operations (commit, push, tag). Use/pushfor 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
| Option | Description |
|---|---|
project-name | Target project to close |
all | Close all projects with changes in the current session |
workspace | Log to Areas/Workspace/sessions/ instead of a project |
done | If 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:
| Type | Criteria | Log Destination |
|---|---|---|
| Project Work | Development, bug fixes, project docs | Projects/[name]/sessions/YYYY-MM-DD.md |
| Workspace & Learning | Structure refactoring, learning, standards | Areas/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
strategydocument changed → creates SYNC entry for downstream - If the active
roadmapdocument 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.mdC5 —/endis the sole sync point.
Step A: Process Quick Tasks from sprint-current.md:
[x]items → append todone.mdwith#sessiontag[ ]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.mdwith#backlogtag
4. Check Plan Phase Progress
Only runs if
project.mdhas a non-emptyactive_planfield.
- Extracts the current phase from the plan file
- Counts ✅ Done items for that phase against the backlog
- Logs phase status in the session file
When using the done keyword:
- Plan 100% complete → asks for confirmation before archiving:
If confirmed → moves plan to📦 Archive completed plan? [plan-name] → plans/done/[plan-name].md Y → Move to archive (recommended) N → Keep in placeplans/done/, removesactive_planfromproject.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 not | Use instead |
|---|---|
| Commit code | /push |
| Push to remote | /push |
| Run build/test | /push --test |
| Create releases | /release |
| Review code | /verify |
Recommended Flow
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