원클릭으로
create-directive
Guidelines for creating effective workflow directives that orchestrate without redundancy
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Guidelines for creating effective workflow directives that orchestrate without redundancy
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
End-of-session procedure that captures learnings into memory topic files, verifies index consistency, updates current-state.md, and syncs changes to team-lib.
Send an on-demand manual pulse to the ClickUp Pulse channel and optionally register thread-to-task mappings.
Graduated to team-lib — see team-lib/skills/session-debrief/. This stub demonstrates the my-lib → team-lib graduation pattern.
Add aliases, functions, or env vars to ~/.bashrc with section-aware placement
Check and upgrade local workspace files against latest team-lib templates
Compose base + type-override templates with brand tokens to produce fully resolved branded templates. Deep merges base+override, resolves tokenRef dot-paths against brand-tokens.json, and applies brand preference fan-out.
| name | create-directive |
| description | Guidelines for creating effective workflow directives that orchestrate without redundancy |
| summary | Comprehensive guidelines for writing directives: template, anti-patterns, review criteria, and the directive vs skill vs AGENTS.md distinction. Follow when creating or reviewing any directive. |
| version | 1.1.0 |
| created | "2026-01-26T00:00:00.000Z" |
| last_updated | "2026-01-26T00:00:00.000Z" |
| maintainer | pvragon |
| tags | ["directive","documentation","workflow","best-practices"] |
Guidelines for creating effective, non-redundant workflow directives.
Use when you need to create a new directive to orchestrate a multi-step workflow.
Before creating a directive, ask:
Purpose: Orchestrate multi-step workflows
Scope: Entire processes with multiple checkpoints
Example: "Workspace Release Process" - validation → git → CHANGELOG → release notes
Location: directives/
Purpose: Detailed procedure for a specific capability
Scope: Single, focused task
Example: "Check Workspace Consistency" - three verification passes, specific commands
Location: skills/
Purpose: Global agent behavior and principles Scope: All agent operations Example: "Always exclude /archive/ from searches" Location: Root of workspace
[!IMPORTANT] Directives orchestrate. They don't duplicate.
## Step 1: Validate Workspace
Execute the check-workspace-consistency skill:
Follow: `team-lib/skills/_workspace-developer/check-workspace-consistency/SKILL.md`
### Checkpoint
- [ ] Consistency check completed
- [ ] `validate.sh` passes
## Step 1: Validate Workspace
Run these three passes:
### Pass 1: Automated Extraction
Run these commands:
```bash
grep -oP 'ensure_dir \"\\K[^\"]+' ~/ai-workspace/team-lib/_admin/setup_workspace.sh
# ... 20 more lines of commands ...
```
### Pass 2: Documentation Review
Open each file and verify...
# ... 30 more lines of details ...
Problem: The skill already contains this. The directive just repeated it.
---
template: directive
version: 1.0.0
created: YYYY-MM-DD
last_updated: YYYY-MM-DD
maintainer: [your-name]
tags: [relevant, tags]
---
# [Directive Name]
[One-sentence description of the workflow]
## When to Use This Directive
[Clear trigger conditions for when to execute this workflow]
[Optional: Clarify scope - what types of changes/situations this covers]
## User Triggers
**Run this directive when the user asks to:**
- "[Phrase 1]"
- "[Phrase 2]"
## Prerequisites
[Required conditions before starting]
- Item 1
- Item 2
---
## Step 1: [Action Name]
**Goal:** [What this step accomplishes]
### [Execute skill / Run command / Verify condition]
[High-level instruction - reference skills, don't duplicate them]
### Checkpoint
- [ ] Outcome 1 verified
- [ ] Outcome 2 verified
**Do not proceed until checkpoint passes.**
---
## Step 2: [Next Action]
[Continue pattern...]
---
## Output Contract
Define what data flows where after execution:
**Return to context (agent sees this):**
- Summary counts, status messages, error descriptions
- Only what the agent needs to reason about next
**Keep in execution only (never leaves the script):**
- Raw API responses, full data dumps, verbose logs
- Intermediate transformation results
**Write to disk (persists for later use):**
- Full result files (`runtime/deliverables/` or `runtime/.tmp/`)
- Logs, exports, generated artifacts
> **Why:** Keeping raw data out of agent context reduces token usage and
> prevents context window overflow. See `execution-standard.md`.
---
## Final Checklist
**Category 1:**
- [ ] Item
- [ ] Item
**Category 2:**
- [ ] Item
- [ ] Item
---
## Troubleshooting
**Issue:** [Common problem]
- [Solution approach]
---
## Version History
- **v1.0.0** (YYYY-MM-DD): Initial directive created
Before finalizing your directive, check for these anti-patterns:
Bad:
Run the consistency check:
1. Extract directories from setup script: grep -oP 'ensure_dir...'
2. Extract directories from validate script: grep -oP 'check_dir...'
3. Compare for discrepancies: comm -23...
Good:
Execute the check-workspace-consistency skill:
Follow: `team-lib/skills/_workspace-developer/check-workspace-consistency/SKILL.md`
Bad:
## Step 2: Commit Changes
First, check what files have been modified:
```bash
git status
This will show you a list of modified files. Then use git diff to see the changes:
git diff
Review each line carefully. Once satisfied, stage the files:
git add .
[... 20 more lines explaining basic git ...]
**Good:**
```markdown
## Step 2: Commit Changes
For each repository with changes:
1. Review: `git status` and `git diff`
2. Commit: `git add . && git commit -m "[Category] Description"`
### Checkpoint
- [ ] All changes committed
- [ ] Clean working tree
Bad:
## Step 5: Generate Release Notes
Run this command:
```bash
python3 team-lib/skills/_workspace-developer/generate-release-notes/generate_release_notes.py --last-run
Or use this command for a specific date:
python3 team-lib/skills/_workspace-developer/generate-release-notes/generate_release_notes.py --since "YYYY-MM-DD"
[... command documentation ...]
**Good:**
```markdown
## Step 5: Generate Release Notes
Execute the generate-release-notes skill:
Follow: `team-lib/skills/_workspace-developer/generate-release-notes/SKILL.md`
**Recommended:** Use `--last-run` for auto-detection.
Bad:
## Step 1: Do A and B
Do task A.
Do task B.
### Checkpoint
- [ ] A completed
## Step 2: Do C
Do task C.
### Checkpoint
- [ ] B completed
- [ ] C completed
Good:
## Step 1: Do A and B
Do task A.
Do task B.
### Checkpoint
- [ ] A completed
- [ ] B completed
## Step 2: Do C
Do task C.
### Checkpoint
- [ ] C completed
Key Principles:
Bad:
## Step 3: Fetch API Data
Run the API script and review all results:
```bash
python3 executions/fetch_data.py --all
Copy the full JSON output and analyze it.
**Good:**
```markdown
## Step 3: Fetch and Summarize API Data
Run the API script — it returns a summary dict, not raw data:
```python
from executions.fetch_data import run
result = run(target="all")
# result = {"status": "ok", "total": 42, "errors": 0}
Raw data stays on disk at runtime/.tmp/fetch_results.json.
Only the summary enters your context.
---
## Review Criteria
Before considering your directive complete, verify:
### Content Quality
- [ ] **Scope is clear:** When to use this directive is explicit
- [ ] **User Triggers defined:** Clear mappings from user intent to execution
- [ ] **Steps reference skills:** Not re-documenting existing procedures
- [ ] **Checkpoints are actionable:** Clear pass/fail criteria
- [ ] **No basic explanations:** Git, file ops, etc. are assumed knowledge
### Structure
- [ ] **Has frontmatter:** version, dates, maintainer, tags
- [ ] **Prerequisites listed:** Required conditions before starting
- [ ] **Steps are numbered:** Clear sequence
- [ ] **Each step has goal:** Purpose is stated
- [ ] **Checkpoints after steps:** Verification before proceeding
- [ ] **Final checklist exists:** Comprehensive verification
- [ ] **Troubleshooting included:** Common issues addressed
### Maintainability
- [ ] **Version history updated:** Changes tracked
- [ ] **No hardcoded paths:** Uses variables or clear examples
- [ ] **Skills linked properly:** Correct paths to referenced skills
- [ ] **Registry updated:** Added to `registry/directives.yaml`
---
## Workflow: Creating a New Directive
1. **Define the workflow:**
- What's the end-to-end process?
- What are the major steps/phases?
- What skills already exist that can be referenced?
2. **Identify checkpoints:**
- Where are the natural verification points?
- What must be true before proceeding to next step?
- What are the blocking vs. non-blocking checks?
3. **Draft using template:**
- Start with frontmatter
- Write "When to Use" section
- List prerequisites
- Create step structure with goals and checkpoints
4. **Apply anti-pattern checklist:**
- Remove any skill re-documentation
- Remove basic competency explanations
- Condense command listings into skill references
- Verify checkpoint boundaries
5. **Add metadata:**
- Version history
- Tags for discoverability
- Update registry: `registry/directives.yaml`
6. **Review:**
- Can an agent follow this without ambiguity?
- Is every step either a skill reference or a simple action?
- Are checkpoints clear and verifiable?
---
## File Locations
**Team directives:** `team-lib/directives/[directive-name].md`
- Workflows affecting team workspace
- Shared processes all team members use
**Personal directives:** `my-lib/directives/[directive-name].md`
- Custom workflows specific to you
- Personal automation processes
**After creating a team directive:**
- Update `team-lib/registry/directives.yaml`
- Follow workspace-release-process to publish
---
## Common Pitfalls
**Over-specifying:** Listing multiple command options instead of recommending one approach
**Under-specifying:** Vague instructions without clear goals or checkpoints
**Mixing levels:** Jumping between high-level orchestration and low-level commands in the same step - stay consistent
---
## Version History
- **v1.1.0** (2026-01-26): Added "User Triggers" to template and checklist (DOE Framework)
- **v1.0.0** (2026-01-26): Initial skill created based on lessons from workspace-release-process directive