Skip to content
Open
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
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`
73 changes: 73 additions & 0 deletions .claude/commands/commit.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
---
description: Validate, format, and push changes with tests passing
---

# commit

You are executing the **commit** job. Validate, format, and push changes with tests passing

A pre-commit workflow that ensures code quality before pushing changes.

This job runs through three validation and preparation steps:
1. Runs the test suite and fixes any failures until all tests pass (max 5 attempts)
2. Runs ruff formatting and linting, fixing issues until clean (max 5 attempts)
3. Fetches from remote, rebases if needed, generates a simple commit message,
commits changes, and pushes to the remote branch

Each step uses a quality validation loop to ensure it completes successfully
before moving to the next step. The format step runs as a subagent to
minimize token usage.

Key behaviors:
- Rebase strategy when remote has changes (keeps linear history)
- Simple summary commit messages (no conventional commits format)
- Maximum 5 fix attempts before stopping

Designed for developers who want a reliable pre-push workflow that catches
issues early and ensures consistent code quality.


## Available Steps

This job has 3 step(s):

### test
**Run Tests**: Run pytest and fix any failures until all tests pass (max 5 attempts)
- Command: `uw.commit.test`
### format
**Format Code**: Run ruff formatting and linting, fix issues until clean (max 5 attempts, runs as subagent)
- Command: `uw.commit.format`
- Requires: test
### reconcile_and_push
**Reconcile and Push**: Fetch remote, rebase if needed, commit with simple summary message, and push
- Command: `uw.commit.reconcile_and_push`
- Requires: format

## 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 `/commit`

2. **Identify the starting step** based on intent:
- test: Run pytest and fix any failures until all tests pass (max 5 attempts)
- format: Run ruff formatting and linting, fix issues until clean (max 5 attempts, runs as subagent)
- reconcile_and_push: Fetch remote, rebase if needed, commit with simple summary message, and push

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/commit/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_policy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
---
description: Policy enforcement for AI agent sessions
---

# deepwork_policy

You are executing the **deepwork_policy** job. Policy enforcement for AI agent sessions

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

Policies are defined in a `.deepwork.policy.yml` file at the root of your project. Each policy
specifies:
- Trigger patterns: Glob patterns for files that, when changed, should trigger the policy
- Safety patterns: Glob patterns for files that, if also changed, mean the policy doesn't need to fire
- Instructions: What the agent should do when the policy triggers

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
- Remind developers to update changelogs


## Available Steps

This job has 1 step(s):

### define
**Define Policy**: Create or update policy entries in .deepwork.policy.yml
- Command: `uw.deepwork_policy.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_policy`

2. **Identify the starting step** based on intent:
- define: Create or update policy entries in .deepwork.policy.yml

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_policy/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_policy`) 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`
Loading