Skip to content

SOP-003: Session Management

DOCUMENT CONTROL

FieldValue
SOP IDSOP-003
Version1.0
StatusActive
Last UpdatedDecember 2025

Purpose

This SOP covers managing multiple Claude Code sessions simultaneously across different machines and projects using Happy Coder.

Multi-Session Architecture

┌─────────────────────────────────────────────────────────────────┐
│                     HAPPY CODER MOBILE APP                      │
├─────────────────────────────────────────────────────────────────┤
│  ┌─────────────┐  ┌─────────────┐  ┌─────────────┐             │
│  │ Session 1   │  │ Session 2   │  │ Session 3   │             │
│  │ Frontend    │  │ Backend     │  │ DevOps      │             │
│  │ [Laptop]    │  │ [Desktop]   │  │ [VPS]       │             │
│  └──────┬──────┘  └──────┬──────┘  └──────┬──────┘             │
└─────────┼────────────────┼────────────────┼─────────────────────┘
          │                │                │
          ▼                ▼                ▼
    ┌───────────┐    ┌───────────┐    ┌───────────┐
    │  Laptop   │    │  Desktop  │    │   VPS     │
    │ Claude    │    │ Claude    │    │ Claude    │
    │   Code    │    │   Code    │    │   Code    │
    └───────────┘    └───────────┘    └───────────┘

Procedure Flowchart

┌────────────────────┐
│       START        │
└─────────┬──────────┘


┌────────────────────┐
│ Start happy CLI on │
│ each machine       │
└─────────┬──────────┘


┌────────────────────┐
│ Open mobile app    │
│ View session list  │
└─────────┬──────────┘


┌────────────────────┐
│ Select session     │
│ to interact with   │
└─────────┬──────────┘


┌────────────────────┐
│ Send commands or   │
│ switch sessions    │
└─────────┬──────────┘


┌────────────────────┐
│     COMPLETE       │
└────────────────────┘

Step-by-Step Procedure

Starting Multiple Sessions

Step 1: On your first machine (e.g., laptop):

bash
cd ~/projects/frontend
happy

Step 2: On your second machine (e.g., desktop):

bash
cd ~/projects/backend
happy

Step 3: Sessions automatically appear in your mobile app.

Switching Between Sessions

  1. Open Happy Coder mobile app
  2. Tap the session list icon
  3. Select the desired session
  4. Continue conversation in that context

Session Identification

Each session shows:

InfoDescription
Machine NameHostname of the computer
Project PathWorking directory
StatusActive/Idle/Needs Input
Last ActivityTimestamp of last action

Running Parallel Tasks

Parallel Exploration Pattern

  1. Start 3-4 different approaches to a problem
  2. Let them run on different machines/sessions
  3. Check results on your phone
  4. Pick the best approach, discard the rest

Example Setup:

bash
# Machine 1: Try approach A
cd ~/project && git checkout -b experiment-a
happy

# Machine 2: Try approach B
cd ~/project && git checkout -b experiment-b
happy

# Machine 3: Try approach C
cd ~/project && git checkout -b experiment-c
happy

Session States

StateIconDescription
Active🟢Claude Code is processing
Idle🔵Waiting for input
Needs Input🟡Permission prompt pending
Disconnected🔴CLI not running

Best Practices

1. Use Git Worktrees

Set up worktrees for parallel experimentation:

bash
# Create worktrees ahead of time
git worktree add ../project-experiment-1 -b experiment-1
git worktree add ../project-experiment-2 -b experiment-2
git worktree add ../project-experiment-3 -b experiment-3

2. Connect All Compute Resources

Device TypeExample Uses
Development laptopPrimary coding
Desktop workstationHeavy builds, testing
Cloud VPSDeployment, CI tasks
Raspberry PiBackground automation
Mac MiniiOS development

3. Session Naming

Name sessions clearly by project or task:

bash
# Set custom session name
HAPPY_SESSION_NAME="frontend-refactor" happy

Verification Checklist

  • [ ] Multiple sessions visible in mobile app
  • [ ] Each session shows correct machine/path
  • [ ] Can switch between sessions smoothly
  • [ ] Push notifications work for all sessions
  • [ ] Session state updates in real-time

Released under the MIT License.