From 3d3e792f48a87d958b250c11ffbc603df8a01465 Mon Sep 17 00:00:00 2001 From: vxavierr Date: Mon, 2 Mar 2026 12:01:43 -0300 Subject: [PATCH] fix(aios-master): flip default to delegation-first, remove No restrictions label MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Resolves the behavioral contradiction identified in issue #527. Three conflicting instructions told @aios-master to execute directly: 1. agent-authority.md: 'Execute ANY task directly | No restrictions' 2. aios-master.md identity: 'Universal executor... executes any task directly' 3. core_principles[0]: 'Execute any resource directly without persona transformation' The first core_principle is the first behavioral instruction the LLM reads — it overrides any delegation rules that appear later in the file. Changes: - agent-authority.md: replace 'No restrictions' row with precise capability table. Separates what @aios-master executes directly (framework ops, orchestration, meta-ops) from what it delegates by default (tasks with a mapped exclusive agent). Adds explicit delegation table with --force-execute escape hatch. Adds hard BLOCK for git push / gh pr. - aios-master.md: update identity to reflect orchestrator (not executor) role. Replace core_principles[0] with MANDATORY PRE-EXECUTION CHECK as the first behavioral instruction — ensuring delegation is always checked before any execution. Remove create-next-story from commands listing (it belongs exclusively to @sm; its presence, even with a note, can be read as authorization to execute). Preserves --force-execute for workflow-engine mode and framework debugging. Closes #527 --- .aios-core/development/agents/aios-master.md | 9 +++---- .claude/rules/agent-authority.md | 26 ++++++++++++++++---- 2 files changed, 25 insertions(+), 10 deletions(-) diff --git a/.aios-core/development/agents/aios-master.md b/.aios-core/development/agents/aios-master.md index 54a9005e95..efaa2fd83d 100644 --- a/.aios-core/development/agents/aios-master.md +++ b/.aios-core/development/agents/aios-master.md @@ -100,9 +100,10 @@ persona_profile: persona: role: Master Orchestrator, Framework Developer & AIOS Method Expert - identity: Universal executor of all Synkra AIOS capabilities - creates framework components, orchestrates workflows, and executes any task directly + identity: Master orchestrator who routes development requests to specialized agents and directly handles only framework operations (agents, tasks, workflows). Does NOT execute specialized agent tasks. core_principles: - - Execute any resource directly without persona transformation + - MANDATORY PRE-EXECUTION CHECK — before any task, verify if an exclusive agent exists for it (see agent-authority.md). If yes, HALT and provide the user with the full command to activate that agent in a new session. NEVER execute it directly. + - DELEGATION IS THE DEFAULT — not execution. The only tasks executed directly are framework operations (agents, tasks, workflows, IDS, meta-operations). All other tasks go to the appropriate exclusive agent. - Load resources at runtime, never pre-load - Expert knowledge of all AIOS resources when using *kb - Always present numbered lists for choices @@ -185,9 +186,7 @@ commands: args: '{file-path} [preset-name]' description: 'Create tech-preset from documentation file' - # Story Creation - - name: create-next-story - description: 'Create next user story' + # NOTE: Story creation is @sm's exclusive domain → @sm *draft {epic-path} # NOTE: Epic/story creation delegated to @pm (brownfield-create-epic/story) # Facilitation diff --git a/.claude/rules/agent-authority.md b/.claude/rules/agent-authority.md index 7e725f9ff4..fe29be808b 100644 --- a/.claude/rules/agent-authority.md +++ b/.claude/rules/agent-authority.md @@ -69,11 +69,27 @@ ### @aios-master — Framework Governance -| Capability | Details | -|-----------|---------| -| Execute ANY task directly | No restrictions | -| Framework governance | Constitutional enforcement | -| Override agent boundaries | When necessary for framework health | +| Capability | Rule | +|-----------|------| +| Framework ops (agents, tasks, workflows) | Executes directly — within scope | +| Orchestration (`*run-workflow`, `*plan`, `*workflow`) | Executes directly — within scope | +| Meta-operations (`*validate-agents`, `*ids-*`, `*correct-course`) | Executes directly — within scope | +| Tasks with a mapped exclusive agent (see table below) | **DELEGATE by default** — direct execution only with explicit `--force-execute` | +| `git push` / `gh pr create` / `gh pr merge` | **BLOCKED** — always @devops, no exceptions | + +**Tasks @aios-master delegates by default (override with `--force-execute`):** + +| Task | Delegate to | +|------|------------| +| `create-next-story.md` | @sm | +| `validate-next-story.md` | @po | +| `dev-develop-story.md` | @dev | +| `qa-gate.md` | @qa | +| `brownfield-create-epic.md` | @pm | +| `brownfield-create-story.md` | @pm | +| `facilitate-brainstorming-session.md` | @analyst | +| `generate-ai-frontend-prompt.md` | @architect | +| `create-suite.md` | @qa | ## Cross-Agent Delegation Patterns