Skip to content

Conversation

@Musti7even
Copy link
Collaborator

@Musti7even Musti7even commented Dec 18, 2025

Summary

  • Adds multi-conversation (multi-chat) support per workspace/worktree

Key Features

  • Multiple conversations per workspace: Users can now have multiple independent chat sessions within a single workspace
  • Conversation tabs: Clean tab interface for switching between conversations
  • Proper history isolation: New conversations start fresh without resume flags

Technical Changes

UI Components

  • ConversationTabs: New component for tab-based conversation navigation with:
    • Centered tab titles with proper padding
    • Close button (X) on hover with gradient fade effect
    • Active tab indicator (bottom border)

State Management

  • useConversations: New hook for conversation CRUD operations
  • Conversations persist via SQLite database
  • Active conversation ID stored in localStorage per workspace

Database Schema

  • Added conversations table with proper foreign key relationships
  • IPC handlers for conversation CRUD operations
  • Automatic default conversation creation

This commit implements multi-conversation (multi-chat) support per workspace/worktree, allowing users to have multiple independent chat sessions within a single workspace.

Key changes:
- Add ConversationTabs component for tab-based conversation navigation
- Add NewConversationButton with simple + icon (removed fancy provider selection UI)
- Add useConversations hook for conversation state management
- Implement conversation CRUD operations in DatabaseService
- Fix issue where new tabs were starting with shared history by:
  - Adding skipResume parameter to prevent resume flags (-c -r, --resume, etc.) on new conversations
  - Pass skipResume=true when creating new terminal sessions
  - Update PTY manager to conditionally skip provider resumeFlag

UI improvements:
- Simplified new conversation button (no animations, just basic + button)
- Tab styling with proper centering, padding, and close button
- Gradient fade effect on tab titles when hovering to show X button
- Remove provider icon from active tab

Technical details:
- Each conversation has unique terminalId: ${provider}-conv-${conversationId}
- Conversations persist across app restarts via SQLite database
- Tab state stored in localStorage per workspace
- Resume flags are skipped only for new conversations to avoid history sharing

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@vercel
Copy link

vercel bot commented Dec 18, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
docs Ready Ready Preview, Comment Dec 18, 2025 3:48am

Resolved conflicts in:
- src/main/services/ptyManager.ts (formatting and skipResume default value)
- src/main/services/ptyIpc.ts (integrated snapshot-based skipResume logic)

The merge brings in:
- Environment variable cleanup for Linux AppImage (#485)
- New AllChangesDiffModal component
- Monaco diff colors and utilities
- Improved file changes panel

Our skipResume logic now works alongside the snapshot-based logic from main.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@Musti7even Musti7even changed the title feat: Add multi-conversation support with simplified new tab UI feat: Add multi-conversation support (multi chats in worktree) Dec 18, 2025
The previous implementation was breaking history management by always
setting skipResume=true for all sessions, including existing ones.

The correct behavior is:
- New conversations (first time): skipResume is handled by ptyIpc based on snapshot existence
- Existing conversations (reopening): ptyIpc checks for snapshot and uses resume flag if present

This fix removes the forced skipResume=true from SessionRegistry and lets
the intelligent snapshot-based logic in ptyIpc.ts (lines 40-59) handle it.

Now:
- New conversations without snapshots: resume flag is skipped
- Existing conversations with snapshots: resume flag is used to continue where left off

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@Musti7even Musti7even changed the title feat: Add multi-conversation support (multi chats in worktree) draft: feat: Add multi-conversation support (multi chats in worktree) Dec 18, 2025
@Musti7even Musti7even marked this pull request as draft December 18, 2025 03:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants