Session Start
Initialize a new work session with proper state management.
Execution Protocol
Step 1: Create Brain Backup
TIMESTAMP=$(date +%Y%m%d_%H%M%S)
BACKUP_DIR=".brain-backups/${TIMESTAMP}"
mkdir -p "${BACKUP_DIR}"
cp -r brain/* "${BACKUP_DIR}/"
echo "ā Brain backup created: ${BACKUP_DIR}"
Step 2: Validate Environment
Step 3: Load Context
Read these files to understand current state:
brain/development_standard.md ā Standards to follow
brain/general_index.md ā Project structure
brain/history_log.md (last 2 entries) ā Recent context
Step 4: Output Session Header
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
SESSION INITIALIZED
Date: [current date/time]
Branch: [current branch]
Backup: [backup path]
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
Ready for work request. Provide a feature description to begin planning.
Next step: /plan "your feature request"
Session Rules
- Each session targets 1-2 hours of work
- Maximum 6 atomic tasks per session
- All tasks must be in plan.md before execution
- End session with
/session-end before merging
Failure Recovery
If session-start fails:
- Check
.brain-backups/ for recent backups
- Verify brain/ directory integrity
- Run
git status to check repository state