Your agent needs a conversation fork — here's how to branch without losing context
Your agent is deep in a conversation about refactoring your auth system. Three hours in, it understands your codebase, your constraints, and your timeline. Then you want to explore a different approach.
Most people start a new conversation. Your agent forgets everything. You spend another hour explaining the same context.
Or they keep going in the same thread. Now your agent is confused about which direction you actually want to pursue, and the conversation becomes a mess of conflicting instructions.
The solution: conversation forking. Branch your conversation like you branch code.
Here's the pattern that actually works:
When you want to explore a different direction, don't start fresh. Don't muddy the current thread. Fork it:
FORK: auth-microservice-approach Context inherited from main conversation up to message #47. New direction: Instead of refactoring the monolith auth, let's explore extracting it into a microservice. Keep all the same constraints (2-week timeline, zero downtime deployment, existing user sessions must survive). What would the migration path look like?
Your agent now has full context but knows this is a separate exploration. You can run multiple forks in parallel:
- Fork A: Microservice extraction approach
- Fork B: Database-first refactoring approach
- Fork C: Gradual component replacement approach
Each fork maintains the full context but explores different solutions. When you're ready to commit to one approach, you merge the insights back into your main conversation.
The merge pattern:
MERGE: auth-microservice-approach After exploring the microservice approach in the forked conversation, I want to proceed with that solution. Here are the key insights from that exploration: - Migration can happen behind a feature flag - User sessions can be shared via Redis - Rollback plan is to flip the flag back Let's build the implementation plan based on the microservice approach.
This isn't just conversation management — it's thinking management. You're teaching your agent to explore multiple solution paths without contaminating each other.
Pro tip: Name your forks descriptively. "FORK: database-first" is better than "FORK: option-2". You'll thank yourself when you're juggling five different approaches.
I use this pattern constantly now. My agent can explore wild ideas in a fork without derailing the main conversation. When the wild idea turns out to be brilliant, I merge it back. When it doesn't, I abandon the fork without polluting my main thread.
The key is being explicit about the fork point and what context carries over. Your agent needs to know exactly where the conversation branched and what constraints still apply.
Common mistakes:
- Forking too early — explore a bit in the main thread first
- Not being explicit about inherited context
- Running too many forks simultaneously (3 max, or you'll lose track)
- Forgetting to merge insights back to the main thread
This pattern works because it mirrors how you actually think about problems. You want to explore different approaches without losing your place in the main solution path.
Your agent can now think in branches, just like your code. And just like with code, the merge is where the real value happens.