Skip to content

Commit 15c85af

Browse files
nhortonclaude
andcommitted
refactor: deprecate steps/ folder pattern in job definitions
Step instructions are now inlined in job.yml. This removes all references to the steps/ folder pattern across documentation, AGENTS.md files, .deepreview rules, CI tests, and job instructions. Supplemental reference files are moved from steps/ to the job root directory. The repair workflow retains steps/ references for migrating legacy jobs, and now instructs agents to `git rm` step instruction files after inlining. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 6ef1bdc commit 15c85af

18 files changed

Lines changed: 51 additions & 121 deletions

File tree

.deepwork/jobs/test_job_flow/AGENTS.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,7 @@ This folder and its subfolders are managed using `deepwork_jobs` workflows.
1313
```
1414
.
1515
├── AGENTS.md # This file - project context and guidance
16-
├── job.yml # Job specification (created by define step)
17-
├── steps/ # Step instruction files (created by implement step)
18-
│ └── *.md # One file per step
16+
├── job.yml # Job specification with inline step instructions
1917
├── hooks/ # Custom validation scripts and prompts
2018
│ └── *.md|*.sh # Hook files referenced in job.yml
2119
├── scripts/ # Reusable scripts and utilities created during job execution

.deepwork/jobs/test_job_flow/job.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,8 +90,8 @@ workflows:
9090
completed on first try or required retries.
9191
9292
2. **Verify completion**: Confirm `.deepwork/jobs/detailed_test_review/job.yml`
93-
exists with expected structure (2 steps, correct outputs, reviews). Check
94-
step instruction files exist in `steps/`.
93+
exists with expected structure (2 steps, correct outputs, reviews, and
94+
inline step instructions).
9595
9696
3. **Identify friction points**: Look for errors, workarounds, retries, confusion,
9797
unnecessary steps, slow paths, and missing guidance in the transcript.

.deepwork/learning-agents/consistency-reviewer/core-knowledge.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ There are exactly three types of jobs. Confusing them is one of the most common
3434
### Key File Patterns
3535

3636
- `job.yml` — Job definitions with steps, workflows, outputs, reviews, quality criteria
37-
- `steps/*.md` — Step instruction files (markdown with structured guidance)
37+
- Step instructions are inlined in `job.yml` (the `steps/` folder pattern is deprecated)
3838
- `hooks/` — Lifecycle hooks (after_agent, before_tool, etc.)
3939
- `.claude/agents/*.md` — Agent definitions with YAML frontmatter (name, description)
4040
- `AGENTS.md` — Bespoke learnings and context for a working directory

.github/workflows/claude-code-test.yml

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -310,18 +310,12 @@ jobs:
310310
exit 1
311311
fi
312312
313-
# Verify step files were created
314-
echo "=== Checking step files were created ==="
315-
if [ -f ".deepwork/jobs/fruits/steps/identify.md" ] && [ -f ".deepwork/jobs/fruits/steps/classify.md" ]; then
316-
echo "SUCCESS: Step instruction files created"
317-
echo "--- identify.md ---"
318-
cat .deepwork/jobs/fruits/steps/identify.md
319-
echo ""
320-
echo "--- classify.md ---"
321-
cat .deepwork/jobs/fruits/steps/classify.md
313+
# Verify step instructions are inlined in job.yml
314+
echo "=== Checking step instructions are inlined ==="
315+
if grep -q 'instructions:' .deepwork/jobs/fruits/job.yml; then
316+
echo "SUCCESS: Step instructions are inlined in job.yml"
322317
else
323-
echo "ERROR: Step files were not created"
324-
ls -la .deepwork/jobs/fruits/steps/ || echo "No steps directory"
318+
echo "ERROR: No inline step instructions found in job.yml"
325319
exit 1
326320
fi
327321

doc/doc-specs.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,8 @@ steps:
9393
- id: generate_report
9494
name: "Generate Monthly Report"
9595
description: "Create the monthly AWS spending report"
96-
instructions_file: steps/generate_report.md
96+
instructions: |
97+
Generate the monthly AWS spending report...
9798
outputs:
9899
- file: reports/aws_spending.md
99100
doc_spec: .deepwork/doc_specs/monthly_aws_report.md

library/jobs/.deepreview

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ library_job_portability:
3030
match:
3131
include:
3232
- "**/job.yml"
33-
- "**/steps/*.md"
33+
- "**/conventions.md"
3434
- "**/readme.md"
3535
- "**/conventions.md"
3636
- "**/templates/*.template"
@@ -51,7 +51,7 @@ library_job_portability:
5151
- Workspace-relative paths that assume a specific repo layout
5252
(e.g., `.repos/acme/api/` or `/code/myproject/`)
5353

54-
Acceptable: relative paths within the job directory (e.g., `steps/foo.md`,
54+
Acceptable: relative paths within the job directory (e.g., `templates/bar.yml`,
5555
`templates/bar.yml`) and generic placeholders like `<project_root>`.
5656

5757
## Personal and Private Information

library/jobs/README.md

Lines changed: 6 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -74,49 +74,22 @@ library/jobs/
7474
│ ├── job.yml
7575
│ ├── AGENTS.md # Agent context and learnings
7676
│ ├── CLAUDE.md -> AGENTS.md
77-
│ ├── requirements.md # RFC 2119 requirements specification
78-
│ └── steps/ # Step instruction files (also inlined in job.yml)
77+
│ └── requirements.md # RFC 2119 requirements specification
7978
├── platform_engineer/ # Platform engineering workflows
8079
│ ├── job.yml
8180
│ ├── AGENTS.md # Agent context and learnings
8281
│ ├── CLAUDE.md -> AGENTS.md
8382
│ ├── conventions.md # RFC 2119 platform engineering standards
8483
│ ├── readme.md
85-
│ ├── steps/ # Step instruction files (also inlined in job.yml)
8684
│ └── templates/ # Output templates
8785
├── repo/
88-
│ ├── job.yml # Job definition (name, steps, workflows)
89-
│ ├── readme.md # Job-specific documentation
90-
│ └── steps/
91-
│ ├── detect_platform.md
92-
│ ├── ensure_labels.md
93-
│ ├── check_branch_protection.md
94-
│ ├── check_milestones.md
95-
│ ├── check_boards.md
96-
│ ├── setup_report.md
97-
│ ├── audit_labels.md
98-
│ ├── audit_branch_protection.md
99-
│ ├── audit_milestones.md
100-
│ ├── audit_boards.md
101-
│ └── doctor_report.md
86+
│ ├── job.yml # Job definition (self-contained with inline instructions)
87+
│ └── readme.md # Job-specific documentation
10288
├── research/
103-
│ ├── job.yml # Job definition (name, steps, workflows)
89+
│ ├── job.yml # Job definition (self-contained with inline instructions)
10490
│ ├── readme.md # Job-specific documentation
10591
│ ├── AGENTS.md # Agent context and learnings
106-
│ ├── CLAUDE.md -> AGENTS.md
107-
│ └── steps/
108-
│ ├── scope.md
109-
│ ├── choose_platforms.md
110-
│ ├── gather.md
111-
│ ├── gather_quick.md
112-
│ ├── synthesize.md
113-
│ ├── summarize.md
114-
│ ├── report.md
115-
│ ├── parse.md
116-
│ ├── file.md
117-
│ ├── ingest_material.md
118-
│ ├── analyze.md
119-
│ └── plan.md
92+
│ └── CLAUDE.md -> AGENTS.md
12093
└── spec_driven_development/
12194
├── job.yml # Job definition (self-contained with inline instructions)
12295
└── readme.md # Job-specific documentation
@@ -147,7 +120,7 @@ The job definition file contains:
147120
- `process_requirements`: Optional quality criteria for the work process
148121
- `post_workflow_instructions`: Optional instructions shown after workflow completes
149122

150-
Step instructions are inlined in `job.yml`. Some jobs also retain separate `steps/*.md` files from earlier versions; the inline `instructions` in `job.yml` are the canonical source.
123+
Step instructions are inlined in `job.yml` using YAML block scalars (`instructions: |`).
151124

152125
## Using a Job from the Library
153126

library/jobs/engineer/.deepreview

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,13 @@ job_definition_review:
33
match:
44
include:
55
- "job.yml"
6-
- "steps/*.md"
76
- "requirements.md"
87
review:
98
strategy: matches_together
109
instructions: |
11-
Review this DeepWork job definition (job.yml), its requirements (requirements.md),
12-
and its step instruction files (steps/*.md) holistically. Check that they form a
13-
coherent, well-structured workflow that an AI agent can execute reliably.
10+
Review this DeepWork job definition (job.yml) and its requirements (requirements.md)
11+
holistically. Check that they form a coherent, well-structured workflow that an AI
12+
agent can execute reliably.
1413

1514
## Reference Material
1615

library/jobs/engineer/AGENTS.md

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -11,18 +11,8 @@ It is a library job — available for users to adopt but not auto-installed by t
1111
engineer/
1212
├── AGENTS.md # This file
1313
├── CLAUDE.md -> AGENTS.md # Symlink for Claude Code
14-
├── job.yml # Job definition
15-
├── requirements.md # RFC 2119 requirements specification
16-
└── steps/
17-
├── translate_issue.md
18-
├── initialize_branch.md
19-
├── red_tests.md
20-
├── green_implementation.md
21-
├── finalize_pr.md
22-
├── product_sync.md
23-
├── check_agent_md.md
24-
├── check_context.md
25-
└── doctor_report.md
14+
├── job.yml # Job definition (all step instructions inlined)
15+
└── requirements.md # RFC 2119 requirements specification
2616
```
2717

2818
## Workflows

library/jobs/platform_engineer/AGENTS.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ platform_engineer/
1919
├── conventions.md # RFC 2119 platform engineering standards
2020
├── readme.md # User-facing documentation
2121
├── AGENTS.md # This file — agent context and learnings
22-
├── steps/ # Step instruction files
2322
└── templates/ # Output templates
2423
```
2524

0 commit comments

Comments
 (0)