forked from tonycho/Awesome-Agentic-AI
feat: Introduce mobile UI guide, update web and backend documentation for multi-agent "Crew AI" features, and address related technical debt.
This commit is contained in:
19
FIXME.md
19
FIXME.md
@@ -156,4 +156,21 @@ error: subprocess-exited-with-error
|
||||
× Getting requirements to build wheel did not run successfully.
|
||||
│ exit code: 1
|
||||
╰─> See above for output.
|
||||
```
|
||||
|
||||
# Latest Technical Debt & Blockers (Phase 11)
|
||||
|
||||
## 🔄 Circular Imports in MemoryManager
|
||||
- **Issue**: `MemoryManager` in `memory/memory_manager.py` was being imported in routes that it also depended on (e.g., `calendar_routes`).
|
||||
- **Fix**: Instantiated `memory = MemoryManager()` at the bottom of the file to provide a global object for import, rather than importing the class and instantiating it per-request.
|
||||
|
||||
## 📦 Missing Plugin Modules
|
||||
- **Issue**: `main.py` fails to load certain agents (e.g., `agents.custom_agent.CustomAgent`) if the submodules are not correctly placed in the python path.
|
||||
- **Action**: Ensure all agent subfolders have `__init__.py` and are listed in the `PYTHONPATH`.
|
||||
|
||||
## 🧪 Minimal Backend Requirement
|
||||
- **Issue**: The full `main.py` has heavy dependencies (SentenceTransformers, CLIP, LLMs) that make it slow to start and prone to failure in resource-constrained or restricted environments.
|
||||
- **Workaround**: Use `tests/minimal_backend.py` for targeted API verification of new routes (Crew, Notifications, Analytics).
|
||||
|
||||
## 📅 Google Calendar Credentials
|
||||
- **Issue**: Backend crashes if `credentials.json` is missing.
|
||||
- **Fix**: Wrapped initialization in a try-except block with a `MockCalendarService` fallback.
|
||||
|
||||
@@ -102,8 +102,16 @@ sqlite3 data/telemetry.db "SELECT * FROM usage_logs ORDER BY id DESC LIMIT 5;"
|
||||
|
||||
---
|
||||
|
||||
## 6. Wake Word (Optional)
|
||||
If using voice features with Picovoice:
|
||||
1. Get a `.ppn` file for your platform from Picovoice Console.
|
||||
2. Place it in `wakewords/`.
|
||||
3. Update `voice_listener.py` with the path.
|
||||
---
|
||||
|
||||
## 7. Crew & Collective AI (Phase 11)
|
||||
Phase 11 introduces multi-agent orchestration and cross-platform sync.
|
||||
|
||||
### 🚀 New Routes
|
||||
- **`/api/crew/trust-scores`**: Real-time reliability scores for all active agents.
|
||||
- **`/api/crew/active-treaties`**: Persistent agreements negotiated via the Diplomacy Protocol.
|
||||
- **`/admin/notify/register`**: Endpoint for native clients to subscribe to system alerts.
|
||||
|
||||
### 🛡️ Reliability & Mocking
|
||||
- **Google Calendar**: If `credentials.json` is missing, the system fallbacks to a `MockCalendarService` to prevent startup failure.
|
||||
- **Memory Management**: The `MemoryManager` is now instantiated globally in `memory/memory_manager.py` as `memory` to ensure consistent session state across all routes.
|
||||
|
||||
67
HOWTO_MOBILE.md
Normal file
67
HOWTO_MOBILE.md
Normal file
@@ -0,0 +1,67 @@
|
||||
# 📱 Mobile UI Development Guide (Flutter)
|
||||
|
||||
## 1. Project Overview
|
||||
The mobile interface is built with **Flutter** for cross-platform deployment (Android/iOS). It acts as a native client for the FastAPI backend.
|
||||
|
||||
### 📁 Folder Structure
|
||||
```
|
||||
mobile-flutter/
|
||||
├── lib/
|
||||
│ ├── main.dart # App Entry Point
|
||||
│ ├── screens/ # UI Screens
|
||||
│ │ ├── dashboard_screen.dart
|
||||
│ │ ├── crew_dashboard_screen.dart
|
||||
│ │ └── ...
|
||||
│ ├── services/ # Backend Data Services
|
||||
│ │ ├── crew_service.dart
|
||||
│ │ └── ...
|
||||
│ └── models/ # Data Models
|
||||
├── pubspec.yaml # Dependencies
|
||||
└── ...
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## 2. Setup & Installation
|
||||
|
||||
### 📦 Prerequisites
|
||||
- **Flutter SDK**: v3.x+
|
||||
- **Dart SDK**
|
||||
- **Android Studio** or **Xcode** (for emulators/deployment)
|
||||
|
||||
### 📥 Install Dependencies
|
||||
```bash
|
||||
cd mobile-flutter
|
||||
flutter pub get
|
||||
```
|
||||
|
||||
Key dependencies:
|
||||
- `http`: For REST API communication.
|
||||
- `provider` or `bloc`: (Optional) for state management.
|
||||
|
||||
---
|
||||
|
||||
## 3. Configuration
|
||||
|
||||
### 🔗 Backend URL
|
||||
The app expects the backend to be running at `http://localhost:8000`.
|
||||
- **Note**: When running on an Android emulator, use `http://10.0.2.2:8000`.
|
||||
- **Note**: When running on a physical device, use the local IP of your development machine.
|
||||
|
||||
---
|
||||
|
||||
## 4. Key Features
|
||||
|
||||
### 👥 Crew Monitoring (Phase 11)
|
||||
- **`CrewDashboardScreen`**: Aligned with the backend API.
|
||||
- **Data Mapping**:
|
||||
- `agent_role` -> Display Name
|
||||
- `score` -> Trust Indicator
|
||||
- `success` / `failure` -> Performance Stats
|
||||
|
||||
---
|
||||
|
||||
## 5. Running the App
|
||||
```bash
|
||||
flutter run
|
||||
```
|
||||
16
HOWTO_WEB.md
16
HOWTO_WEB.md
@@ -75,11 +75,15 @@ The UI will be available at `http://localhost:5173` (default).
|
||||
|
||||
---
|
||||
|
||||
## 5. Building for Production
|
||||
---
|
||||
|
||||
To build the static assets for deployment:
|
||||
## 6. Mission Control & Gradio (Phase 10/11)
|
||||
The **Mission Control** dashboard acts as the central hub for multi-agent coordination.
|
||||
|
||||
```bash
|
||||
npm run build
|
||||
```
|
||||
The output will be in `web/dist`.
|
||||
### 📊 Live Monitoring
|
||||
- **Gradio Integration**: A live monitoring feed is embedded in `web/src/dashboard/MissionControl.jsx`.
|
||||
- **Telemetry**: Real-time activity traces and trust scores are fetched from the `/api/crew` endpoints and displayed in reactive widgets.
|
||||
|
||||
### 🔧 Automation Hub
|
||||
- **Browser Automation**: Integrated with Playwright for agentic web navigation.
|
||||
- **Connectors**: Supports IMAP (Email) and CalDAV (Calendar) sync via the backend orchestration layer.
|
||||
|
||||
Reference in New Issue
Block a user