with one click
opsx-apply
Implement tasks from an OpenSpec change (Experimental)
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Menu
Implement tasks from an OpenSpec change (Experimental)
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Based on SOC occupation classification
Reset the OpenRegister development environment (stop, remove volumes, restart, install apps)
Iteratively run apply→verify in a loop until verify passes, then auto-archive — runs per-app in Docker context
Process multiple OpenSpec changes in parallel using subagents — full lifecycle from proposal to merged PR
Run automated browser tests for a Nextcloud app — single agent or multi-perspective parallel testing
Apply openspec/app-config.json changes to the actual Nextcloud app files — applies configuration decisions made in app-explore back into the codebase
Verify that a Nextcloud app's files match its openspec/app-config.json — read-only audit that reports drift between config and code
| name | opsx-apply |
| description | Implement tasks from an OpenSpec change (Experimental) |
| metadata | {"category":"Workflow","tags":["workflow","artifacts","experimental"]} |
Check the active model from your system context (it appears as "You are powered by the model named…").
"This command requires Sonnet or Opus — implementing tasks from OpenSpec changes needs stronger reasoning than Haiku can reliably provide. Please switch to Sonnet (
/model sonnet) or Opus (/model opus) and re-run."
Implement tasks from an OpenSpec change.
Input: Optionally specify a change name (e.g., /opsx-apply add-auth). If omitted, check if it can be inferred from conversation context. If vague or ambiguous you MUST prompt for available changes.
Steps
Select the change
If a name is provided, use it. Otherwise:
openspec list --json to get available changes and use the AskUserQuestion tool to let the user selectAlways announce: "Using change: " and how to override (e.g., /opsx-apply <other>).
Check status to understand the schema
openspec status --change "<name>" --json
Parse the JSON to understand:
schemaName: The workflow being used (e.g., "spec-driven")Get apply instructions
openspec instructions apply --change "<name>" --json
This returns:
Handle states:
state: "blocked" (missing artifacts): show message, suggest using /opsx-continuestate: "all_done": congratulate, suggest archiveLoad architectural context
Before reading change-specific files, load ALL applicable ADRs. These are hard constraints on implementation — violating an ADR is a bug.
| Location | What | Priority |
|---|---|---|
openspec/changes/<name>/context-brief.md | Specter intelligence brief — features, user stories, stakeholders, schemas, standards. Contains market research data that informed the spec. | Load if present — provides domain context for implementation decisions |
.claude/openspec/architecture/adr-*.md | Company-wide ADRs (13 Conduction-wide decisions: data layer, API patterns, frontend, security, i18n, testing, etc.) | Always load — these are non-negotiable |
openspec/architecture/adr-*.md | Repo-specific ADRs (app's data model, workflows, standards compliance, security model) | Always load if present |
docs/ARCHITECTURE.md | App-specific technology decisions and component structure | Load if present |
Read these silently. Key ADRs to enforce during implementation:
Read context files
Read the files listed in contextFiles from the apply instructions output.
The files depend on the schema being used:
Additionally, load optional artifacts if present:
openspec/changes/<name>/contract.md — if it exists, treat it as the authoritative interface definition. Do not deviate from its declared endpoints, schemas, or error codes during implementation.openspec/changes/<name>/test-plan.md — if it exists, use it to guide verification steps for each task. Each TC's acceptance criteria tell you how to verify the task is done.Show current progress and confirm
Display:
Then use AskUserQuestion to ask:
"Ready to implement remaining tasks for
<change-name>?"
Options:
Implement tasks (loop until done or blocked)
For each pending task:
tests/Unit/ or tests/unit/ with at least 3 test methods covering the happy path, error handling, and edge cases- [ ] → - [x]plan.json exists):
openspec/changes/<name>/plan.json, find the tracking_issue numberget_issue → {owner, repo, issue_number: <tracking_issue>} → find the task's checkbox line (by title) → change - [ ] to - [x] for the task AND its nested acceptance criteria → update_issue → {owner, repo, issue_number: <tracking_issue>, body: <updated_body>}gh issue view <tracking_issue> --repo <repo> --json body --jq '.body' → update the task's checkbox line and its nested criteria → gh issue edit <tracking_issue> --repo <repo> --body "<updated_body>"plan.json: set "status": "done" for that taskSeed data requirement (ADR-016):
lib/Settings/{app}_register.jsondesign.md as the source — it defines objects, field values, and related items@self envelope pattern (register, schema, slug) per ADR-013design.md has no Seed Data section, flag this and suggest adding one before continuingPause if:
On completion or pause, show status
Display:
If all tasks done: proceed to Step 8 (quality checks).
If plan.json exists and all tasks are now done: add a comment to the issue (do NOT close it):
add_issue_comment → {owner, repo, issue_number: <tracking_issue>, body: "✓ All tasks implemented. Running quality checks."}gh issue comment <tracking_issue> --repo <repo> --body "✓ All tasks implemented. Running quality checks."Run code quality checks
After all tasks are complete, run the full quality suite from the project directory.
PHP quality (if the project has a composer.json with quality scripts):
cd <project-dir> && composer check:strict 2>&1
This runs: lint + named-args check + phpcs + phpmd + psalm + phpstan + unit tests.
If check:strict is not available, fall back to running individually:
composer phpcs 2>&1
composer phpmd 2>&1
composer psalm 2>&1
Frontend quality (if the project has a package.json with lint scripts):
cd <project-dir> && npm run lint 2>&1
npm run stylelint 2>&1
Handle failures:
composer phpcs:fix (PHPCBF auto-fixes ~60% of PHPCS issues)npm run lint -- --fix (ESLint auto-fix)Show quality results:
## Quality Checks
| Tool | Status |
|------|--------|
| PHPCS | ✓ Pass (or X errors fixed) |
| PHPMD | ✓ Pass |
| Psalm | ✓ Pass |
| PHPStan | ✓ Pass |
| ESLint | ✓ Pass |
| Stylelint | ✓ Pass |
| Unit Tests | ✓ Pass (N tests) |
Ask what's next
After quality checks pass (or remaining issues are reported), show the completion summary, then use AskUserQuestion to ask:
"Implementation complete! What would you like to do next?"
Options:
/opsx-verify) — recommended: check the code matches specs and run API/browser tests/team-reviewer) — have a reviewer look at the code before verifying/opsx-sync) — sync this change's specs to main specs first/opsx-archive) — skip verification if already reviewed externallyOutput During Implementation
## Implementing: <change-name> (schema: <schema-name>)
Working on task 3/7: <task description>
[...implementation happening...]
✓ Task complete
Working on task 4/7: <task description>
[...implementation happening...]
✓ Task complete
Output On Completion
## Implementation Complete
**Change:** <change-name>
**Schema:** <schema-name>
**Progress:** 7/7 tasks complete ✓
### Completed This Session
- [x] Task 1
- [x] Task 2
...
### Quality Checks
| Tool | Status |
|------|--------|
| PHPCS | ✓ Pass |
| PHPMD | ✓ Pass |
| Psalm | ✓ Pass |
| ESLint | ✓ Pass |
| Unit Tests | ✓ 42 tests passed |
**What's Next**
Recommended: `/opsx-verify` | Optional: `/team-reviewer`, `/opsx-sync` | Alternative: `/opsx-archive`
Output On Pause (Issue Encountered)
## Implementation Paused
**Change:** <change-name>
**Schema:** <schema-name>
**Progress:** 4/7 tasks complete
### Issue Encountered
<description of the issue>
**Options:**
1. <option 1>
2. <option 2>
3. Other approach
What would you like to do?
Guardrails
Fluid Workflow Integration
This skill supports the "actions on a change" model:
💡 If you switched models to run this command, don't forget to switch back to your preferred model with
/model <name>(e.g./model defaultor/model sonnet) when done.