Skip to content

Commit 9ee9b3d

Browse files
authored
Merge pull request #22 from lexler/add-yak-shave-delegation-pattern
Add Yak Shave Delegation pattern
2 parents b1858b6 + d7febbd commit 9ee9b3d

2 files changed

Lines changed: 30 additions & 0 deletions

File tree

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
---
2+
authors: [ivett_ordog]
3+
---
4+
5+
# 🐃 Yak Shave Delegation
6+
7+
## Problem
8+
9+
Yak shaving breaks flow and context for both you and your primary agent. Environment issues derail focus even though they're often trivial to fix.
10+
11+
## Pattern
12+
13+
When a tangential issue blocks your main work, spawn a separate agent to handle it instead of switching context yourself.
14+
15+
1. Hit an environment/tooling issue (compiler error, missing dependency, config problem)
16+
2. Recognize it's yak shaving - not your core task
17+
3. Spawn a separate agent to handle it (error messages usually contain the fix instructions)
18+
4. Continue your main work with your primary agent
19+
5. Check back when the yak-shave agent signals it's done
20+
21+
This keeps both you and your main agent focused on the core problem while the yak shave gets resolved in parallel.
22+
23+
## Example
24+
25+
Returning to a project after some time, the codebase has moved on. Running the app fails - needs a new Ruby runtime, recompiled libraries, and config changes.
26+
27+
Instead of context-switching to fix these, spawn an agent with the error output. The agent installs Ruby, recompiles dependencies, and updates config while you and your primary agent continue exploring the codebase and planning the next feature.

documents/relationships.mmd

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,9 @@ graph LR
8282
patterns/happy-to-delete <-->|similar| patterns/playgrounds
8383
patterns/approved-fixtures <-->|similar| patterns/check-alignment
8484
patterns/approved-fixtures <-->|similar| patterns/approved-logs
85+
patterns/yak-shave-delegation -->|uses| patterns/background-agent
86+
patterns/yak-shave-delegation -->|uses| patterns/focused-agent
87+
patterns/yak-shave-delegation -->|solves| anti-patterns/distracted-agent
8588

8689
%% Anti-pattern → Obstacle relationships (causes)
8790
anti-patterns/distracted-agent -->|causes| obstacles/limited-focus

0 commit comments

Comments
 (0)