System Overview
Agent Backend
The agent backend is the core service that powers OMNI’s AI capabilities.Request Flow
Key Components
| Component | Purpose |
|---|---|
| OmniAgent | Main agent orchestration |
| ToolRegistry | Tool discovery and execution |
| McpManager | MCP server connections |
| PermissionManager | Access control |
| SessionStorage | Session persistence |
Web App
Next.js application with:- Server components for initial render
- Client components for interactivity
- WebSocket for real-time updates
- IndexedDB for offline support
Desktop App
Electron application that:- Embeds the web app
- Provides native features (notifications, file access)
- Secure token storage via OS keychain
- Auto-updates via GitHub releases
Data Flow
Message Flow
Storage
Sessions
PostgreSQL for cross-device sync
Attachments
R2 for file storage
Credentials
OS keychain (desktop) or secure cookie (web)