Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions .claude/commands/AGENTS.md

This file was deleted.

75 changes: 75 additions & 0 deletions .claude/commands/add_platform.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
---
description: Add a new AI platform to DeepWork with adapter, templates, and tests
---

# add_platform

You are executing the **add_platform** job. Add a new AI platform to DeepWork with adapter, templates, and tests

A workflow for adding support for a new AI platform (like Cursor, Windsurf, etc.) to DeepWork.

This job guides you through four phases:
1. **Research**: Capture the platform's CLI configuration and hooks system documentation
2. **Add Capabilities**: Update the job schema and adapters with any new hook events
3. **Implement**: Create the platform adapter, templates, tests (100% coverage), and README updates
4. **Verify**: Ensure installation works correctly and produces expected files

The workflow ensures consistency across all supported platforms and maintains
comprehensive test coverage for new functionality.

**Important Notes**:
- Only hooks available on slash command definitions should be captured
- Each existing adapter must be updated when new hooks are added (typically with null values)
- Tests must achieve 100% coverage for any new functionality
- Installation verification confirms the platform integrates correctly with existing jobs


## Available Steps

This job has 4 step(s):

### research
**Research Platform Documentation**: Capture CLI configuration and hooks system documentation for the new platform
- Command: `uw.add_platform.research`
### add_capabilities
**Add Hook Capabilities**: Update job schema and adapters with any new hook events the platform supports
- Command: `uw.add_platform.add_capabilities`
- Requires: research
### implement
**Implement Platform Support**: Add platform adapter, templates, tests with 100% coverage, and README documentation
- Command: `uw.add_platform.implement`
- Requires: research, add_capabilities
### verify
**Verify Installation**: Set up platform directories and verify deepwork install works correctly
- Command: `uw.add_platform.verify`
- Requires: implement

## Instructions

This is a **multi-step workflow**. Determine the starting point and run through the steps in sequence.

1. **Analyze user intent** from the text that follows `/add_platform`

2. **Identify the starting step** based on intent:
- research: Capture CLI configuration and hooks system documentation for the new platform
- add_capabilities: Update job schema and adapters with any new hook events the platform supports
- implement: Add platform adapter, templates, tests with 100% coverage, and README documentation
- verify: Set up platform directories and verify deepwork install works correctly

3. **Run the workflow** starting from the identified step:
- Invoke the starting step using the Skill tool
- When that step completes, **automatically continue** to the next step in the workflow
- Continue until the workflow is complete or the user intervenes

4. **If intent is ambiguous**, ask the user which step to start from:
- Present the available steps as numbered options
- Use AskUserQuestion to let them choose

**Critical**:
- You MUST invoke each step using the Skill tool. Do not copy/paste step instructions.
- After each step completes, check if there's a next step and invoke it automatically.
- The workflow continues until all dependent steps are complete.

## Context Files

- Job definition: `.deepwork/jobs/add_platform/job.yml`
22 changes: 6 additions & 16 deletions .claude/commands/deepwork_jobs.learn.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,8 @@ hooks:

## Quality Criteria

Verify the learning process meets ALL quality criteria before completing:

1. **Conversation Analyzed**: Did you review the conversation for DeepWork job executions?
2. **Confusion Identified**: Did you identify points of confusion, errors, or inefficiencies?
1. **Conversation Analyzed**: Did the agent review the conversation for DeepWork job executions?
2. **Confusion Identified**: Did the agent identify points of confusion, errors, or inefficiencies?
3. **Instructions Improved**: Were job instructions updated to address identified issues?
4. **Instructions Concise**: Are instructions free of redundancy and unnecessary verbosity?
5. **Shared Content Extracted**: Is lengthy/duplicated content extracted into referenced files?
Expand All @@ -22,10 +20,6 @@ hooks:
9. **Generalizable Separated**: Are generalizable improvements in instructions, not AGENTS.md?
10. **Sync Complete**: Has `deepwork sync` been run if instructions were modified?

If ANY criterion is not met, continue working to address it.
If ALL criteria are satisfied, include `<promise>✓ Quality Criteria Met</promise>` in your response.


## Instructions

Review the conversation and determine if ALL quality criteria above have been satisfied.
Expand All @@ -34,8 +28,8 @@ hooks:
If the agent has included `<promise>✓ Quality Criteria Met</promise>` in their response AND
all criteria appear to be met, respond with: {"ok": true}

If criteria are NOT met AND the promise tag is missing, respond with:
{"ok": false, "reason": "Continue working. [specific feedback on what's wrong]"}
If criteria are NOT met OR the promise tag is missing, respond with:
{"ok": false, "reason": "**AGENT: TAKE ACTION** - [which criteria failed and why]"}
---

# deepwork_jobs.learn
Expand Down Expand Up @@ -386,10 +380,9 @@ Ensure all outputs are:
This step uses an iterative quality validation loop. After completing your work, stop hook(s) will evaluate whether the outputs meet quality criteria. If criteria are not met, you will be prompted to continue refining.

### Quality Criteria
Verify the learning process meets ALL quality criteria before completing:

1. **Conversation Analyzed**: Did you review the conversation for DeepWork job executions?
2. **Confusion Identified**: Did you identify points of confusion, errors, or inefficiencies?
1. **Conversation Analyzed**: Did the agent review the conversation for DeepWork job executions?
2. **Confusion Identified**: Did the agent identify points of confusion, errors, or inefficiencies?
3. **Instructions Improved**: Were job instructions updated to address identified issues?
4. **Instructions Concise**: Are instructions free of redundancy and unnecessary verbosity?
5. **Shared Content Extracted**: Is lengthy/duplicated content extracted into referenced files?
Expand All @@ -399,9 +392,6 @@ Verify the learning process meets ALL quality criteria before completing:
9. **Generalizable Separated**: Are generalizable improvements in instructions, not AGENTS.md?
10. **Sync Complete**: Has `deepwork sync` been run if instructions were modified?

If ANY criterion is not met, continue working to address it.
If ALL criteria are satisfied, include `<promise>✓ Quality Criteria Met</promise>` in your response.


### Completion Promise

Expand Down
63 changes: 63 additions & 0 deletions .claude/commands/deepwork_jobs.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
---
description: DeepWork job management commands
---

# deepwork_jobs

You are executing the **deepwork_jobs** job. DeepWork job management commands

Core commands for managing DeepWork jobs. These commands help you define new multi-step
workflows and learn from running them.

The `define` command guides you through an interactive process to create a new job by
asking structured questions about your workflow, understanding each step's inputs and outputs,
and generating all necessary files.

The `learn` command reflects on conversations where DeepWork jobs were run, identifies
confusion or inefficiencies, and improves job instructions. It also captures bespoke
learnings specific to the current run into AGENTS.md files in the working folder.


## Available Steps

This job has 3 step(s):

### define
**Define Job Specification**: Create the job.yml specification file by understanding workflow requirements
- Command: `uw.deepwork_jobs.define`
### implement
**Implement Job Steps**: Generate instruction files for each step based on the job.yml specification
- Command: `uw.deepwork_jobs.implement`
- Requires: define
### learn
**Learn from Job Execution**: Reflect on conversation to improve job instructions and capture learnings
- Command: `deepwork_jobs.learn`

## Instructions

This is a **multi-step workflow**. Determine the starting point and run through the steps in sequence.

1. **Analyze user intent** from the text that follows `/deepwork_jobs`

2. **Identify the starting step** based on intent:
- define: Create the job.yml specification file by understanding workflow requirements
- implement: Generate instruction files for each step based on the job.yml specification
- learn: Reflect on conversation to improve job instructions and capture learnings

3. **Run the workflow** starting from the identified step:
- Invoke the starting step using the Skill tool
- When that step completes, **automatically continue** to the next step in the workflow
- Continue until the workflow is complete or the user intervenes

4. **If intent is ambiguous**, ask the user which step to start from:
- Present the available steps as numbered options
- Use AskUserQuestion to let them choose

**Critical**:
- You MUST invoke each step using the Skill tool. Do not copy/paste step instructions.
- After each step completes, check if there's a next step and invoke it automatically.
- The workflow continues until all dependent steps are complete.

## Context Files

- Job definition: `.deepwork/jobs/deepwork_jobs/job.yml`
59 changes: 59 additions & 0 deletions .claude/commands/deepwork_rules.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
---
description: Rules enforcement for AI agent sessions
---

# deepwork_rules

You are executing the **deepwork_rules** job. Rules enforcement for AI agent sessions

Manages rules that automatically trigger when certain files change during an AI agent session.
Rules help ensure that code changes follow team guidelines, documentation is updated,
and architectural decisions are respected.

Rules are stored as individual markdown files with YAML frontmatter in the `.deepwork/rules/`
directory. Each rule file specifies:
- Detection mode: trigger/safety, set (bidirectional), or pair (directional)
- Patterns: Glob patterns for matching files, with optional variable capture
- Instructions: Markdown content describing what the agent should do

Example use cases:
- Update installation docs when configuration files change
- Require security review when authentication code is modified
- Ensure API documentation stays in sync with API code
- Enforce source/test file pairing


## Available Steps

This job has 1 step(s):

### define
**Define Rule**: Create a new rule file in .deepwork/rules/
- Command: `uw.deepwork_rules.define`

## Instructions

This is a **multi-step workflow**. Determine the starting point and run through the steps in sequence.

1. **Analyze user intent** from the text that follows `/deepwork_rules`

2. **Identify the starting step** based on intent:
- define: Create a new rule file in .deepwork/rules/

3. **Run the workflow** starting from the identified step:
- Invoke the starting step using the Skill tool
- When that step completes, **automatically continue** to the next step in the workflow
- Continue until the workflow is complete or the user intervenes

4. **If intent is ambiguous**, ask the user which step to start from:
- Present the available steps as numbered options
- Use AskUserQuestion to let them choose

**Critical**:
- You MUST invoke each step using the Skill tool. Do not copy/paste step instructions.
- After each step completes, check if there's a next step and invoke it automatically.
- The workflow continues until all dependent steps are complete.

## Context Files

- Job definition: `.deepwork/jobs/deepwork_rules/job.yml`
57 changes: 57 additions & 0 deletions .claude/commands/update.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
---
description: Update standard jobs in src/ and sync to installed locations
---

# update

You are executing the **update** job. Update standard jobs in src/ and sync to installed locations

A workflow for maintaining standard jobs bundled with DeepWork. Standard jobs
(like `deepwork_jobs` and `deepwork_rules`) are source-controlled in
`src/deepwork/standard_jobs/` and must be edited there—never in `.deepwork/jobs/`
or `.claude/commands/` directly.

This job guides you through:
1. Identifying which standard job(s) to update from conversation context
2. Making changes in the correct source location (`src/deepwork/standard_jobs/[job_name]/`)
3. Running `deepwork install` to propagate changes to `.deepwork/` and command directories
4. Verifying the sync completed successfully

Use this job whenever you need to modify job.yml files, step instructions, or hooks
for any standard job in the DeepWork repository.


## Available Steps

This job has 1 step(s):

### job
**Update Standard Job**: Edit standard job source files and sync to installed locations
- Command: `uw.update.job`

## Instructions

This is a **multi-step workflow**. Determine the starting point and run through the steps in sequence.

1. **Analyze user intent** from the text that follows `/update`

2. **Identify the starting step** based on intent:
- job: Edit standard job source files and sync to installed locations

3. **Run the workflow** starting from the identified step:
- Invoke the starting step using the Skill tool
- When that step completes, **automatically continue** to the next step in the workflow
- Continue until the workflow is complete or the user intervenes

4. **If intent is ambiguous**, ask the user which step to start from:
- Present the available steps as numbered options
- Use AskUserQuestion to let them choose

**Critical**:
- You MUST invoke each step using the Skill tool. Do not copy/paste step instructions.
- After each step completes, check if there's a next step and invoke it automatically.
- The workflow continues until all dependent steps are complete.

## Context Files

- Job definition: `.deepwork/jobs/update/job.yml`
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,6 @@ hooks:
- hooks:
- type: prompt
prompt: |
You must evaluate whether Claude has met all the below quality criteria for the request.

## Quality Criteria

Verify the capability additions meet ALL criteria:
1. Any new hooks from the platform (for slash commands only) are added to src/deepwork/schemas/job_schema.py
2. All existing adapters in src/deepwork/adapters.py are updated with the new hook fields
Expand All @@ -20,17 +16,6 @@ hooks:

If ALL criteria are met, include `<promise>✓ Quality Criteria Met</promise>`.


## Instructions

Review the conversation and determine if ALL quality criteria above have been satisfied.
Look for evidence that each criterion has been addressed.

If the agent has included `<promise>✓ Quality Criteria Met</promise>` in their response AND
all criteria appear to be met, respond with: {"ok": true}

If criteria are NOT met AND the promise tag is missing, respond with:
{"ok": false, "reason": "Continue working. [specific feedback on what's wrong]"}
---

# add_platform.add_capabilities
Expand Down Expand Up @@ -241,17 +226,6 @@ Ensure all outputs are:

This step uses an iterative quality validation loop. After completing your work, stop hook(s) will evaluate whether the outputs meet quality criteria. If criteria are not met, you will be prompted to continue refining.

### Quality Criteria
Verify the capability additions meet ALL criteria:
1. Any new hooks from the platform (for slash commands only) are added to src/deepwork/schemas/job_schema.py
2. All existing adapters in src/deepwork/adapters.py are updated with the new hook fields
(set to None/null if the platform doesn't support that hook)
3. Only hooks available on slash command definitions are added (not general CLI hooks)
4. job_schema.py remains valid Python with no syntax errors
5. adapters.py remains consistent - all adapters have the same hook fields
6. If no new hooks are needed, document why in a comment

If ALL criteria are met, include `<promise>✓ Quality Criteria Met</promise>`.


### Completion Promise
Expand Down
Loading