refactor: Standardize agent references to @agent-name format

- Convert direct agent name references to @agent-name format in documentation
- Preserve Task() function calls and subagent_type parameters unchanged
- Keep task content agent identifiers in original format (for display only)
- Maintain document reference paths in original format
- Update workflow architecture, task management, and execution files

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
catlog22
2025-09-23 19:53:46 +08:00
parent 410d0efd7b
commit 0f01cecc2d
9 changed files with 53 additions and 53 deletions

View File

@@ -77,8 +77,8 @@ Proceed with breakdown? (y/n): y
✅ Task IMPL-1 broken down: ✅ Task IMPL-1 broken down:
▸ IMPL-1: Build authentication module (container) ▸ IMPL-1: Build authentication module (container)
├── IMPL-1.1: User authentication core → code-developer ├── IMPL-1.1: User authentication core → @code-developer
└── IMPL-1.2: OAuth integration → code-developer └── IMPL-1.2: OAuth integration → @code-developer
Files updated: .task/IMPL-1.json + 2 subtask files + TODO_LIST.md Files updated: .task/IMPL-1.json + 2 subtask files + TODO_LIST.md
``` ```
@@ -86,10 +86,10 @@ Files updated: .task/IMPL-1.json + 2 subtask files + TODO_LIST.md
## Decomposition Logic ## Decomposition Logic
### Agent Assignment ### Agent Assignment
- **Design/Planning** → `planning-agent` - **Design/Planning** → `@planning-agent`
- **Implementation** → `code-developer` - **Implementation** → `@code-developer`
- **Testing** → `code-review-test-agent` - **Testing** → `@code-review-test-agent`
- **Review** → `review-agent` - **Review** → `@review-agent`
### Context Inheritance ### Context Inheritance
- Subtasks inherit parent requirements - Subtasks inherit parent requirements
@@ -160,9 +160,9 @@ See @~/.claude/workflows/workflow-architecture.md for:
/task:breakdown impl-1 /task:breakdown impl-1
▸ impl-1: Build authentication (container) ▸ impl-1: Build authentication (container)
├── impl-1.1: Design schema → planning-agent ├── impl-1.1: Design schema → @planning-agent
├── impl-1.2: Implement logic → code-developer ├── impl-1.2: Implement logic → @code-developer
└── impl-1.3: Write tests → code-review-test-agent └── impl-1.3: Write tests → @code-review-test-agent
``` ```
## Error Handling ## Error Handling

View File

@@ -45,7 +45,7 @@ Output:
✅ Task created: IMPL-1 ✅ Task created: IMPL-1
Title: Build authentication module Title: Build authentication module
Type: feature Type: feature
Agent: code-developer Agent: @code-developer
Status: pending Status: pending
``` ```
@@ -105,10 +105,10 @@ Tasks inherit from:
## Agent Assignment ## Agent Assignment
Based on task type and title keywords: Based on task type and title keywords:
- **Build/Implement** → `code-developer` - **Build/Implement** → `@code-developer`
- **Design/Plan** → `planning-agent` - **Design/Plan** → `@planning-agent`
- **Test/Validate** → `code-review-test-agent` - **Test/Validate** → `@code-review-test-agent`
- **Review/Audit** → `review-agent` - **Review/Audit** → `@review-agent`
## Validation Rules ## Validation Rules
@@ -141,7 +141,7 @@ Based on task type and title keywords:
✅ Created IMPL-1: Implement user authentication ✅ Created IMPL-1: Implement user authentication
Type: feature Type: feature
Agent: code-developer Agent: @code-developer
Status: pending Status: pending
``` ```
@@ -151,7 +151,7 @@ Status: pending
✅ Created IMPL-2: Fix login validation bug ✅ Created IMPL-2: Fix login validation bug
Type: bugfix Type: bugfix
Agent: code-developer Agent: @code-developer
Status: pending Status: pending
``` ```

View File

@@ -24,7 +24,7 @@ examples:
- Executes step-by-step, requiring user confirmation at each checkpoint. - Executes step-by-step, requiring user confirmation at each checkpoint.
- Allows for dynamic adjustments and manual review during the process. - Allows for dynamic adjustments and manual review during the process.
- **review** - **review**
- Executes under the supervision of a `review-agent`. - Executes under the supervision of a `@review-agent`.
- Performs quality checks and provides detailed feedback at each step. - Performs quality checks and provides detailed feedback at each step.
### 🤖 **Agent Selection Logic** ### 🤖 **Agent Selection Logic**
@@ -42,15 +42,15 @@ FUNCTION select_agent(task, agent_override):
ELSE: ELSE:
CASE task.title: CASE task.title:
WHEN CONTAINS "Build API", "Implement": WHEN CONTAINS "Build API", "Implement":
RETURN "code-developer" RETURN "@code-developer"
WHEN CONTAINS "Design schema", "Plan": WHEN CONTAINS "Design schema", "Plan":
RETURN "planning-agent" RETURN "@planning-agent"
WHEN CONTAINS "Write tests": WHEN CONTAINS "Write tests":
RETURN "code-review-test-agent" RETURN "@code-review-test-agent"
WHEN CONTAINS "Review code": WHEN CONTAINS "Review code":
RETURN "review-agent" RETURN "@review-agent"
DEFAULT: DEFAULT:
RETURN "code-developer" // Default agent RETURN "@code-developer" // Default agent
END CASE END CASE
END FUNCTION END FUNCTION
``` ```
@@ -138,7 +138,7 @@ This is the simplified data structure loaded to provide context for task executi
"title": "Build authentication module", "title": "Build authentication module",
"type": "feature", "type": "feature",
"status": "active", "status": "active",
"agent": "code-developer", "agent": "@code-developer",
"context": { "context": {
"requirements": ["JWT authentication", "OAuth2 support"], "requirements": ["JWT authentication", "OAuth2 support"],
"scope": ["src/auth/*", "tests/auth/*"], "scope": ["src/auth/*", "tests/auth/*"],
@@ -209,7 +209,7 @@ This is the simplified data structure loaded to provide context for task executi
} }
}, },
"execution": { "execution": {
"agent": "code-developer", "agent": "@code-developer",
"mode": "auto", "mode": "auto",
"attempts": 0 "attempts": 0
} }
@@ -220,25 +220,25 @@ This is the simplified data structure loaded to provide context for task executi
Different agents receive context tailored to their function, including implementation details: Different agents receive context tailored to their function, including implementation details:
**`code-developer`**: **`@code-developer`**:
- Complete implementation.files array with file paths and locations - Complete implementation.files array with file paths and locations
- original_code snippets and proposed_changes for precise modifications - original_code snippets and proposed_changes for precise modifications
- logic_flow diagrams for understanding data flow - logic_flow diagrams for understanding data flow
- Dependencies and affected modules for integration planning - Dependencies and affected modules for integration planning
- Performance and error handling considerations - Performance and error handling considerations
**`planning-agent`**: **`@planning-agent`**:
- High-level requirements, constraints, success criteria - High-level requirements, constraints, success criteria
- Implementation risks and mitigation strategies - Implementation risks and mitigation strategies
- Architecture implications from implementation.context_notes - Architecture implications from implementation.context_notes
**`code-review-test-agent`**: **`@code-review-test-agent`**:
- Files to test from implementation.files[].path - Files to test from implementation.files[].path
- Logic flows to validate from implementation.modifications.logic_flow - Logic flows to validate from implementation.modifications.logic_flow
- Error conditions to test from implementation.context_notes.error_handling - Error conditions to test from implementation.context_notes.error_handling
- Performance benchmarks from implementation.context_notes.performance_considerations - Performance benchmarks from implementation.context_notes.performance_considerations
**`review-agent`**: **`@review-agent`**:
- Code quality standards and implementation patterns - Code quality standards and implementation patterns
- Security considerations from implementation.context_notes.risks - Security considerations from implementation.context_notes.risks
- Dependency validation from implementation.context_notes.dependencies - Dependency validation from implementation.context_notes.dependencies
@@ -262,7 +262,7 @@ Optional summary file generated at `.summaries/IMPL-[task-id]-summary.md`.
- Added tests in tests/auth.test.ts - Added tests in tests/auth.test.ts
## Execution Results ## Execution Results
- **Agent**: code-developer - **Agent**: @code-developer
- **Status**: completed - **Status**: completed
## Files Modified ## Files Modified

View File

@@ -111,7 +111,7 @@ Each documentation task uses the workflow-architecture.md 5-field schema:
- **id**: IMPL-N format - **id**: IMPL-N format
- **title**: Documentation task name - **title**: Documentation task name
- **status**: pending|active|completed|blocked - **status**: pending|active|completed|blocked
- **meta**: { type: "documentation", agent: "doc-generator" } - **meta**: { type: "documentation", agent: "@doc-generator" }
- **context**: { requirements, focus_paths, acceptance, scope } - **context**: { requirements, focus_paths, acceptance, scope }
- **flow_control**: { pre_analysis[], implementation_approach, target_files[] } - **flow_control**: { pre_analysis[], implementation_approach, target_files[] }

View File

@@ -233,10 +233,10 @@ Task(subagent_type="{agent_type}",
``` ```
meta.agent specified → Use specified agent meta.agent specified → Use specified agent
meta.agent missing → Infer from meta.type: meta.agent missing → Infer from meta.type:
- "feature" → code-developer - "feature" → @code-developer
- "test" → code-review-test-agent - "test" → @code-review-test-agent
- "review" → code-review-agent - "review" → @code-review-agent
- "docs" → doc-generator - "docs" → @doc-generator
``` ```
#### Error Handling During Execution #### Error Handling During Execution

View File

@@ -70,7 +70,7 @@ Shows detailed task information:
**Title**: Build authentication module **Title**: Build authentication module
**Status**: active **Status**: active
**Agent**: code-developer **Agent**: @code-developer
**Type**: feature **Type**: feature
## Context ## Context
@@ -245,7 +245,7 @@ Performs integrity checks:
/workflow:status --format=tasks --filter=completed /workflow:status --format=tasks --filter=completed
# Show tasks for specific agent # Show tasks for specific agent
/workflow:status --format=tasks --agent=code-developer /workflow:status --format=tasks --agent=@code-developer
``` ```
## Related Commands ## Related Commands

View File

@@ -26,7 +26,7 @@ Before ANY agent coordination begins, the brainstorming command MUST establish t
- Establish agent coordination metadata - Establish agent coordination metadata
### Pre-Agent Verification ### Pre-Agent Verification
Before delegating to conceptual-planning-agent, VERIFY: Before delegating to @conceptual-planning-agent, VERIFY:
- [ ] Topic slug generated correctly - [ ] Topic slug generated correctly
- [ ] All required directories exist - [ ] All required directories exist
- [ ] workflow-session.json initialized - [ ] workflow-session.json initialized
@@ -103,7 +103,7 @@ Each brainstorming session maintains metadata in `session-summary.md` header:
**Topic**: [Challenge description] **Topic**: [Challenge description]
**Mode**: creative|analytical|strategic **Mode**: creative|analytical|strategic
**Perspectives**: [role1, role2, role3...] **Perspectives**: [role1, role2, role3...]
**Facilitator**: conceptual-planning-agent **Facilitator**: @conceptual-planning-agent
**Date**: YYYY-MM-DD **Date**: YYYY-MM-DD
## Session Overview ## Session Overview
@@ -161,7 +161,7 @@ done
``` ```
### Agent Document Assignment Protocol ### Agent Document Assignment Protocol
When coordinating with conceptual-planning-agent, ALWAYS specify exact output location: When coordinating with @conceptual-planning-agent, ALWAYS specify exact output location:
**Correct Agent Delegation:** **Correct Agent Delegation:**
``` ```

View File

@@ -14,7 +14,7 @@ All task files use this simplified 5-field schema (aligned with workflow-archite
"meta": { "meta": {
"type": "feature|bugfix|refactor|test|docs", "type": "feature|bugfix|refactor|test|docs",
"agent": "code-developer|planning-agent|code-review-test-agent" "agent": "@code-developer|@planning-agent|@code-review-test-agent"
}, },
"context": { "context": {
@@ -145,17 +145,17 @@ Tasks inherit from:
## Agent Mapping ## Agent Mapping
### Automatic Agent Selection ### Automatic Agent Selection
- **code-developer**: Implementation tasks, coding - **@code-developer**: Implementation tasks, coding
- **planning-agent**: Design, architecture planning - **@planning-agent**: Design, architecture planning
- **code-review-test-agent**: Testing, validation - **@code-review-test-agent**: Testing, validation
- **review-agent**: Code review, quality checks - **@review-agent**: Code review, quality checks
### Agent Context Filtering ### Agent Context Filtering
Each agent receives tailored context: Each agent receives tailored context:
- **code-developer**: Complete implementation details - **@code-developer**: Complete implementation details
- **planning-agent**: High-level requirements, risks - **@planning-agent**: High-level requirements, risks
- **test-agent**: Files to test, logic flows to validate - **@test-agent**: Files to test, logic flows to validate
- **review-agent**: Quality standards, security considerations - **@review-agent**: Quality standards, security considerations
## Deprecated Fields ## Deprecated Fields

View File

@@ -114,7 +114,7 @@ All task files use this unified 5-field schema:
"meta": { "meta": {
"type": "feature|bugfix|refactor|test|docs", "type": "feature|bugfix|refactor|test|docs",
"agent": "code-developer|planning-agent|code-review-test-agent" "agent": "@code-developer|@planning-agent|@code-review-test-agent"
}, },
"context": { "context": {
@@ -394,10 +394,10 @@ fi
### Agent Assignment ### Agent Assignment
Based on task type and title keywords: Based on task type and title keywords:
- **Planning tasks** → planning-agent - **Planning tasks** → @planning-agent
- **Implementation** → code-developer - **Implementation** → @code-developer
- **Testing** → code-review-test-agent - **Testing** → @code-review-test-agent
- **Review** → review-agent - **Review** → @review-agent
### Execution Context ### Execution Context
Agents receive complete task JSON plus workflow context: Agents receive complete task JSON plus workflow context: