-
-
Notifications
You must be signed in to change notification settings - Fork 1
Closed
Description
Problem
7 different chat/conversation implementations exist (~5,000 duplicate lines), causing confusion about which to use and feature fragmentation.
Files Affected
src/chat_workflow_manager.py(67,537 bytes) - Main chat workflowsrc/chat_workflow_consolidated.py(35,730 bytes) - Consolidated attemptsrc/async_chat_workflow.py(13,090 bytes) - Async workflowsrc/simple_chat_workflow.py(12,608 bytes) - Simplified workflowsrc/conversation.py(29,403 bytes) - Conversation managementsrc/conversation_performance_optimized.py(39,933 bytes) - Performance-optimizedsrc/conversation_file_manager.py(36,061 bytes) - File-based storage
⚠️ CRITICAL: Feature Preservation Required
MUST audit ALL 7 chat/conversation implementations:
- Main workflow (67KB) likely has features not in smaller versions
- Performance-optimized (40KB) may have critical performance improvements
- File-based manager (36KB) may have unique persistence capabilities
- Consolidated (36KB) may have been attempt to merge features already
- Simple (13KB) may have cleaner patterns despite being smaller
- CANNOT assume biggest = best - each evolved for different use cases
Recommended Approach
- AUDIT: Compare all 7 implementations for unique workflows, features, optimizations
- ANALYZE: What makes performance-optimized version faster? What's in file-based that others lack?
- Identify active/primary BASE implementation (likely
chat_workflow_manager.py) - MERGE: Best features from all 7 (workflows from main, optimizations from performance, persistence from file-based)
- DOCUMENT: Feature matrix showing what came from where
- Create migration guide
- Deprecate old implementations
- Update all consumers
Benefits
- Single chat workflow API
- Consistent conversation handling
- Easier to add new features
- Reduced confusion for developers
Acceptance Criteria
- Feature comparison across all 7 implementations
- Performance analysis (why is performance-optimized version 40KB?)
- Persistence analysis (what's unique in file-based manager?)
- Team decides on primary BASE implementation
- Best features from all 7 merged
- Feature provenance documented (workflows, optimizations, persistence)
- Migration guide created
- All consumers updated
- Old implementations deprecated
- Tests passing
- Documentation updated
Estimated Effort
8-10 hours
Reactions are currently unavailable