Overview
The web interface provides an interactive, visual dashboard for working with RepoMaster’s multi-agent system. Built with Streamlit, it offers a user-friendly chat interface with real-time agent collaboration visualization, file management, and multi-user session support.
Launching the Web Interface
Default Launch
Custom Port
Remote Access
Shell Script
python launcher.py --mode frontend
# Access at: http://localhost:8501
Configuration Options
Server Configuration
The web interface supports several configuration options from launcher.py:115-126:
Option Flag Default Description Port --streamlit-port8501 Web server port Host --streamlit-hostlocalhost Server host address Upload Limit --max-upload-size200 File upload size limit (MB) File Watcher --file-watcher-typeauto File watcher type
Production Setup
Development Setup
python launcher.py --mode frontend \
--streamlit-port 8501 \
--streamlit-host 0.0.0.0 \
--max-upload-size 500
File Upload Configuration
The --max-upload-size parameter controls the maximum file size for uploads:
Default : 200 MB
Range : 1 MB - 2000 MB (2 GB)
Larger files may cause performance issues on low-memory systems
Key Features
Multi-Agent Chat Interface
The web interface provides an interactive chat experience with:
Real-time messaging : Instant communication with AI agents
Rich message formatting : Markdown support for code, tables, and formatting
Agent visualization : See which agents are working on your task
Message history : Persistent conversation history per session
Agent Mode Selection
From app_autogen_enhanced.py:447-491, the interface supports four agent modes:
Mode Icon Description Unified 🧠 Automatically selects the best agent for your task DeepSearch 🔍 Advanced web search and information synthesis Programming Assistant 💻 Code generation and debugging assistance Repository Agent 📁 Repository exploration and task execution
The Unified mode is recommended for most users. It intelligently orchestrates multiple agents based on your task requirements.
File Management
The web interface includes comprehensive file handling capabilities:
File Upload
From app_autogen_enhanced.py:129-156, uploaded files are:
Saved to session-specific work directories
Automatically sanitized for safe filenames
Time-stamped to avoid naming conflicts
Limited by the configured upload size
File Browser
The integrated file browser (app_autogen_enhanced.py:553) allows you to:
View files generated by agents
Browse work directory contents
Access output files and artifacts
Session Management
Multi-User Support
The application supports both authenticated and guest users:
Guest Mode (app_autogen_enhanced.py:91-98):
No login required
6-character short ID assigned
Data saved in local session
Limited to browser session lifetime
Authenticated Mode :
Persistent user sessions
Long-term conversation history
Cross-device access
Chat History
From app_autogen_enhanced.py:262-385, the interface provides:
Automatic conversation saving
Chat preview with timestamps
Message count indicators
Easy conversation switching
Delete conversation functionality
Work Directory Isolation
Each chat session gets an isolated work directory (app_autogen_enhanced.py:806-813):
work_dir = f " { pwd } /coding/ { user_id } / { chat_id } "
This ensures:
No file conflicts between sessions
Clean workspace per conversation
Easy cleanup and management
User Interface Components
Navigation
The top navigation bar displays:
Application title: “Code RepoMaster”
User identification (username or “Guest”)
Session status
The sidebar includes:
Chat Management - Create new chats
Chat History - Browse past conversations
Agent Mode Selector - Choose agent mode
User Status - Login/logout controls
Main Chat Area
The central chat interface features:
Welcome message for new conversations
Message thread with user/AI avatars
Timestamp for each message
File upload area above input
Chat input box at bottom
Message Display
Messages are rendered with (app_autogen_enhanced.py:588-615):
Role indicators (User/AI)
Avatar icons (👤 for user, ✨ for AI)
Timestamps (HH:MM format)
Markdown formatting support
Data Persistence
The web interface stores data in the data/ directory:
File Pattern Purpose {user_id}_past_chatsChat list and metadata {user_id}_{chat_id}_messagesRaw message history {user_id}_{chat_id}_display_messagesFormatted display messages
From app_autogen_enhanced.py:100-127, data is managed using joblib for serialization.
Best Practices
For better performance:
Keep upload file sizes reasonable (< 100 MB when possible)
Clear old conversation history periodically
Use localhost for single-user scenarios
Enable debug logging only when troubleshooting
Security Considerations
When exposing to network (--streamlit-host 0.0.0.0):
Use a firewall to restrict access
Consider implementing authentication
Monitor upload activity
Regularly review user sessions
File Management
Monitor disk space : Work directories can grow large
Regular cleanup : Remove old chat sessions
Backup important outputs : Save valuable generated files elsewhere
Troubleshooting
Port Already in Use
If port 8501 is already in use:
python launcher.py --mode frontend --streamlit-port 8502
Upload Fails
If file uploads fail:
Check file size against --max-upload-size limit
Verify disk space availability
Check file permissions in work directory
Session Not Persisting
If chat history doesn’t persist:
Verify data/ directory exists and is writable
Check for joblib serialization errors in logs
Ensure sufficient disk space
If the interface is slow:
Reduce --max-upload-size if not needed
Clear old conversation history
Check system memory usage
Review agent processing logs with --log-level DEBUG
Technical Details
Startup Command
From launcher.py:115-136, the frontend mode constructs:
cmd = [
sys.executable, "-m" , "streamlit" , "run" ,
"src/frontend/app_autogen_enhanced.py" ,
"--server.port" , str (config.streamlit_port),
"--server.address" , config.streamlit_host,
"--server.fileWatcherType" , config.file_watcher_type,
"--server.maxUploadSize" , str (config.max_upload_size)
]
File Upload Processing
File uploads are handled with safety measures (app_autogen_enhanced.py:158-184):
Filename sanitization (remove dangerous characters)
Length truncation (max 100 characters)
Timestamp addition (prevent conflicts)
Safe path construction (prevent directory traversal)
Chat ID Generation
Chat IDs use timestamp-based generation (app_autogen_enhanced.py:75-77):
def generate_chat_id () -> str :
return f ' { time.time() } ' .replace( '.' , '_' )
See Also