Files
stack/docs/TASKS.md
T

79 lines
18 KiB
Markdown

# 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
## 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 (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** | **—** |