Session Management
Carry Code’s session feature allows you to create, switch, and manage multiple conversation contexts.
What is a Session?
Section titled “What is a Session?”A session is an independent conversation context. When you chat with AI, all conversation history is saved. In a session:
- AI can see what you’ve discussed before
- No need to repeat background information
- Context is automatically preserved
Session Commands
Section titled “Session Commands”Use the /session command to manage sessions:
| Command | Description |
|---|---|
/session | View all sessions |
/session new | Create a new session |
/session <name> | Switch to a specified session |
Creating a New Session
Section titled “Creating a New Session”Method 1: Command Creation
Section titled “Method 1: Command Creation”/session newThen enter the session name.
Method 2: Auto-Create
Section titled “Method 2: Auto-Create”When you exit Carry Code and restart, a new session is automatically created.
Use Cases
Section titled “Use Cases”| Scenario | Recommendation |
|---|---|
| Start a new project | Create a new session |
| Different tasks | Use different sessions |
| Clear context | Create a blank session |
Switching Sessions
Section titled “Switching Sessions”View All Sessions
Section titled “View All Sessions”/sessionDisplays all sessions, including:
- Session name
- Creation time
- Last activity time
- Message count
Switch to a Specified Session
Section titled “Switch to a Specified Session”/session <name>After switching, AI will remember the previous conversation.
Practical Tips
Section titled “Practical Tips”1. Project Isolation
Section titled “1. Project Isolation”Create separate sessions for each project:
project-frontend- Frontend projectproject-backend- Backend projectproject-utils- Utility scripts
2. Task Isolation
Section titled “2. Task Isolation”Use different sessions for different tasks:
bug-fix- Bug fixesfeature-dev- New feature developmentcode-review- Code review
3. Cleaning Up Sessions
Section titled “3. Cleaning Up Sessions”When a session gets too long, you can:
- Create a new session
- Use
/compactto compress context
Manual Context Compression
Section titled “Manual Context Compression”When a session gets too long, Carry Code automatically compresses the conversation:
- Preserve key info - Important decisions and results
- Compress history - Early conversation details
- Maintain coherence - So AI still understands context
Trigger Compression Manually
Section titled “Trigger Compression Manually”/compactManually trigger context compression to save token space.
Next Steps
Section titled “Next Steps”- Context Compaction - Learn more about context compression
- AI Model Configuration - Switch different AI models
- Theme Configuration - Customize the interface appearance