Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8d28e163a4 | ||
|
|
d61c5c15e2 | ||
|
|
b7bb62e03f | ||
|
|
a3af402f73 |
@@ -1,90 +1,60 @@
|
||||
{
|
||||
"schema_version": 1,
|
||||
"mission_id": "ms21-multi-tenant-rbac-data-migration-20260228",
|
||||
"name": "MS21 Multi-Tenant RBAC Data Migration",
|
||||
"description": "Build multi-tenant user/workspace/team management, break-glass auth, RBAC UI enforcement, and migrate jarvis-brain data into Mosaic Stack",
|
||||
"mission_id": "fleet-evolution-20260228",
|
||||
"name": "Fleet Evolution",
|
||||
"description": "Multi-agent fleet with persistent knowledge layer, OpenClaw as runtime, Mosaic as management plane",
|
||||
"project_path": "/home/jwoltje/src/mosaic-stack",
|
||||
"created_at": "2026-02-28T17:10:22Z",
|
||||
"created_at": "2026-03-01T01:21:19Z",
|
||||
"status": "active",
|
||||
"task_prefix": "MS21",
|
||||
"task_prefix": "MS22",
|
||||
"quality_gates": "pnpm lint && pnpm build && pnpm test",
|
||||
"milestone_version": "0.0.21",
|
||||
"milestone_version": "0.5.0",
|
||||
"milestones": [
|
||||
{
|
||||
"id": "phase-1",
|
||||
"name": "Schema and Admin API",
|
||||
"name": "Knowledge Layer",
|
||||
"status": "pending",
|
||||
"branch": "schema-and-admin-api",
|
||||
"branch": "knowledge-layer",
|
||||
"issue_ref": "",
|
||||
"started_at": "",
|
||||
"completed_at": ""
|
||||
},
|
||||
{
|
||||
"id": "phase-2",
|
||||
"name": "Break-Glass Authentication",
|
||||
"name": "Agent Fleet Standup",
|
||||
"status": "pending",
|
||||
"branch": "break-glass-authentication",
|
||||
"branch": "agent-fleet-standup",
|
||||
"issue_ref": "",
|
||||
"started_at": "",
|
||||
"completed_at": ""
|
||||
},
|
||||
{
|
||||
"id": "phase-3",
|
||||
"name": "Data Migration",
|
||||
"name": "WebUI Chat + Tasks",
|
||||
"status": "pending",
|
||||
"branch": "data-migration",
|
||||
"branch": "webui-chat-tasks",
|
||||
"issue_ref": "",
|
||||
"started_at": "",
|
||||
"completed_at": ""
|
||||
},
|
||||
{
|
||||
"id": "phase-4",
|
||||
"name": "Admin UI",
|
||||
"name": "LLM Provider Management",
|
||||
"status": "pending",
|
||||
"branch": "admin-ui",
|
||||
"branch": "llm-provider-management",
|
||||
"issue_ref": "",
|
||||
"started_at": "",
|
||||
"completed_at": ""
|
||||
},
|
||||
{
|
||||
"id": "phase-5",
|
||||
"name": "RBAC UI Enforcement",
|
||||
"name": "Installer + Polish",
|
||||
"status": "pending",
|
||||
"branch": "rbac-ui-enforcement",
|
||||
"issue_ref": "",
|
||||
"started_at": "",
|
||||
"completed_at": ""
|
||||
},
|
||||
{
|
||||
"id": "phase-6",
|
||||
"name": "Verification",
|
||||
"status": "pending",
|
||||
"branch": "verification",
|
||||
"branch": "installer-polish",
|
||||
"issue_ref": "",
|
||||
"started_at": "",
|
||||
"completed_at": ""
|
||||
}
|
||||
],
|
||||
"sessions": [
|
||||
{
|
||||
"session_id": "sess-001",
|
||||
"runtime": "unknown",
|
||||
"started_at": "2026-02-28T17:48:51Z",
|
||||
"ended_at": "",
|
||||
"ended_reason": "",
|
||||
"milestone_at_end": "",
|
||||
"tasks_completed": [],
|
||||
"last_task_id": ""
|
||||
},
|
||||
{
|
||||
"session_id": "sess-002",
|
||||
"runtime": "unknown",
|
||||
"started_at": "2026-02-28T20:30:13Z",
|
||||
"ended_at": "",
|
||||
"ended_reason": "",
|
||||
"milestone_at_end": "",
|
||||
"tasks_completed": [],
|
||||
"last_task_id": ""
|
||||
}
|
||||
]
|
||||
"sessions": []
|
||||
}
|
||||
|
||||
@@ -34,3 +34,9 @@ CVE-2026-26996 # HIGH: minimatch DoS via specially crafted glob patterns (needs
|
||||
# OpenBao 2.5.0 compiled with Go 1.25.6, fix needs Go >= 1.25.7.
|
||||
# Cannot build OpenBao from source (large project). Waiting for upstream release.
|
||||
CVE-2025-68121 # CRITICAL: crypto/tls session resumption
|
||||
|
||||
# === multer CVEs (upstream via @nestjs/platform-express) ===
|
||||
# multer <2.1.0 — waiting on NestJS to update their dependency
|
||||
# These are DoS vulnerabilities in file upload handling
|
||||
GHSA-xf7r-hgr6-v32p # HIGH: DoS via incomplete cleanup
|
||||
GHSA-v52c-386h-88mc # HIGH: DoS via resource exhaustion
|
||||
|
||||
+45
-27
@@ -1,52 +1,70 @@
|
||||
# Mission Manifest — MS21 Multi-Tenant RBAC Data Migration
|
||||
# Mission Manifest — Fleet Evolution
|
||||
|
||||
> Persistent document tracking full mission scope, status, and session history.
|
||||
> Updated by the orchestrator at each phase transition and milestone completion.
|
||||
|
||||
## Mission
|
||||
|
||||
**ID:** ms21-multi-tenant-rbac-data-migration-20260228
|
||||
**Statement:** Build multi-tenant user/workspace/team management, break-glass auth, RBAC UI enforcement, and migrate jarvis-brain data into Mosaic Stack
|
||||
**Phase:** Intake
|
||||
**Current Milestone:** —
|
||||
**Progress:** 0 / 6 milestones
|
||||
**ID:** fleet-evolution-20260228
|
||||
**Statement:** Multi-agent fleet with persistent knowledge layer, OpenClaw as runtime, Mosaic as management plane
|
||||
**Phase:** Phase 1 — Knowledge Layer
|
||||
**Current Milestone:** MS22-P0
|
||||
**Progress:** 0 / 5 milestones
|
||||
**Status:** active
|
||||
**Last Updated:** 2026-02-28 17:10 UTC
|
||||
**Last Updated:** 2026-03-01 01:21 UTC
|
||||
**PRD:** docs/PRD-MS22.md
|
||||
|
||||
## Success Criteria
|
||||
|
||||
<!-- Define measurable success criteria here -->
|
||||
1. An agent writes a finding → another agent searches and retrieves it (context crosses agent boundaries)
|
||||
2. A user chats with any agent via WebUI and sees streamed responses
|
||||
3. Semantic search returns relevant findings and conversation history
|
||||
4. LLM providers configurable via WebUI with per-agent model assignment
|
||||
5. Matrix rooms show mirrored agent activity within 5 seconds
|
||||
6. Single-command installer provisions a working 3-agent fleet in < 10 minutes
|
||||
7. A non-technical user can interact with agents via natural language (no commands)
|
||||
8. Context from day 1 is still searchable on day 30 (zero context loss)
|
||||
|
||||
## Milestones
|
||||
|
||||
| # | ID | Name | Status | Branch | Issue | Started | Completed |
|
||||
| --- | ------- | -------------------------- | ------- | ------ | ----- | ------- | --------- |
|
||||
| 1 | phase-1 | Schema and Admin API | pending | — | — | — | — |
|
||||
| 2 | phase-2 | Break-Glass Authentication | pending | — | — | — | — |
|
||||
| 3 | phase-3 | Data Migration | pending | — | — | — | — |
|
||||
| 4 | phase-4 | Admin UI | pending | — | — | — | — |
|
||||
| 5 | phase-5 | RBAC UI Enforcement | pending | — | — | — | — |
|
||||
| 6 | phase-6 | Verification | pending | — | — | — | — |
|
||||
| # | ID | Name | Status | Branch | Issue | Started | Completed |
|
||||
| --- | ------- | ----------------------- | ------- | ------ | ----- | ---------- | --------- |
|
||||
| 1 | phase-1 | Knowledge Layer | active | — | — | 2026-02-28 | — |
|
||||
| 2 | phase-2 | Agent Fleet Standup | pending | — | — | — | — |
|
||||
| 3 | phase-3 | WebUI Chat + Tasks | pending | — | — | — | — |
|
||||
| 4 | phase-4 | LLM Provider Management | pending | — | — | — | — |
|
||||
| 5 | phase-5 | Installer + Polish | pending | — | — | — | — |
|
||||
|
||||
## Deployment
|
||||
|
||||
| Target | URL | Method |
|
||||
| ------ | --- | ------ |
|
||||
| — | — | — |
|
||||
| Target | URL | Method |
|
||||
| ---------- | ----------------------------------------- | ------------------------ |
|
||||
| Production | mosaic.woltje.com / mosaic-api.woltje.com | Docker Swarm (10.1.1.45) |
|
||||
| CI | ci.mosaicstack.dev | Woodpecker |
|
||||
| Git | git.mosaicstack.dev | Gitea |
|
||||
|
||||
## Token Budget
|
||||
|
||||
| Metric | Value |
|
||||
| ------ | ------ |
|
||||
| Budget | — |
|
||||
| Used | 0 |
|
||||
| Mode | normal |
|
||||
| Metric | Value |
|
||||
| --------------- | ----------------------------------- |
|
||||
| Estimated Total | ~588K |
|
||||
| Used | 0 |
|
||||
| Mode | normal |
|
||||
| Primary Worker | Codex (OpenAI budget) |
|
||||
| Fallback Worker | Sonnet (Claude budget, 1 at a time) |
|
||||
|
||||
## Session History
|
||||
|
||||
| Session | Runtime | Started | Duration | Ended Reason | Last Task |
|
||||
| ------- | ------- | ------- | -------- | ------------ | --------- |
|
||||
| Session | Runtime | Started | Duration | Ended Reason | Last Task |
|
||||
| ------- | ------------------- | ---------------- | -------- | ------------ | ----------------- |
|
||||
| 1 | Opus (orchestrator) | 2026-02-28 19:00 | — | — | Mission bootstrap |
|
||||
|
||||
## Planning Documents
|
||||
|
||||
- Fleet Evolution Plan: `~/src/jarvis-brain/docs/planning/FLEET-EVOLUTION-PLAN.md`
|
||||
- Matrix Design Resolved: `~/src/jarvis-brain/docs/planning/matrix-agent-communication-RESOLVED.md`
|
||||
- Agent Personalities: `~/src/jarvis-brain/agents/`
|
||||
|
||||
## Scratchpad
|
||||
|
||||
Path: `docs/scratchpads/ms21-multi-tenant-rbac-data-migration-20260228.md`
|
||||
Path: `docs/scratchpads/fleet-evolution-20260228.md`
|
||||
|
||||
@@ -0,0 +1,286 @@
|
||||
# PRD: Fleet Evolution — Multi-Agent Knowledge Layer & Management Plane
|
||||
|
||||
## Metadata
|
||||
|
||||
- Owner: Jason Woltje
|
||||
- Date: 2026-02-28
|
||||
- Status: draft
|
||||
- Best-Guess Mode: true
|
||||
- Mission: MS22
|
||||
- Planning Docs:
|
||||
- `~/src/jarvis-brain/docs/planning/FLEET-EVOLUTION-PLAN.md`
|
||||
- `~/src/jarvis-brain/docs/planning/matrix-agent-communication-RESOLVED.md`
|
||||
|
||||
## Problem Statement
|
||||
|
||||
Mosaic Stack manages projects, users, and infrastructure but has no integration with the AI agents that do the actual work. OpenClaw runs those agents but has no persistent knowledge layer — context is lost on every compaction and session boundary. Agents cannot collaborate, share findings, or build on each other's work. There is no unified interface for users to interact with agents, manage LLM providers, or observe agent activity.
|
||||
|
||||
**Why now:** MS21 (multi-tenant RBAC) is complete. The platform has users, roles, and workspaces. The next logical layer is the intelligence that operates within them.
|
||||
|
||||
## Objectives
|
||||
|
||||
1. Eliminate context loss across agent sessions via a persistent, searchable knowledge layer in Postgres + pgvector
|
||||
2. Enable inter-agent collaboration through structured Task and Findings APIs (not chat)
|
||||
3. Provide a WebUI for users to chat with agents, manage tasks, and search findings
|
||||
4. Support multi-LLM provider configuration with per-agent model assignment
|
||||
5. Mirror agent activity to Matrix rooms for observability and audit
|
||||
6. Make the entire system installable via a scripted setup process
|
||||
|
||||
## Scope
|
||||
|
||||
### In Scope
|
||||
|
||||
1. Knowledge layer schema (findings, agent_memory, tasks enhancements, conversation_archive)
|
||||
2. Task API with state machine, assignment, and parent/child relationships
|
||||
3. Findings API with vector similarity search
|
||||
4. Agent memory API (per-agent key/value, cross-agent readable)
|
||||
5. OpenClaw session log ingestion pipeline (JSONL → Postgres → pgvector embeddings)
|
||||
6. OpenClaw `mosaic` skill (CLI wrapper for agents to access the knowledge layer)
|
||||
7. OpenClaw multi-agent provisioning (jarvis, builder, medic — with SOUL.md, model config, tool permissions)
|
||||
8. Discord channel bindings for agent interaction
|
||||
9. Matrix observation room auto-provisioning and async mirroring (via existing bridge module)
|
||||
10. WebSocket chat endpoint (Mosaic API → OpenClaw session proxy)
|
||||
11. WebUI chat component with agent selector
|
||||
12. Task management UI (create, assign, track, view findings)
|
||||
13. Agent registry UI (status, model, channel, last active)
|
||||
14. Findings search UI (semantic search across all agent output)
|
||||
15. LLM provider management UI (add/remove/test providers, per-agent assignment, fallback chains)
|
||||
16. Usage/cost dashboard per provider and per agent
|
||||
17. Provider health monitoring (latency, errors, rate limits)
|
||||
18. Scripted installer (`openclaw skills install mosaic-fleet` or equivalent)
|
||||
19. Interactive setup wizard (detect stack, provision agents, bind channels, configure providers)
|
||||
20. Data retention policy (configurable per-workspace in WebUI, stored in DB)
|
||||
|
||||
### Out of Scope
|
||||
|
||||
1. Matrix federation between Mosaic Stack deployments (federation stays at Mosaic level)
|
||||
2. More than 3 initial agents (additional agents added organically when workflows justify)
|
||||
3. Agent-to-agent direct chat (collaboration is via Task/Findings API)
|
||||
4. Rebuilding agent execution logic in Mosaic (OpenClaw is the runtime)
|
||||
5. Per-agent Docker containers (agents are OpenClaw workspace configs, not separate images)
|
||||
6. Mobile-native apps (Discord serves as mobile surface)
|
||||
7. Billing/payment integration for LLM providers
|
||||
8. Voice/audio agent interaction
|
||||
|
||||
## User/Stakeholder Requirements
|
||||
|
||||
1. **Jason (admin/power user):** Must be able to configure agents, providers, and channels from WebUI without editing config files
|
||||
2. **Non-technical user (e.g., spouse):** Must be able to chat with agents via WebUI or Discord using natural language — no commands or technical knowledge required
|
||||
3. **Agents:** Must be able to read/write findings, query task state, and access other agents' public memory via the mosaic skill — with zero knowledge of Matrix or Discord internals
|
||||
4. **System:** Must persist all agent-produced data (findings, memory, conversations) in Postgres with vector embeddings for semantic search. Must survive compaction, session restarts, and agent reprovisioning.
|
||||
|
||||
## Functional Requirements
|
||||
|
||||
### FR-01: Knowledge Layer Schema
|
||||
|
||||
- `findings` table: id (UUID), task_id (FK nullable), agent_id (string), type (string), data (JSONB), embedding (vector), created_at, updated_at
|
||||
- `agent_memory` table: id (UUID), agent_id (string), key (string), value (JSONB), updated_at. Unique constraint on (agent_id, key).
|
||||
- `tasks` table enhancements: status enum with state machine (not-started → in-progress → awaiting-verification → done | blocked | cancelled), assigned_agent (string), parent_task_id (FK nullable), priority (enum), findings (relation)
|
||||
- `conversation_archive` table: id (UUID), session_id (string), agent_id (string), messages (JSONB), summary (text), embedding (vector), created_at
|
||||
- All tables use pgvector for embedding columns
|
||||
|
||||
### FR-02: Task API
|
||||
|
||||
- `POST /api/tasks` — Create task with title, description, type, priority, assigned_agent, parent_task_id
|
||||
- `GET /api/tasks` — List with filters (status, agent, type, parent)
|
||||
- `GET /api/tasks/:id` — Get task with findings and sub-tasks
|
||||
- `PATCH /api/tasks/:id` — Update status (enforces state machine), assignment, priority
|
||||
- State transitions: not-started → in-progress → awaiting-verification → done; any → blocked; any → cancelled
|
||||
- Webhook/event emission on state change (for triggering downstream agent sessions)
|
||||
|
||||
### FR-03: Findings API
|
||||
|
||||
- `POST /api/findings` — Write finding with task_id, agent_id, type, data (auto-generates embedding)
|
||||
- `GET /api/findings` — List with filters (agent, type, task, date range)
|
||||
- `POST /api/findings/search` — Vector similarity search with query text, optional filters (agent, type, date range), returns ranked results with scores
|
||||
- Embedding generation: use configured embedding model (OpenAI text-embedding-3-small or local alternative)
|
||||
|
||||
### FR-04: Agent Memory API
|
||||
|
||||
- `PUT /api/agents/:id/memory/:key` — Write/update a memory entry
|
||||
- `GET /api/agents/:id/memory` — List all memory entries for an agent
|
||||
- `GET /api/agents/:id/memory/:key` — Get specific entry
|
||||
- `DELETE /api/agents/:id/memory/:key` — Remove entry
|
||||
- Cross-agent read: any agent can read any other agent's memory (no write across agents)
|
||||
|
||||
### FR-05: Conversation Archive API
|
||||
|
||||
- `POST /api/conversations/ingest` — Accept OpenClaw JSONL session data, parse, embed, store
|
||||
- `POST /api/conversations/search` — Semantic search across archived conversations
|
||||
- `GET /api/conversations` — List with filters (agent, date range, session_id)
|
||||
- Ingestion pipeline: scheduled job or webhook that watches OpenClaw session log directory
|
||||
|
||||
### FR-06: Mosaic Skill for OpenClaw
|
||||
|
||||
- OpenClaw skill installed in each agent's workspace
|
||||
- SKILL.md documenting all available commands
|
||||
- CLI commands wrapping Task, Findings, Memory, and Conversation APIs
|
||||
- Authentication via API key or token stored in agent's workspace config
|
||||
- Commands:
|
||||
- `mosaic task list|get|update`
|
||||
- `mosaic finding write|search`
|
||||
- `mosaic agent memory read|write`
|
||||
- `mosaic agent status`
|
||||
- `mosaic conversation search`
|
||||
|
||||
### FR-07: Agent Provisioning
|
||||
|
||||
- OpenClaw multi-agent configuration for 3 initial agents: jarvis, builder, medic
|
||||
- Each agent has: SOUL.md (personality), AGENTS.md (operational rules), USER.md (shared user context), TOOLS.md, MEMORY.md, memory/
|
||||
- Per-agent model config: jarvis=opus, builder=codex/sonnet, medic=haiku
|
||||
- Per-agent tool permissions: medic=exec(SSH)+cron, builder=exec+github+read+write, jarvis=all
|
||||
- mosaic skill installed in each workspace
|
||||
|
||||
### FR-08: Channel Bindings
|
||||
|
||||
- Discord: agent-specific channels (#jarvis, #builder, #medic-alerts, #agent-status)
|
||||
- Matrix: per-agent observation rooms, per-project rooms, #mosaic-ops system room
|
||||
- Matrix rooms auto-created when agents provisioned or projects created
|
||||
- Matrix rooms E2E encrypted by default
|
||||
- Async fire-and-forget mirroring: Mosaic API mirrors findings/status to Matrix rooms (no agent inference cost)
|
||||
|
||||
### FR-09: WebSocket Chat
|
||||
|
||||
- `WS /api/chat` — WebSocket endpoint accepting agent_id, message, returning streamed response
|
||||
- Proxies to OpenClaw agent session via OpenClaw's session API
|
||||
- Message persistence in conversation_archive
|
||||
- Support for multiple concurrent chats (one per agent)
|
||||
|
||||
### FR-10: WebUI Components
|
||||
|
||||
- Chat component: agent selector dropdown, message input, streaming response display, conversation history
|
||||
- Task management: create task form, kanban or list view, task detail with findings, assign agent
|
||||
- Agent registry: card/list view showing agent name, role, model, status, last active, channel
|
||||
- Findings search: search bar with semantic query, filters (agent, type, date), ranked results
|
||||
- Data retention settings: per-workspace retention_days config
|
||||
|
||||
### FR-11: LLM Provider Management
|
||||
|
||||
- Provider CRUD: add/remove/configure providers (Anthropic, OpenAI, GLM/Z.ai, Ollama, MiniMax, OpenRouter)
|
||||
- Per-provider config: API key/endpoint, model list, rate limits, enabled/disabled
|
||||
- Connection test: verify provider is reachable and authenticated
|
||||
- Per-agent model assignment: primary model + fallback chain
|
||||
- ASSUMPTION: Provider config stored in Mosaic DB, synced to OpenClaw at runtime via API call. Rationale: single source of truth, no file sync needed.
|
||||
|
||||
### FR-12: Usage Dashboard
|
||||
|
||||
- Token count tracking per agent per provider
|
||||
- Cost estimation (where provider publishes pricing)
|
||||
- Rate limit status display (for providers that expose it)
|
||||
- Time-series charts: usage over time (daily/weekly/monthly)
|
||||
- ASSUMPTION: Usage data collected from OpenClaw session logs during ingestion. Rationale: OpenClaw already tracks token counts in JSONL logs.
|
||||
|
||||
### FR-13: Provider Health Monitoring
|
||||
|
||||
- Endpoint latency tracking (per request average, p95, p99)
|
||||
- Error rate tracking (4xx, 5xx, timeouts)
|
||||
- Status indicator per provider (healthy/degraded/down)
|
||||
- ASSUMPTION: Health data collected passively from OpenClaw request logs, not active probing. Rationale: avoids unnecessary API calls and billing.
|
||||
|
||||
### FR-14: Installer
|
||||
|
||||
- Single command to install: `openclaw skills install mosaic-fleet` or `npx mosaic-fleet init`
|
||||
- Interactive wizard:
|
||||
- Detect existing Mosaic Stack (URL, API key)
|
||||
- Provision agent workspaces (create directories, write SOUL.md files)
|
||||
- Configure channel bindings (Discord bot token, Matrix homeserver)
|
||||
- Set up LLM providers (API keys, endpoints)
|
||||
- Verify connectivity (Mosaic API, Discord, Matrix, LLM providers)
|
||||
- Idempotent: safe to re-run for updates or adding agents
|
||||
|
||||
## Non-Functional Requirements
|
||||
|
||||
1. **Security:**
|
||||
- Agent API keys stored encrypted in Mosaic DB (existing credential management)
|
||||
- LLM provider API keys encrypted at rest
|
||||
- Matrix rooms E2E encrypted
|
||||
- Cross-agent memory read-only (agents cannot write to other agents' memory)
|
||||
- No Matrix federation (local bus only)
|
||||
- Retention policies enforced via scheduled Postgres cleanup job
|
||||
|
||||
2. **Performance:**
|
||||
- Findings vector search: < 200ms for 95th percentile (pgvector with HNSW index)
|
||||
- WebSocket chat: first token < 2s (dependent on LLM provider latency)
|
||||
- Matrix mirroring: async, fire-and-forget, < 500ms overhead on finding writes
|
||||
- Conversation ingestion: batch processing, not blocking agent sessions
|
||||
|
||||
3. **Reliability:**
|
||||
- Knowledge layer is Postgres — same backup/HA as existing Mosaic DB
|
||||
- Agent sessions managed by OpenClaw (existing restart/reconnect logic)
|
||||
- Provider failover: if primary model fails, automatically try fallback chain
|
||||
- Valkey cache for hot task state; Postgres for durability
|
||||
|
||||
4. **Observability:**
|
||||
- Matrix rooms serve as human-readable audit trail
|
||||
- Agent activity logged in conversation_archive
|
||||
- Provider health metrics exposed via dashboard
|
||||
- Task state changes logged with timestamps and actor
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
1. An agent can write a finding via the mosaic skill and another agent can search for and retrieve it
|
||||
2. Task state changes trigger downstream agent sessions (e.g., Builder completes → Medic verifies)
|
||||
3. A user can chat with any agent via the WebUI and see responses streamed in real-time
|
||||
4. A user can search across all agent findings and conversation history semantically
|
||||
5. LLM providers can be added, configured, and tested from the WebUI
|
||||
6. Per-agent model assignment works: changing an agent's model in WebUI changes its behavior
|
||||
7. Usage dashboard shows accurate token counts per agent per provider
|
||||
8. Matrix observation rooms show mirrored agent activity within 5 seconds of the finding being written
|
||||
9. The installer provisions a working 3-agent fleet from scratch in < 10 minutes
|
||||
10. Data retention policies are enforced: findings older than retention_days are purged on schedule
|
||||
11. Context survives: an agent's finding from day 1 is still searchable on day 30 via the mosaic skill
|
||||
|
||||
## Constraints and Dependencies
|
||||
|
||||
1. **OpenClaw multi-agent support** — must support per-agent workspaces, model config, tool permissions, and channel bindings. Current version appears to support this; verify during Phase 1.
|
||||
2. **pgvector extension** — must be enabled in production Postgres (already available in standard Postgres images)
|
||||
3. **Embedding model** — need an embedding provider configured for vector generation. ASSUMPTION: Use OpenAI text-embedding-3-small initially; support local alternatives (Ollama) later. Rationale: most reliable, cheapest per-token for embeddings.
|
||||
4. **Existing Mosaic Stack modules** — Task API extends existing task infrastructure; Matrix bridge extends existing `apps/api/src/bridge/matrix/` module; LLM provider management extends existing `apps/api/src/llm/providers/`
|
||||
5. **Discord bot** — already configured via OpenClaw; channel bindings extend existing setup
|
||||
6. **Synapse** — already deployed; disable federation, enable E2E encryption
|
||||
7. **Woodpecker CI** — existing CI pipeline; docs-only PRs may need path trigger fix from MS21 leftovers
|
||||
|
||||
## Risks and Open Questions
|
||||
|
||||
1. **Risk:** OpenClaw multi-agent API may not support all needed features (tool restrictions, per-agent model override). Mitigation: verify early in Phase 1; fall back to separate OpenClaw instances if needed.
|
||||
2. **Risk:** pgvector embedding quality affects search relevance. Mitigation: test with representative queries; tune embedding model and similarity thresholds.
|
||||
3. **Risk:** WebSocket chat proxy may add latency or reliability issues. Mitigation: benchmark during Phase 2; consider SSE as alternative.
|
||||
4. **Open Question:** How does OpenClaw expose session creation API for Mosaic to proxy chat? Research during Phase 1.
|
||||
5. **Open Question:** What triggers a Medic agent session on task state change? Options: (a) Mosaic webhook → OpenClaw, (b) OpenClaw cron/heartbeat polls Mosaic, (c) Mosaic directly invokes OpenClaw session API. ASSUMPTION: Option (a) — Mosaic sends webhook to OpenClaw on task state change. Rationale: event-driven is more efficient than polling.
|
||||
6. **Open Question:** Embedding generation — synchronous on write or async batch? ASSUMPTION: Async via queue/cron. Rationale: don't block finding writes on embedding API calls.
|
||||
7. **Risk:** Conversation archive could grow large. Mitigation: retention policies + partitioning by date.
|
||||
|
||||
## Testing and Verification Expectations
|
||||
|
||||
1. **Baseline checks:** `pnpm lint && pnpm build && pnpm test` must pass (existing quality gates)
|
||||
2. **API tests:** Each new endpoint (tasks, findings, memory, conversations, chat) must have integration tests
|
||||
3. **E2E tests:** Agent writes finding → another agent searches and finds it (round-trip via mosaic skill)
|
||||
4. **WebUI tests:** Chat component renders, sends message, receives streamed response
|
||||
5. **Installer test:** Run installer on clean environment, verify all 3 agents respond correctly
|
||||
6. **Evidence format:** PR descriptions include test results, CI green confirmation
|
||||
|
||||
## Milestone / Delivery Intent
|
||||
|
||||
### MS22: Fleet Evolution
|
||||
|
||||
| Phase | Name | Target | Definition of Done |
|
||||
| ----- | ------------------------------ | ------ | ------------------------------------------------------------------------------------ |
|
||||
| P0 | Knowledge Layer + Mosaic Skill | v0.1.0 | Schema deployed, APIs working, mosaic skill installed, session log ingestion running |
|
||||
| P1 | Agent Fleet Standup | v0.2.0 | 3 agents responding in Discord, reading/writing findings, Matrix rooms active |
|
||||
| P2 | WebUI Chat + Task Management | v0.3.0 | Users can chat with agents in WebUI, create/track tasks, search findings |
|
||||
| P3 | LLM Provider Management | v0.4.0 | Providers configurable in WebUI, per-agent model assignment, usage dashboard |
|
||||
| P4 | Installer + Polish | v0.5.0 | Single-command install, interactive wizard, documentation complete |
|
||||
|
||||
Target version: v0.5.0 (full fleet)
|
||||
Definition of done: A non-technical user can install the fleet, chat with agents in WebUI and Discord, and agents collaborate via shared knowledge layer with zero context loss.
|
||||
|
||||
## Assumptions
|
||||
|
||||
1. ASSUMPTION: Provider config stored in Mosaic DB, synced to OpenClaw via API. Rationale: single source of truth, avoids config file drift.
|
||||
2. ASSUMPTION: Use OpenAI text-embedding-3-small for embeddings initially. Rationale: reliable, cheap, well-supported. Can swap to Ollama later.
|
||||
3. ASSUMPTION: Mosaic webhook → OpenClaw for task state change triggers. Rationale: event-driven > polling, lower latency.
|
||||
4. ASSUMPTION: Embedding generation is async (queue/cron, not synchronous on write). Rationale: don't block agent work on external API calls.
|
||||
5. ASSUMPTION: Usage data harvested from OpenClaw session logs during ingestion. Rationale: data already exists in JSONL, no separate telemetry needed.
|
||||
6. ASSUMPTION: Provider health data collected passively from request logs. Rationale: avoids unnecessary API calls and billing.
|
||||
7. ASSUMPTION: Matrix rooms are local only (no federation). Rationale: per Jason's decision — federation at Mosaic Stack level, not Matrix level.
|
||||
8. ASSUMPTION: Start with 3 agents (jarvis, builder, medic). Rationale: per Jason's direction — add agents when workflows justify, not speculatively.
|
||||
+71
-47
@@ -1,54 +1,78 @@
|
||||
# Tasks — MS21 Multi-Tenant RBAC Data Migration
|
||||
# Tasks — MS22 Fleet Evolution
|
||||
|
||||
> Single-writer: orchestrator (Jarvis/OpenClaw) only. Workers read but never modify.
|
||||
> Schema: id | status | milestone | description | issue | repo | branch | depends_on | blocks | agent | started_at | completed_at | estimate | used | notes
|
||||
|
||||
| id | status | milestone | description | issue | repo | branch | depends_on | blocks | agent | started_at | completed_at | estimate | used | notes |
|
||||
| -------------- | ----------- | --------- | --------------------------------------------------------------------------------- | -------- | ----- | ------------------------------ | ----------------------------------------------------------- | -------------------------- | --------------- | ---------- | ------------ | -------- | ---- | --------------------------------------------------------------------------------------------------------------------- |
|
||||
| MS21-PLAN-001 | done | phase-1 | Write PRD, init mission, populate TASKS.md | TASKS:P1 | stack | chore/ms21-init | — | MS21-DB-001 | orchestrator | 2026-02-28 | 2026-02-28 | 10K | 12K | PR #552, CI green |
|
||||
| MS21-DB-001 | done | phase-1 | Prisma migration: add user fields | TASKS:P1 | api | feat/ms21-schema | MS21-PLAN-001 | MS21-API-001 | claude-worker-1 | 2026-02-28 | 2026-02-28 | 10K | 9K | PR #553, CI green |
|
||||
| MS21-API-001 | done | phase-1 | AdminModule with user/workspace admin endpoints | TASKS:P1 | api | feat/ms21-admin-api | MS21-DB-001 | MS21-TEST-001 | claude-worker-2 | 2026-02-28 | 2026-02-28 | 20K | 18K | PR #555, CI green |
|
||||
| MS21-API-002 | done | phase-1 | Admin user endpoints (list, invite, update, deactivate) | TASKS:P1 | api | feat/ms21-admin-api | MS21-DB-001 | MS21-TEST-001 | claude-worker-2 | 2026-02-28 | 2026-02-28 | — | — | Combined with API-001 |
|
||||
| MS21-API-003 | done | phase-1 | Workspace member management endpoints | TASKS:P1 | api | feat/ms21-workspace-members | MS21-DB-001 | — | codex-worker-1 | 2026-02-28 | 2026-02-28 | 15K | 14K | PR #556, CI green |
|
||||
| MS21-API-004 | done | phase-1 | Team management module | TASKS:P1 | api | feat/ms21-teams | MS21-DB-001 | — | codex-worker-2 | 2026-02-28 | 2026-02-28 | 15K | 13K | PR #564, CI green |
|
||||
| MS21-API-005 | done | phase-1 | Admin workspace endpoints | TASKS:P1 | api | feat/ms21-admin-api | MS21-DB-001 | — | claude-worker-2 | 2026-02-28 | 2026-02-28 | — | — | Combined with API-001 |
|
||||
| MS21-TEST-001 | done | phase-1 | Unit tests for AdminService and AdminController | TASKS:P1 | api | feat/ms21-admin-api | MS21-API-001 | — | claude-worker-2 | 2026-02-28 | 2026-02-28 | 15K | — | PR #555, 26 tests |
|
||||
| MS21-FIX-001 | done | phase-1 | Fix flaky CI tests (rate limit timeout + log sanitizer) | TASKS:P1 | api | fix/ms21-flaky-ci | MS21-API-001 | — | codex-worker-3 | 2026-02-28 | 2026-02-28 | 8K | 7K | PR #562, CI green |
|
||||
| MS21-AUTH-001 | done | phase-2 | LocalAuthModule: break-glass auth | TASKS:P2 | api | feat/ms21-local-auth | MS21-DB-001 | MS21-TEST-002 | claude-worker-3 | 2026-02-28 | 2026-02-28 | 20K | 19K | PR #559, CI green |
|
||||
| MS21-AUTH-002 | done | phase-2 | Break-glass setup endpoint | TASKS:P2 | api | feat/ms21-local-auth | MS21-AUTH-001 | — | claude-worker-3 | 2026-02-28 | 2026-02-28 | — | — | Combined with AUTH-001 |
|
||||
| MS21-AUTH-003 | done | phase-2 | Break-glass login endpoint | TASKS:P2 | api | feat/ms21-local-auth | MS21-AUTH-001 | — | claude-worker-3 | 2026-02-28 | 2026-02-28 | — | — | Combined with AUTH-001 |
|
||||
| MS21-AUTH-004 | not-started | phase-2 | Deactivation session invalidation | TASKS:P2 | api | feat/ms21-session-invalidation | MS21-AUTH-001 | — | — | — | — | 10K | — | Deferred; do after Phase 4 |
|
||||
| MS21-TEST-002 | done | phase-2 | Unit tests for LocalAuth | TASKS:P2 | api | feat/ms21-local-auth | MS21-AUTH-001 | — | claude-worker-3 | 2026-02-28 | 2026-02-28 | 15K | — | PR #559, 27 tests |
|
||||
| MS21-MIG-001 | done | phase-3 | Migration script: scripts/migrate-brain.ts | #568 | api | feat/ms21-migration | MS21-DB-001 | MS21-MIG-002,MS21-TEST-003 | codex-worker-1 | 2026-02-28 | 2026-02-28 | 25K | 22K | PR #554 |
|
||||
| MS21-MIG-002 | done | phase-3 | Migration mapping: status/priority/domain | #568 | api | feat/ms21-migration | MS21-MIG-001 | — | codex-worker-1 | 2026-02-28 | 2026-02-28 | — | — | Included in MIG-001 |
|
||||
| MS21-TEST-003 | done | phase-3 | Migration script unit tests (9/9 passing) | #568 | api | test/ms21-migration-tests | MS21-MIG-001 | — | codex | 2026-02-28 | 2026-02-28 | 20K | 17K | PR #566 merged, CI green. Review: 0 blockers, 2 should-fix (brittle harness), 0 sec issues. |
|
||||
| MS21-MIG-003 | not-started | phase-3 | Run migration on production database | #568 | api | — | MS21-MIG-001,MS21-TEST-003 | MS21-VER-001 | — | — | — | 5K | — | Needs deploy coordination; not automatable |
|
||||
| MS21-MIG-004 | done | phase-3 | Import API endpoints (6/6 tests) | #568 | api | feat/ms21-import-api | MS21-DB-001 | — | codex | 2026-02-28 | 2026-02-28 | 20K | 24K | PR #567 merged, CI green. Review: 0 blockers, 4 should-fix, 1 medium sec (no audit log). |
|
||||
| MS21-UI-001 | done | phase-4 | Settings/users page | #569 | web | feat/ms21-ui-users | MS21-API-001,MS21-API-002 | — | codex | 2026-02-28 | 2026-02-28 | 20K | ~30K | PR #573 merged. Review: 0 blockers, 4 should-fix → MS21-UI-001-QA |
|
||||
| MS21-UI-001-QA | not-started | phase-4 | QA: fix 4 review findings (pagination, error state, self-deactivate guard, tests) | #569 | web | fix/ms21-ui-001-qa | MS21-UI-001 | — | — | — | — | 15K | — | 0 blockers; merged per framework. Should-fix: pagination cap, error/empty collision, self-deactivate guard, no tests. |
|
||||
| MS21-UI-002 | not-started | phase-4 | User detail/edit and invite dialogs | #569 | web | feat/ms21-ui-users | MS21-UI-001 | — | — | — | — | 15K | — | |
|
||||
| MS21-UI-003 | done | phase-4 | Settings/workspaces page (wire to real API) | #569 | web | feat/ms21-ui-workspaces | MS21-API-003 | — | codex | 2026-02-28 | 2026-02-28 | 15K | ~25K | PR #574 merged. Review: 0 critical, 1 low (raw errors in UI) |
|
||||
| MS21-UI-004 | not-started | phase-4 | Workspace member management UI | #569 | web | feat/ms21-ui-workspaces | MS21-UI-003,MS21-API-003 | — | — | — | — | 15K | — | Components exist |
|
||||
| MS21-UI-005 | not-started | phase-4 | Settings/teams page | #569 | web | feat/ms21-ui-teams | MS21-API-004 | — | — | — | — | 15K | — | |
|
||||
| MS21-TEST-004 | not-started | phase-4 | Frontend component tests | #569 | web | test/ms21-ui | MS21-UI-001,MS21-UI-002,MS21-UI-003,MS21-UI-004,MS21-UI-005 | — | — | — | — | 20K | — | |
|
||||
| MS21-RBAC-001 | not-started | phase-5 | Sidebar navigation role gating | #570 | web | feat/ms21-rbac | MS21-UI-001 | — | — | — | — | 10K | — | |
|
||||
| MS21-RBAC-002 | not-started | phase-5 | Settings page access restriction | #570 | web | feat/ms21-rbac | MS21-RBAC-001 | — | — | — | — | 8K | — | |
|
||||
| MS21-RBAC-003 | done | phase-5 | Action button permission gating | #570 | web | feat/ms21-rbac | MS21-RBAC-001 | — | — | — | — | 8K | — | |
|
||||
| MS21-RBAC-004 | done | phase-5 | User profile role display | #570 | web | feat/ms21-rbac | MS21-RBAC-001 | — | — | — | — | 5K | — | |
|
||||
| MS21-VER-001 | in-progress | phase-6 | Full quality gate pass | #571 | stack | — | MS21-TEST-004,MS21-RBAC-004,MS21-MIG-003 | MS21-VER-002 | — | — | — | 5K | — | |
|
||||
| MS21-VER-002 | not-started | phase-6 | Deploy and smoke test | #571 | stack | — | MS21-VER-001 | MS21-VER-003 | — | — | — | 5K | — | |
|
||||
| MS21-VER-003 | not-started | phase-6 | Tag v0.0.21 | #571 | stack | — | MS21-VER-002 | — | — | — | — | 2K | — | |
|
||||
## Phase 1: Knowledge Layer (MS22-P0)
|
||||
|
||||
| id | status | milestone | description | issue | repo | branch | depends_on | blocks | agent | started_at | completed_at | estimate | used | notes |
|
||||
| --------------- | ----------- | --------- | ----------------------------------------------------------------------------------------------------------- | ----- | ----- | -------------------------- | --------------------------------------------------- | ---------------------------- | ----- | ---------- | ------------ | -------- | ---- | ---------------------------------------- |
|
||||
| MS22-DB-001 | not-started | phase-1 | Prisma schema: findings table (id, task_id, agent_id, type, data JSONB, embedding vector, timestamps) | — | api | feat/ms22-knowledge-schema | — | MS22-DB-002,MS22-API-001 | — | — | — | 15K | — | pgvector extension required |
|
||||
| MS22-DB-002 | not-started | phase-1 | Prisma schema: agent_memory table (agent_id, key, value JSONB, unique constraint) | — | api | feat/ms22-knowledge-schema | MS22-DB-001 | MS22-API-002 | — | — | — | 8K | — | Combine with DB-001 if sensible |
|
||||
| MS22-DB-003 | not-started | phase-1 | Prisma schema: tasks table enhancements (state machine enum, assigned_agent, parent_task_id, priority) | — | api | feat/ms22-knowledge-schema | MS22-DB-001 | MS22-API-003 | — | — | — | 10K | — | Extends existing task model |
|
||||
| MS22-DB-004 | not-started | phase-1 | Prisma schema: conversation_archive table (session_id, agent_id, messages JSONB, summary, embedding vector) | — | api | feat/ms22-knowledge-schema | MS22-DB-001 | MS22-API-004 | — | — | — | 8K | — | |
|
||||
| MS22-API-001 | not-started | phase-1 | Findings module: POST/GET /api/findings + POST /api/findings/search (vector similarity) | — | api | feat/ms22-findings-api | MS22-DB-001 | MS22-TEST-001,MS22-SKILL-001 | — | — | — | 25K | — | NestJS module + controller + service |
|
||||
| MS22-API-002 | not-started | phase-1 | Agent memory module: PUT/GET/DELETE /api/agents/:id/memory[/:key] | — | api | feat/ms22-agent-memory-api | MS22-DB-002 | MS22-TEST-001,MS22-SKILL-001 | — | — | — | 15K | — | Cross-agent read, self-write |
|
||||
| MS22-API-003 | not-started | phase-1 | Task API enhancements: POST/GET/PATCH /api/tasks with state machine + assignment + parent/child | — | api | feat/ms22-task-api | MS22-DB-003 | MS22-TEST-001,MS22-SKILL-001 | — | — | — | 20K | — | State transitions enforced in service |
|
||||
| MS22-API-004 | not-started | phase-1 | Conversation archive: POST /api/conversations/ingest + POST /api/conversations/search | — | api | feat/ms22-conversation-api | MS22-DB-004 | MS22-TEST-001 | — | — | — | 20K | — | Embedding generation async |
|
||||
| MS22-API-005 | not-started | phase-1 | Embedding service: generate embeddings via configured provider (OpenAI text-embedding-3-small) | — | api | feat/ms22-embeddings | MS22-DB-001 | MS22-API-001,MS22-API-004 | — | — | — | 15K | — | Shared service for all vector operations |
|
||||
| MS22-TEST-001 | not-started | phase-1 | Unit + integration tests for findings, memory, tasks, conversation APIs | — | api | test/ms22-knowledge-layer | MS22-API-001,MS22-API-002,MS22-API-003,MS22-API-004 | MS22-VER-P0 | — | — | — | 25K | — | |
|
||||
| MS22-SKILL-001 | not-started | phase-1 | OpenClaw mosaic skill: SKILL.md + CLI wrapper for task/finding/memory/conversation APIs | — | skill | feat/ms22-mosaic-skill | MS22-API-001,MS22-API-002,MS22-API-003 | MS22-AGENT-001 | — | — | — | 20K | — | Installed in each agent workspace |
|
||||
| MS22-INGEST-001 | not-started | phase-1 | Session log ingestion pipeline: watch/poll OpenClaw JSONL → parse → embed → store | — | api | feat/ms22-log-ingestion | MS22-API-004,MS22-API-005 | MS22-VER-P0 | — | — | — | 20K | — | Cron job or file watcher |
|
||||
| MS22-VER-P0 | not-started | phase-1 | Phase 0 verification: quality gates + deploy + smoke test | — | stack | — | MS22-TEST-001,MS22-INGEST-001 | MS22-AGENT-001 | — | — | — | 5K | — | |
|
||||
|
||||
## Phase 2: Agent Fleet Standup (MS22-P1)
|
||||
|
||||
| id | status | milestone | description | issue | repo | branch | depends_on | blocks | agent | started_at | completed_at | estimate | used | notes |
|
||||
| --------------- | ----------- | --------- | ------------------------------------------------------------------------------------------------- | ----- | ------ | --------------------------- | ------------------------------ | -------------- | ----- | ---------- | ------------ | -------- | ---- | ------------------------------------ |
|
||||
| MS22-AGENT-001 | not-started | phase-2 | Provision OpenClaw agents: jarvis, builder, medic (workspaces, SOUL.md, model config, tool perms) | — | config | feat/ms22-agent-provision | MS22-VER-P0,MS22-SKILL-001 | MS22-AGENT-002 | — | — | — | 15K | — | OpenClaw multi-agent config |
|
||||
| MS22-AGENT-002 | not-started | phase-2 | Discord channel bindings: #jarvis, #builder, #medic-alerts, #agent-status | — | config | feat/ms22-discord-bindings | MS22-AGENT-001 | MS22-AGENT-004 | — | — | — | 8K | — | |
|
||||
| MS22-AGENT-003 | not-started | phase-2 | Matrix observation rooms: auto-provision per-agent + #mosaic-ops, E2E encrypted | — | api | feat/ms22-matrix-rooms | MS22-AGENT-001 | MS22-AGENT-004 | — | — | — | 15K | — | Extend existing bridge/matrix module |
|
||||
| MS22-AGENT-004 | not-started | phase-2 | Integration test: agent writes finding via mosaic skill → another agent searches and retrieves it | — | stack | test/ms22-agent-integration | MS22-AGENT-001,MS22-AGENT-002 | MS22-VER-P1 | — | — | — | 15K | — | E2E round-trip test |
|
||||
| MS22-MIRROR-001 | not-started | phase-2 | Async mirroring: findings/status → Matrix rooms (fire-and-forget from API) | — | api | feat/ms22-matrix-mirror | MS22-AGENT-003,MS22-API-001 | MS22-VER-P1 | — | — | — | 12K | — | No agent inference cost |
|
||||
| MS22-VER-P1 | not-started | phase-2 | Phase 1 verification: all agents responding, findings round-trip works, Matrix mirrors active | — | stack | — | MS22-AGENT-004,MS22-MIRROR-001 | MS22-CHAT-001 | — | — | — | 5K | — | |
|
||||
|
||||
## Phase 3: WebUI Chat + Task Management (MS22-P2)
|
||||
|
||||
| id | status | milestone | description | issue | repo | branch | depends_on | blocks | agent | started_at | completed_at | estimate | used | notes |
|
||||
| ---------------- | ----------- | --------- | ------------------------------------------------------------------------------------- | ----- | ----- | ------------------------- | ----------------------------------------------------------- | ------------- | ----- | ---------- | ------------ | -------- | ---- | ---------------------------------- |
|
||||
| MS22-CHAT-001 | not-started | phase-3 | WebSocket chat endpoint: WS /api/chat → proxy to OpenClaw agent sessions | — | api | feat/ms22-chat-ws | MS22-VER-P1 | MS22-CHAT-002 | — | — | — | 25K | — | Stream responses, persist messages |
|
||||
| MS22-CHAT-002 | not-started | phase-3 | WebUI chat component: agent selector, message input, streaming display, history | — | web | feat/ms22-chat-ui | MS22-CHAT-001 | MS22-VER-P2 | — | — | — | 30K | — | |
|
||||
| MS22-TASK-UI-001 | not-started | phase-3 | Task management UI: create, assign, kanban/list view, task detail with findings | — | web | feat/ms22-task-ui | MS22-API-003,MS22-VER-P1 | MS22-VER-P2 | — | — | — | 25K | — | |
|
||||
| MS22-REG-001 | not-started | phase-3 | Agent registry UI: card/list view, status, model, channel, last active | — | web | feat/ms22-agent-registry | MS22-VER-P1 | MS22-VER-P2 | — | — | — | 15K | — | |
|
||||
| MS22-SEARCH-001 | not-started | phase-3 | Findings search UI: semantic query, filters (agent, type, date), ranked results | — | web | feat/ms22-findings-search | MS22-API-001,MS22-VER-P1 | MS22-VER-P2 | — | — | — | 15K | — | |
|
||||
| MS22-TEST-P2 | not-started | phase-3 | Frontend tests for chat, task, registry, search components | — | web | test/ms22-ui | MS22-CHAT-002,MS22-TASK-UI-001,MS22-REG-001,MS22-SEARCH-001 | MS22-VER-P2 | — | — | — | 20K | — | |
|
||||
| MS22-VER-P2 | not-started | phase-3 | Phase 2 verification: WebUI chat works, task management works, search returns results | — | stack | — | MS22-TEST-P2 | MS22-LLM-001 | — | — | — | 5K | — | |
|
||||
|
||||
## Phase 4: LLM Provider Management (MS22-P3)
|
||||
|
||||
| id | status | milestone | description | issue | repo | branch | depends_on | blocks | agent | started_at | completed_at | estimate | used | notes |
|
||||
| ------------ | ----------- | --------- | -------------------------------------------------------------------------------------------- | ----- | ----- | ------------------------- | --------------------------------------------------- | ------------- | ----- | ---------- | ------------ | -------- | ---- | ------------------------------------ |
|
||||
| MS22-LLM-001 | not-started | phase-4 | Provider management UI: add/remove/configure/test providers | — | web | feat/ms22-llm-providers | MS22-VER-P2 | MS22-LLM-002 | — | — | — | 20K | — | Extends existing llm-provider-admin |
|
||||
| MS22-LLM-002 | not-started | phase-4 | Per-agent model assignment UI with fallback chains | — | web | feat/ms22-agent-models | MS22-LLM-001 | MS22-LLM-003 | — | — | — | 15K | — | |
|
||||
| MS22-LLM-003 | not-started | phase-4 | Usage/cost dashboard: tokens per agent per provider, time-series charts | — | web | feat/ms22-usage-dashboard | MS22-LLM-002,MS22-INGEST-001 | MS22-VER-P3 | — | — | — | 20K | — | Data from session log ingestion |
|
||||
| MS22-LLM-004 | not-started | phase-4 | Provider health monitoring: latency, errors, status indicators | — | api | feat/ms22-provider-health | MS22-LLM-001 | MS22-VER-P3 | — | — | — | 15K | — | Passive collection from request logs |
|
||||
| MS22-LLM-005 | not-started | phase-4 | Sync mechanism: Mosaic provider config → OpenClaw runtime config | — | api | feat/ms22-provider-sync | MS22-LLM-001 | MS22-VER-P3 | — | — | — | 15K | — | API-based, not file sync |
|
||||
| MS22-TEST-P3 | not-started | phase-4 | Tests for provider management, assignment, dashboard, health | — | stack | test/ms22-llm | MS22-LLM-001,MS22-LLM-002,MS22-LLM-003,MS22-LLM-004 | MS22-VER-P3 | — | — | — | 15K | — | |
|
||||
| MS22-VER-P3 | not-started | phase-4 | Phase 3 verification: providers configurable, per-agent assignment works, dashboard accurate | — | stack | — | MS22-TEST-P3,MS22-LLM-005 | MS22-INST-001 | — | — | — | 5K | — | |
|
||||
|
||||
## Phase 5: Installer + Polish (MS22-P4)
|
||||
|
||||
| id | status | milestone | description | issue | repo | branch | depends_on | blocks | agent | started_at | completed_at | estimate | used | notes |
|
||||
| ------------- | ----------- | --------- | -------------------------------------------------------------------------------------------- | ----- | ----- | -------------------- | -------------------------- | ------------- | ----- | ---------- | ------------ | -------- | ---- | ---------- |
|
||||
| MS22-INST-001 | not-started | phase-5 | Scripted installer: openclaw skills install mosaic-fleet (or npx mosaic-fleet init) | — | skill | feat/ms22-installer | MS22-VER-P3 | MS22-INST-002 | — | — | — | 25K | — | |
|
||||
| MS22-INST-002 | not-started | phase-5 | Interactive setup wizard: detect stack, provision agents, bind channels, configure providers | — | skill | feat/ms22-wizard | MS22-INST-001 | MS22-INST-003 | — | — | — | 20K | — | |
|
||||
| MS22-INST-003 | not-started | phase-5 | Retention policy: per-workspace config in WebUI, scheduled Postgres cleanup job | — | api | feat/ms22-retention | MS22-VER-P2 | MS22-VER-P4 | — | — | — | 12K | — | |
|
||||
| MS22-DOC-001 | not-started | phase-5 | Documentation: user guide, admin guide, troubleshooting | — | docs | docs/ms22-fleet-docs | MS22-INST-002 | MS22-VER-P4 | — | — | — | 10K | — | |
|
||||
| MS22-VER-P4 | not-started | phase-5 | Final verification: clean install on fresh env, 3 agents respond, full round-trip works | — | stack | — | MS22-INST-003,MS22-DOC-001 | — | — | — | — | 10K | — | Tag v0.5.0 |
|
||||
|
||||
## Budget Summary
|
||||
|
||||
| Phase | Tasks | Done | Estimate | Used |
|
||||
| ---------------------- | ------ | ------ | --------- | --------- |
|
||||
| Phase 1 (Schema + API) | 9 | 9 | ~113K | ~93K |
|
||||
| Phase 2 (Auth) | 4 | 3 | ~45K | ~19K |
|
||||
| Phase 3 (Migration) | 5 | 3 | ~70K | ~63K |
|
||||
| Phase 4 (UI) | 6 | 0 | ~100K | — |
|
||||
| Phase 5 (RBAC) | 4 | 0 | ~31K | — |
|
||||
| Phase 6 (Verification) | 3 | 0 | ~12K | — |
|
||||
| **Total** | **31** | **15** | **~371K** | **~175K** |
|
||||
|
||||
Remaining estimate: ~143K tokens (Codex budget).
|
||||
| Phase | Tasks | Done | Estimate | Used |
|
||||
| ---------------------------- | ------ | ----- | --------- | ----- |
|
||||
| Phase 1 (Knowledge Layer) | 13 | 0 | ~201K | — |
|
||||
| Phase 2 (Agent Fleet) | 6 | 0 | ~70K | — |
|
||||
| Phase 3 (WebUI Chat + Tasks) | 7 | 0 | ~135K | — |
|
||||
| Phase 4 (LLM Providers) | 7 | 0 | ~105K | — |
|
||||
| Phase 5 (Installer + Polish) | 5 | 0 | ~77K | — |
|
||||
| **Total** | **38** | **0** | **~588K** | **—** |
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
# Mission Scratchpad — Fleet Evolution
|
||||
|
||||
> Append-only log. NEVER delete entries. NEVER overwrite sections.
|
||||
> This is the orchestrator's working memory across sessions.
|
||||
|
||||
## Original Mission Prompt
|
||||
|
||||
```
|
||||
(Paste the mission prompt here on first session)
|
||||
```
|
||||
|
||||
## Planning Decisions
|
||||
|
||||
## Session Log
|
||||
|
||||
| Session | Date | Milestone | Tasks Done | Outcome |
|
||||
| ------- | ---- | --------- | ---------- | ------- |
|
||||
|
||||
## Open Questions
|
||||
|
||||
## Corrections
|
||||
+2
-1
@@ -74,7 +74,8 @@
|
||||
"tough-cookie": ">=4.1.3",
|
||||
"undici": ">=6.23.0",
|
||||
"rollup": ">=4.59.0",
|
||||
"serialize-javascript": ">=7.0.3"
|
||||
"serialize-javascript": ">=7.0.3",
|
||||
"multer": ">=2.1.0"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Generated
+6
-15
@@ -17,6 +17,7 @@ overrides:
|
||||
undici: '>=6.23.0'
|
||||
rollup: '>=4.59.0'
|
||||
serialize-javascript: '>=7.0.3'
|
||||
multer: '>=2.1.0'
|
||||
|
||||
importers:
|
||||
|
||||
@@ -1603,6 +1604,7 @@ packages:
|
||||
|
||||
'@mosaicstack/[email protected]':
|
||||
resolution: {integrity: sha512-1udg6p4cs8rhQgQ2pKCfi7EpRlJieRRhA5CIqthRQ6HQZLgQ0wH+632jEulov3rlHSM1iplIQ+AAe5DWrvSkEA==, tarball: https://git.mosaicstack.dev/api/packages/mosaic/npm/%40mosaicstack%2Ftelemetry-client/-/0.1.1/telemetry-client-0.1.1.tgz}
|
||||
engines: {node: '>=18'}
|
||||
|
||||
'@mrleebo/[email protected]':
|
||||
resolution: {integrity: sha512-XyroGQXcHrZdvmrGJvsA9KNeOOgGMg1Vg9OlheUsBOSKznLMDl+YChxbkboRHvtFYJEMRYmlV3uoo/njCw05iw==}
|
||||
@@ -5805,10 +5807,6 @@ packages:
|
||||
[email protected]:
|
||||
resolution: {integrity: sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==}
|
||||
|
||||
[email protected]:
|
||||
resolution: {integrity: sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==}
|
||||
hasBin: true
|
||||
|
||||
[email protected]:
|
||||
resolution: {integrity: sha512-+NsyUUAZDmo6YVHzL/stxSu3t9YS1iljliy3BSDrXJ/dkn1KYdmtZODGGjLcc9XLgVVpH4KshHB8XmZgMhaBXg==}
|
||||
engines: {node: '>=10'}
|
||||
@@ -5837,8 +5835,8 @@ packages:
|
||||
[email protected]:
|
||||
resolution: {integrity: sha512-UjkUHN0yqp9RWKy0Lplhh+wlpdt9oQBYgULZOiFhV3VclSF1JnSQWZ5r9gORQlNYaUKQoR8itv7g7z1xDDuACA==}
|
||||
|
||||
multer@2.0.2:
|
||||
resolution: {integrity: sha512-u7f2xaZ/UG8oLXHvtF/oWTRvT44p9ecwBBqTwgJVq0+4BW1g8OW01TyMEGWBHbyMOYVHXslaut7qEQ1meATXgw==}
|
||||
multer@2.1.0:
|
||||
resolution: {integrity: sha512-TBm6j41rxNohqawsxlsWsNNh/VdV4QFXcBvRcPhXaA05EZ79z0qJ2bQFpync6JBoHTeNY5Q1JpG7AlTjdlfAEA==}
|
||||
engines: {node: '>= 10.16.0'}
|
||||
|
||||
[email protected]:
|
||||
@@ -8842,7 +8840,7 @@ snapshots:
|
||||
'@nestjs/core': 11.1.12(@nestjs/[email protected]([email protected])([email protected])([email protected])([email protected]))(@nestjs/[email protected])(@nestjs/[email protected])([email protected])([email protected])
|
||||
cors: 2.8.5
|
||||
express: 5.2.1
|
||||
multer: 2.0.2
|
||||
multer: 2.1.0
|
||||
path-to-regexp: 8.3.0
|
||||
tslib: 2.8.1
|
||||
transitivePeerDependencies:
|
||||
@@ -13391,10 +13389,6 @@ snapshots:
|
||||
|
||||
[email protected]: {}
|
||||
|
||||
[email protected]:
|
||||
dependencies:
|
||||
minimist: 1.2.8
|
||||
|
||||
[email protected]: {}
|
||||
|
||||
[email protected]:
|
||||
@@ -13436,15 +13430,12 @@ snapshots:
|
||||
optionalDependencies:
|
||||
msgpackr-extract: 3.0.3
|
||||
|
||||
multer@2.0.2:
|
||||
multer@2.1.0:
|
||||
dependencies:
|
||||
append-field: 1.0.0
|
||||
busboy: 1.6.0
|
||||
concat-stream: 2.0.0
|
||||
mkdirp: 0.5.6
|
||||
object-assign: 4.1.1
|
||||
type-is: 1.6.18
|
||||
xtend: 4.0.2
|
||||
|
||||
[email protected]: {}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user