-
-
Notifications
You must be signed in to change notification settings - Fork 3
Description
Parent: #731
Purpose
Add context: fork and agent to analysis/research-oriented skills so they run in an isolated subagent. This prevents polluting the main conversation context and returns only independent analysis results.
v2.0 Rule
context: fork: Runs in an isolated subagent. The skill content becomes the subagent's prompt.
agent: Specifies the subagent type. Options:Explore(read-only),Plan(planning),general-purpose(full tools).
Important Note
context: forkonly makes sense for skills with explicit instructions. If your skill contains guidelines without a task, the subagent receives the guidelines but no actionable prompt.
Therefore, each skill must be verified to contain explicit task instructions before applying fork.
Target Files (4 files)
1. packages/rules/.ai-rules/skills/code-explanation/SKILL.md
context: fork
agent: ExploreReason: Code explanation is read-only exploration; no conversation context needed. Explore agent is optimal.
2. packages/rules/.ai-rules/skills/security-audit/SKILL.md
context: fork
agent: general-purposeReason: Security audit can run as independent analysis. Requires grep/bash access, so general-purpose.
3. packages/rules/.ai-rules/skills/pr-review/SKILL.md
context: fork
agent: ExploreReason: PR diff analysis is read-only. Only results are returned to the main context.
4. packages/rules/.ai-rules/skills/performance-optimization/SKILL.md
context: fork
agent: general-purposeReason: Profiling analysis is independent but may need bash execution.
Pre-verification Checklist
Verify each skill's body is suitable for context: fork:
- ✅ Does it have explicit task instructions? (step-by-step procedures, analysis processes, etc.)
- ✅ Does it receive analysis targets via
$ARGUMENTS? - ❌ If it only contains guidelines, fork is unsuitable → add task structure to the skill body in this case
How to Apply
- Verify each skill's body for fork suitability
- If suitable, add
context: fork+agentto the YAML frontmatter - If unsuitable, add minimal task structure to the body before modifying frontmatter
Acceptance Criteria
- All 4 files have
context: fork+agentadded - Each skill returns meaningful results when run in fork mode
- No YAML frontmatter syntax errors
- No changes to existing fields