feat(vu-001): Work Request Intake (Phase A) behind MAESTRO_WORKFLOW_ENABLED#12
Merged
Merged
Conversation
…OW_ENABLED Introduces the first VU-001 work-orchestration step: operators register a work request and approve/reject/cancel it before an agent starts, gated by the MAESTRO_WORKFLOW_ENABLED flag (default OFF) so existing flows are untouched when disabled. Server (maestro-server.js): - WorkRequest store (in-memory + persisted into the existing .maestro-workflows.json alongside work sessions; restored on restart) - GET/POST /api/work-requests, GET /:id, POST /:id/decision — 404 WORKFLOW_DISABLED when the flag is off - Validation with the planned error codes (WORK_REQUEST_INVALID, PROJECT_ID_INVALID, LANE_INDEX_INVALID, WORK_REQUEST_ALREADY_DECIDED) - WORK_REQUEST_CREATED / WORK_REQUEST_DECIDED websocket broadcasts - /health exposes workflow.enabled so the UI can gate the toggle UI: - useWorkRequests hook (flag probe via /health, CRUD, socket sync) - WorkRequestPanel (create form + request cards + approve/reject/cancel, aria-live summary, aria-expanded/controls) - Header "Requests" toggle (distinct from the existing "Work" console toggle), shown only when the flag is enabled Deviations from the 2026-03-15 plan (documented in PHASE_A plan): - Store integrated into .maestro-workflows.json + inline in the server instead of separate shared modules, to avoid clobbering Session Core - Project selector deferred to the multi-project phase; requests default to the active project Tests: 5 server regression cases + 2 UI regression cases. npm run qa and npm run smoke:lanes pass. Verified end-to-end against a live server (flag gating, create, approve, duplicate 409, validation, persistence). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
개요
VU-001 OpenClaw Work Orchestration의 첫 단계인 **Work Request Intake (Phase A)**를 도입합니다. 운영자가 작업 요청을 등록하고, 에이전트 착수 전에 요청 자체를 승인/반려/취소합니다.
MAESTRO_WORKFLOW_ENABLED플래그(기본 OFF) 뒤에 격리되어 플래그 OFF 시 기존 동작은 완전히 동일합니다.서버 (maestro-server.js)
WorkRequest스토어: 메모리 + 기존.maestro-workflows.json(Session Core와 공유)에workRequests통합 영속화, 재시작 복구GET/POST /api/work-requests,GET /:id,POST /:id/decision— 플래그 OFF 시404 WORKFLOW_DISABLEDWORK_REQUEST_INVALID,PROJECT_ID_INVALID,LANE_INDEX_INVALID,WORK_REQUEST_ALREADY_DECIDED(중복 결정 409)WORK_REQUEST_CREATED/WORK_REQUEST_DECIDEDWebSocket 브로드캐스트/health에workflow.enabled노출 (UI 토글 게이팅용)UI
/health플래그 감지 + CRUD + 소켓 동기화aria-live요약,aria-expanded/controlsRequests토글 (기존Work(Console) 토글과 구분), 플래그 ON일 때만 노출계획 대비 조정 (Phase A 플랜 문서에 기록)
shared모듈 →.maestro-workflows.json통합 + 서버 인라인 (Session Core 파일 충돌 회피)테스트 & 검증
npm run qa(server 47 + UI 28 + build) +npm run smoke:lanes통과알려진 UX 관찰
🤖 Generated with Claude Code