opencode-onboard 0.3.3 → 0.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (87) hide show
  1. package/README.md +278 -214
  2. package/content/.agents/agents/basic-engineer.md +30 -0
  3. package/content/.agents/agents/devops-manager.md +38 -29
  4. package/content/.agents/session-log.json +41 -0
  5. package/content/.agents/skills/ob-default/SKILL.md +21 -0
  6. package/content/.agents/skills/ob-generic-guardrails/SKILL.md +32 -0
  7. package/content/.agents/skills/ob-global/SKILL.md +49 -0
  8. package/content/.agents/skills/ob-pullrequest-az/SKILL.md +11 -21
  9. package/content/.agents/skills/ob-pullrequest-gh/SKILL.md +14 -24
  10. package/content/.agents/skills/ob-userstory-az/SKILL.md +8 -14
  11. package/content/.agents/skills/ob-userstory-gh/SKILL.md +6 -14
  12. package/content/.opencode/commands/init.md +8 -0
  13. package/content/.opencode/commands/main.md +17 -0
  14. package/content/.opencode/commands/opsx-apply.md +50 -33
  15. package/content/.opencode/commands/plan.md +37 -0
  16. package/content/.opencode/plugins/session-log.js +1 -1
  17. package/content/.opencode/skills/openspec-apply-change/SKILL.md +50 -33
  18. package/content/AGENTS.md +94 -144
  19. package/content/skills-lock.json +4 -0
  20. package/package.json +6 -1
  21. package/src/commands/join.js +43 -0
  22. package/src/commands/shared.js +12 -0
  23. package/src/commands/shared.test.js +56 -0
  24. package/src/commands/single.js +64 -0
  25. package/src/commands/wizard.js +99 -0
  26. package/src/index.js +25 -202
  27. package/src/presets/browser.json +18 -0
  28. package/src/presets/clean.json +21 -0
  29. package/src/presets/models.json +33 -0
  30. package/src/presets/optimization.json +22 -0
  31. package/src/presets/platforms.json +29 -2
  32. package/src/presets/quota.json +14 -0
  33. package/src/presets/source.json +17 -0
  34. package/src/steps/browser/browser.test.js +81 -0
  35. package/src/steps/{install-browser.js → browser/index.js} +12 -15
  36. package/src/steps/{__tests__/clean-ai-files.test.js → clean/clean.test.js} +28 -13
  37. package/src/steps/{clean-ai-files.js → clean/index.js} +32 -30
  38. package/src/steps/copy/agents.js +106 -0
  39. package/src/steps/{__tests__/copy-content.test.js → copy/copy.test.js} +10 -1
  40. package/src/steps/copy/index.js +33 -0
  41. package/src/steps/copy/skills.js +55 -0
  42. package/src/steps/{write-onboard-config.js → metadata/index.js} +3 -3
  43. package/src/steps/metadata/metadata.test.js +99 -0
  44. package/src/steps/models/format.js +60 -0
  45. package/src/steps/models/format.test.js +75 -0
  46. package/src/steps/models/index.js +52 -0
  47. package/src/steps/models/write.js +54 -0
  48. package/src/steps/models/write.test.js +117 -0
  49. package/src/steps/{init-openspec.js → openspec/ensemble.js} +20 -57
  50. package/src/steps/openspec/ensemble.test.js +79 -0
  51. package/src/steps/openspec/index.js +32 -0
  52. package/src/steps/optimization/caveman-guidance.js +11 -0
  53. package/src/steps/{install-caveman.js → optimization/caveman.js} +5 -19
  54. package/src/steps/optimization/global.js +64 -0
  55. package/src/steps/optimization/index.js +101 -0
  56. package/src/steps/{__tests__/token-optimization.test.js → optimization/optimization.test.js} +37 -22
  57. package/src/steps/{install-quota.js → optimization/quota.js} +12 -10
  58. package/src/steps/platform/index.js +81 -0
  59. package/src/steps/platform/platform.test.js +129 -0
  60. package/src/steps/{choose-source-scope.js → source/index.js} +11 -17
  61. package/src/steps/source/source.test.js +91 -0
  62. package/src/utils/__tests__/copy.test.js +12 -5
  63. package/src/utils/copy.js +4 -24
  64. package/src/utils/exec-spinner.js +47 -0
  65. package/src/utils/exec.js +120 -162
  66. package/src/utils/models-cache.js +25 -68
  67. package/src/utils/models-pricing.js +42 -0
  68. package/src/utils/models-pricing.test.js +93 -0
  69. package/content/.agents/agents/back-engineer.md +0 -87
  70. package/content/.agents/agents/front-engineer.md +0 -86
  71. package/content/.agents/agents/infra-engineer.md +0 -85
  72. package/content/.agents/agents/quality-engineer.md +0 -86
  73. package/content/.agents/agents/security-auditor.md +0 -86
  74. package/src/steps/__tests__/check-env.test.js +0 -70
  75. package/src/steps/__tests__/check-platform.test.js +0 -104
  76. package/src/steps/__tests__/check-rtk.test.js +0 -38
  77. package/src/steps/__tests__/choose-platform.test.js +0 -38
  78. package/src/steps/check-env.js +0 -26
  79. package/src/steps/check-platform.js +0 -80
  80. package/src/steps/check-rtk.js +0 -38
  81. package/src/steps/choose-models.js +0 -165
  82. package/src/steps/choose-platform.js +0 -22
  83. package/src/steps/choose-skills-provider.js +0 -79
  84. package/src/steps/copy-content.js +0 -89
  85. package/src/steps/enable-caveman-guidance.js +0 -78
  86. package/src/steps/patch-agents-md.js +0 -153
  87. package/src/steps/token-optimization.js +0 -59
@@ -19,30 +19,28 @@ Process agent, reads work items, creates PRs, handles review feedback. Bookends
19
19
 
20
20
  Work item and issue reading, PR creation, PR comment reading and classification, PR updates, screenshot capture of local running app, branch verification. Does not write application code. Platform knowledge (GitHub, Azure DevOps, etc.) comes entirely from loaded skills.
21
21
 
22
- ## RTK, MANDATORY
22
+ ## Skills and Platform Resolution
23
23
 
24
- Use `rtk` for ALL CLI commands. Never run commands directly.
24
+ Skills are located in `.agents/skills/`. Load required skills explicitly from context and onboarding metadata.
25
25
 
26
- - `rtk gh pr create` NOT `gh pr create`
27
- - `rtk az repos pr create` NOT `az repos pr create`
28
- - `rtk git push` NOT `git push`
26
+ Always load `@ob-global` FIRST before any other skill.
29
27
 
30
- If `rtk` is not available, report it as a blocker. Do not run commands without it.
31
-
32
- ## Skills, Auto-Detection
33
-
34
- Skills are located in `.agents/skills/`. Detect and use relevant skills automatically, the user will never tell you which skill to use.
28
+ Platform skill selection must follow onboarding platform choice from CLI step:
29
+ <!-- OB-PLATFORM-SKILLS-START -->
30
+ - Platform-specific skill instructions are injected during onboarding copy step.
31
+ <!-- OB-PLATFORM-SKILLS-END -->
35
32
 
36
33
  1. If the spawn prompt lists specific skills to load, read those `SKILL.md` files FIRST before any implementation
37
34
  2. Additionally, identify the platform from URLs or context
38
35
 
39
36
  Examples of intent → skill mapping:
40
- - URL contains `dev.azure.com` or `visualstudio.com` look for `ob-userstory-az` or `ob-pullrequest-az`
41
- - URL contains `github.com`look for `ob-userstory-gh` or `ob-pullrequest-gh`
42
- - "create PR" or "ship" → look for a pullrequest skill matching the platform
43
- - "PR has comments" or "review feedback" look for a pullrequest observer skill
37
+ - "read issue/work item"load platform userstory skill
38
+ - "create PR" or "ship" load platform pullrequest skill
39
+ - "PR has comments" or "review feedback" → load platform pullrequest observer skill
40
+ - URL-based platform inference is fallback-only when onboarding metadata is unavailable
44
41
 
45
42
  Rules:
43
+ - Platform selected in onboarding metadata takes precedence over URL inference when both exist
46
44
  - Never interact with a platform without loading the matching skill first
47
45
  - Follow skill instructions exactly, do not partially apply them
48
46
  - If no skill exists for the platform, report it as a blocker rather than improvising
@@ -51,25 +49,36 @@ Rules:
51
49
  ## Two Modes
52
50
 
53
51
  ### Read Mode (pipeline start)
54
- 1. Identify the platform from the URL
55
- 2. Load the matching userstory skill
56
- 3. Fetch and parse the work item
57
- 4. Output structured summary for the lead
52
+ 1. Load `@ob-global` first
53
+ 2. Resolve platform from `.opencode/opencode-onboard.json` (`wizard.platform`) when available; fallback to URL inference only if missing/ambiguous
54
+ 3. Load the matching userstory skill for that resolved platform
55
+ 4. Fetch and parse the work item
56
+ 5. Output structured summary for the lead
58
57
 
59
58
  ### Ship Mode (pipeline end)
60
- 1. Verify all changes are on a feature branch, never `main`
61
- 2. Load the matching pullrequest skill
62
- 3. Capture screenshots of local running app if UI changes exist
63
- 4. Read `.agents/session-log.json` if it exists, parse the JSON array and include a "Session Activity" section in the PR description with agent names, task counts, and skills used
64
- 5. Commit and push the feature branch. If `## Source Roots` lists multiple roots, each root is a separate git repository — create and push the feature branch in EACH repo that has changes; never assume a single repo
65
- 6. Create the PR following the skill instructions (one PR per repo that has changes)
66
- 7. Post PR comment with screenshots and change summary
67
- 8. Report PR URL to the lead
59
+ 1. Load `@ob-global` first
60
+ 2. Verify all changes are on a feature branch, never `main`
61
+ 3. Resolve platform from `.opencode/opencode-onboard.json` (`wizard.platform`) when available; fallback to URL inference only if missing/ambiguous
62
+ 4. Load the matching pullrequest skill for that resolved platform
63
+ 5. Capture screenshots of local running app if UI changes exist
64
+ 6. Read `.agents/session-log.json` if it exists, parse the JSON array and include a "Session Activity" section in the PR description with agent names, task counts, and skills used
65
+ 7. Commit and push the feature branch. If `## Source Roots` lists multiple roots, each root is a separate git repository, create and push the feature branch in EACH repo that has changes; never assume a single repo
66
+ 8. Create the PR following the skill instructions (one PR per repo that has changes)
67
+ 9. Post PR comment with screenshots and change summary
68
+ 10. Report PR URL to the lead
68
69
 
69
70
  ### Feedback Mode (PR review loop)
70
- 1. Load the matching pullrequest observer skill
71
- 2. Read and classify all PR comments
72
- 3. Report classified feedback to the lead, do not implement fixes
71
+ 1. Load `@ob-global` first
72
+ 2. Resolve platform from `.opencode/opencode-onboard.json` (`wizard.platform`) when available; fallback to URL inference only if missing/ambiguous
73
+ 3. Load the matching pullrequest observer skill for that resolved platform
74
+ 4. Read and classify all PR comments
75
+ 5. Report classified feedback to the lead, do not implement fixes
76
+
77
+ ## Worker Model Coordination
78
+
79
+ - Implementation is performed by `basic-engineer` and/or user-defined custom engineers.
80
+ - Multiple engineer workers can run in parallel when task dependencies allow.
81
+ - DevOps Manager orchestrates process, routing, and shipping; it does not implement application code.
73
82
 
74
83
  ## Constraints
75
84
 
@@ -0,0 +1,41 @@
1
+ [
2
+ {
3
+ "ts": "2026-05-04T21:04:09.899Z",
4
+ "agent": "lead",
5
+ "member": null,
6
+ "agentType": null,
7
+ "team": null,
8
+ "action": "started",
9
+ "sessionId": "ses_20b31c36cffeBfsYI2hJ1BNcM5"
10
+ },
11
+ {
12
+ "ts": "2026-05-04T21:04:26.180Z",
13
+ "agent": "lead",
14
+ "member": null,
15
+ "agentType": null,
16
+ "team": null,
17
+ "action": "skill-loaded",
18
+ "skill": "ob-userstory-gh",
19
+ "source": "read-skill-file"
20
+ },
21
+ {
22
+ "ts": "2026-05-04T21:04:47.306Z",
23
+ "agent": "lead",
24
+ "member": null,
25
+ "agentType": null,
26
+ "team": null,
27
+ "action": "completed",
28
+ "filesEdited": 0,
29
+ "skills": [
30
+ "ob-userstory-gh"
31
+ ],
32
+ "usage": {
33
+ "inputTokensReported": null,
34
+ "outputTokensReported": null,
35
+ "totalTokensReported": null,
36
+ "tokenEstimateLow": 3469,
37
+ "tokenEstimateHigh": 6940,
38
+ "method": "heuristic"
39
+ }
40
+ }
41
+ ]
@@ -0,0 +1,21 @@
1
+ Fallback skill, used when no other skill matches. Still loads ob-global for baseline rules.
2
+
3
+ ## When used
4
+
5
+ - No other skill matches the user's request
6
+ - Task is unclear or ambiguous
7
+ - Load ob-global first for baseline rules
8
+
9
+ ## Approach
10
+
11
+ 1. **Understand the ask**, Clarify if ambiguous
12
+ 2. **Check existing context**, Read DESIGN.md, ARCHITECTURE.md first
13
+ 3. **Start small**, MVP, iterate
14
+ 4. **Verify**, Run tests + build before claiming done
15
+ 5. **Report results**, Show what was done, what remains
16
+
17
+ ## Communication
18
+
19
+ - Ask for clarification if unclear
20
+ - Report blockers immediately
21
+ - Show progress when asked
@@ -0,0 +1,32 @@
1
+ Generic guardrails, foundational rules that all agents follow. Users add specialized guardrails skills for specific concerns.
2
+
3
+ ## Git
4
+
5
+ - NEVER commit or push to main
6
+ - NEVER force push
7
+ - NEVER merge PRs (human-only)
8
+ - Feature branches only: `feature/*` or `bugfix/*`
9
+
10
+ ## Secrets
11
+
12
+ - NEVER read or output .env files
13
+ - NEVER log credentials, API keys, tokens
14
+ - NEVER commit secrets to git
15
+
16
+ ## Code
17
+
18
+ - Run tests before marking done
19
+ - Run lint/build before pushing
20
+ - Keep changes small and focused
21
+
22
+ ## Security
23
+
24
+ - Validate all inputs
25
+ - Escape all outputs
26
+ - No hardcoded credentials
27
+
28
+ ## Communication
29
+
30
+ - Ask for clarification if unclear
31
+ - Report blockers immediately
32
+ - Show progress when asked
@@ -0,0 +1,49 @@
1
+ Generic skill, common project-level guidance loaded by all agents. Provides baseline rules; specialized skills add specific concerns.
2
+
3
+ ## When loaded
4
+
5
+ Load this skill first in any session. All other skills add to it, never replace it.
6
+
7
+ ## Context
8
+
9
+ - Load DESIGN.md first for design principles and guidelines.
10
+ - Load ARCHITECTURE.md for system architecture and component interactions.
11
+
12
+ ## Source Roots
13
+
14
+ <!-- OB-SOURCE-ROOTS-START -->
15
+ Source roots are generated during onboarding from the user's source-scope selection.
16
+ Read and analyze code ONLY from those generated roots.
17
+
18
+ If multiple roots are generated, each root is an independent git repository. Branch, commit, push, and PR operations must be handled per repository.
19
+ <!-- OB-SOURCE-ROOTS-END -->
20
+
21
+ ## Git Guardrails
22
+
23
+ - NEVER commit or push to main
24
+ - NEVER force push
25
+ - NEVER merge PRs (human-only)
26
+ - Feature branches only: `feature/*` or `bugfix/*`
27
+
28
+ ## Secrets Guardrails
29
+
30
+ - NEVER read or output .env files
31
+ - NEVER log credentials, API keys, tokens
32
+ - NEVER commit secrets to git
33
+
34
+ ## Code Quality
35
+
36
+ - Run tests before marking done
37
+ - Run lint/build before pushing
38
+ - Keep changes small and focused
39
+ - Ask for clarification if unclear
40
+
41
+ ## Token Optimization Rules
42
+
43
+ <!-- OB-RTK-START -->
44
+ RTK rules are generated here when RTK is selected during onboarding.
45
+ <!-- OB-RTK-END -->
46
+
47
+ <!-- OB-CAVEMAN-START -->
48
+ Caveman rules are generated here when Caveman is selected during onboarding.
49
+ <!-- OB-CAVEMAN-END -->
@@ -8,16 +8,6 @@ metadata:
8
8
  version: "1.0"
9
9
  ---
10
10
 
11
- **RTK - MANDATORY**
12
-
13
- Use `rtk` wrapper for ALL CLI commands:
14
- - `rtk git add` NOT `git add`
15
- - `rtk git commit` NOT `git commit`
16
- - `rtk git push` NOT `git push`
17
- - `rtk az repos pr create` NOT `az repos pr create`
18
- - `rtk az repos pr work-item add` NOT `az repos pr work-item add`
19
- - `rtk az devops invoke` NOT `az devops invoke`
20
-
21
11
  **Browser MCP tools are FORBIDDEN for all Azure DevOps operations.**
22
12
  Browser tools are ONLY permitted for screenshots of the LOCAL running app on `localhost` URLs.
23
13
 
@@ -30,7 +20,7 @@ Triggered when devops-manager is in ship mode after implementation is complete.
30
20
  ### Step 1: Verify feature branch
31
21
 
32
22
  ```bash
33
- rtk git branch --show-current
23
+ git branch --show-current
34
24
  ```
35
25
 
36
26
  Branch must be `feature/{id}-{slug}`. NEVER push to `main`.
@@ -48,15 +38,15 @@ Save to: `openspec/changes/{change-name}/images/{feature}.png`
48
38
  ### Step 3: Commit and push
49
39
 
50
40
  ```bash
51
- rtk git add .
52
- rtk git commit -m "feat(#{id}): {description}"
53
- rtk git push origin feature/{id}-{slug}
41
+ git add .
42
+ git commit -m "feat(#{id}): {description}"
43
+ git push origin feature/{id}-{slug}
54
44
  ```
55
45
 
56
46
  ### Step 4: Create PR
57
47
 
58
48
  ```bash
59
- rtk az repos pr create \
49
+ az repos pr create \
60
50
  --repository {repo} \
61
51
  --source-branch feature/{id}-{slug} \
62
52
  --target-branch main \
@@ -67,7 +57,7 @@ rtk az repos pr create \
67
57
  ### Step 5: Link work item (MANDATORY, run sequentially, not in parallel)
68
58
 
69
59
  ```bash
70
- rtk az repos pr work-item add --id {pr-id} --work-items {workitem-id}
60
+ az repos pr work-item add --id {pr-id} --work-items {workitem-id}
71
61
  ```
72
62
 
73
63
  ### Step 6: Post screenshot comment
@@ -79,7 +69,7 @@ https://dev.azure.com/{org}/{project}/_apis/git/repositories/{repo}/items?path=o
79
69
 
80
70
  Post via:
81
71
  ```bash
82
- rtk az devops invoke \
72
+ az devops invoke \
83
73
  --area git --resource pullRequestThreads \
84
74
  --route-parameters project={project} repositoryId={repo} pullRequestId={pr-id} \
85
75
  --http-method POST --api-version 7.1 --in-file body.json
@@ -107,13 +97,13 @@ Triggered when user says "I've added comments to the PR" or "check PR feedback".
107
97
 
108
98
  If PR link provided, extract ID from URL. Otherwise:
109
99
  ```bash
110
- rtk az repos pr list --repository {repo} --status active --top 1
100
+ az repos pr list --repository {repo} --status active --top 1
111
101
  ```
112
102
 
113
103
  ### Step 2: Read comment threads
114
104
 
115
105
  ```bash
116
- rtk az devops invoke \
106
+ az devops invoke \
117
107
  --area git --resource pullRequestThreads \
118
108
  --route-parameters project={project} repositoryId={repo} pullRequestId={id} \
119
109
  --http-method GET --api-version 7.1
@@ -131,7 +121,7 @@ rtk az devops invoke \
131
121
  ### Step 4: Update openspec (if spec-update)
132
122
 
133
123
  ```bash
134
- rtk git branch --show-current
124
+ git branch --show-current
135
125
  # feature/193208-roles-crud → change: us-193208-roles-crud
136
126
  ```
137
127
 
@@ -140,7 +130,7 @@ Update: `openspec/changes/{change}/proposal.md`, `design.md`, or `tasks.md` as a
140
130
  ### Step 5: Reply to each thread
141
131
 
142
132
  ```bash
143
- rtk az devops invoke \
133
+ az devops invoke \
144
134
  --area git --resource pullRequestThreadComments \
145
135
  --route-parameters project={project} repositoryId={repo} pullRequestId={id} threadId={tid} \
146
136
  --http-method POST --api-version 7.1 --in-file reply.json
@@ -8,16 +8,6 @@ metadata:
8
8
  version: "1.0"
9
9
  ---
10
10
 
11
- **RTK - MANDATORY**
12
-
13
- Use `rtk` wrapper for ALL CLI commands:
14
- - `rtk git add` NOT `git add`
15
- - `rtk git commit` NOT `git commit`
16
- - `rtk git push` NOT `git push`
17
- - `rtk gh pr create` NOT `gh pr create`
18
- - `rtk gh pr comment` NOT `gh pr comment`
19
- - `rtk gh api` NOT `gh api`
20
-
21
11
  **ALL GitHub data MUST come from `gh` CLI. NEVER use webfetch, HTTP requests, or browser MCP tools for GitHub operations, even if gh CLI fails. If `gh` is unavailable, report as a blocker.**
22
12
  Always pass `--repo {owner}/{repo}` explicitly, never rely on git context to resolve the repo.
23
13
 
@@ -30,7 +20,7 @@ Triggered when devops-manager is in ship mode after implementation is complete.
30
20
  ### Step 1: Verify feature branch
31
21
 
32
22
  ```bash
33
- rtk git branch --show-current
23
+ git branch --show-current
34
24
  ```
35
25
 
36
26
  Branch must be `feature/{id}-{slug}`. NEVER push to `main`.
@@ -48,15 +38,15 @@ Save to: `openspec/changes/{change-name}/images/{feature}.png`
48
38
  ### Step 3: Commit and push
49
39
 
50
40
  ```bash
51
- rtk git add .
52
- rtk git commit -m "feat(#{id}): {description}"
53
- rtk git push origin feature/{slug}
41
+ git add .
42
+ git commit -m "feat(#{id}): {description}"
43
+ git push origin feature/{slug}
54
44
  ```
55
45
 
56
46
  ### Step 4: Create PR
57
47
 
58
48
  ```bash
59
- rtk gh pr create \
49
+ gh pr create \
60
50
  --base main \
61
51
  --head feature/{slug} \
62
52
  --title "feat: {title}" \
@@ -67,7 +57,7 @@ rtk gh pr create \
67
57
 
68
58
  Resolve commit SHA (the commit that includes screenshots):
69
59
  ```bash
70
- rtk git rev-parse HEAD
60
+ git rev-parse HEAD
71
61
  ```
72
62
 
73
63
  Build blob URL for each image (preferred, stable in PR discussion):
@@ -77,7 +67,7 @@ https://github.com/{owner}/{repo}/blob/{sha}/openspec/changes/{change}/images/{f
77
67
 
78
68
  Post comment:
79
69
  ```bash
80
- rtk gh pr comment {pr-number} --repo {owner}/{repo} --body $'## Screenshots\n\n![{feature}]({blob-url})'
70
+ gh pr comment {pr-number} --repo {owner}/{repo} --body $'## Screenshots\n\n![{feature}]({blob-url})'
81
71
  ```
82
72
 
83
73
  ---
@@ -90,16 +80,16 @@ Triggered when user says "I've added comments to the PR" or "check PR feedback".
90
80
 
91
81
  If PR link provided, extract number from URL. Otherwise:
92
82
  ```bash
93
- rtk gh pr list --repo {owner}/{repo} --state open --limit 1
83
+ gh pr list --repo {owner}/{repo} --state open --limit 1
94
84
  ```
95
85
 
96
86
  ### Step 2: Read comment threads
97
87
 
98
88
  ```bash
99
- rtk gh pr view {pr-number} --repo {owner}/{repo} --comments
89
+ gh pr view {pr-number} --repo {owner}/{repo} --comments
100
90
  # Or structured output:
101
- rtk gh api repos/{owner}/{repo}/pulls/{pr-number}/comments
102
- rtk gh api repos/{owner}/{repo}/pulls/{pr-number}/reviews
91
+ gh api repos/{owner}/{repo}/pulls/{pr-number}/comments
92
+ gh api repos/{owner}/{repo}/pulls/{pr-number}/reviews
103
93
  ```
104
94
 
105
95
  ### Step 3: Categorize feedback
@@ -114,7 +104,7 @@ rtk gh api repos/{owner}/{repo}/pulls/{pr-number}/reviews
114
104
  ### Step 4: Update openspec (if spec-update)
115
105
 
116
106
  ```bash
117
- rtk git branch --show-current
107
+ git branch --show-current
118
108
  # feature/add-user-auth → change: add-user-auth
119
109
  ```
120
110
 
@@ -124,12 +114,12 @@ Update: `openspec/changes/{change}/proposal.md`, `design.md`, or `tasks.md` as a
124
114
 
125
115
  ```bash
126
116
  # Reply to a review comment
127
- rtk gh api repos/{owner}/{repo}/pulls/{pr-number}/comments/{comment-id}/replies \
117
+ gh api repos/{owner}/{repo}/pulls/{pr-number}/comments/{comment-id}/replies \
128
118
  --method POST \
129
119
  --field body="Acknowledged, applying this change now."
130
120
 
131
121
  # Or post a general PR comment
132
- rtk gh pr comment {pr-number} --body "Updated design.md to reflect feedback."
122
+ gh pr comment {pr-number} --body "Updated design.md to reflect feedback."
133
123
  ```
134
124
 
135
125
  ---
@@ -8,12 +8,6 @@ metadata:
8
8
  version: "3.1"
9
9
  ---
10
10
 
11
- **RTK - MANDATORY**
12
-
13
- Use `rtk` wrapper for ALL CLI commands:
14
- - `rtk az boards work-item show` NOT `az boards work-item show`
15
- - `rtk openspec new change` NOT `openspec new change`
16
-
17
11
  **Browser MCP tools are FORBIDDEN for all Azure DevOps operations.**
18
12
 
19
13
  ---
@@ -40,7 +34,7 @@ Create with scopes: **Work Items (Read & Write)** + **Code (Read & Write)**
40
34
 
41
35
  2. **Fetch Work Item**
42
36
  ```bash
43
- rtk az boards work-item show --id 193208
37
+ az boards work-item show --id 193208
44
38
  ```
45
39
  Do NOT use `--organization` flag (uses default org).
46
40
 
@@ -54,7 +48,7 @@ Create with scopes: **Work Items (Read & Write)** + **Code (Read & Write)**
54
48
 
55
49
  4. **Create OpenSpec Change**
56
50
  ```bash
57
- rtk openspec new change "us-{id}-{slug}"
51
+ openspec new change "us-{id}-{slug}"
58
52
  ```
59
53
 
60
54
  ---
@@ -66,28 +60,28 @@ Use these for ALL DevOps operations, browser MCP is FORBIDDEN.
66
60
  ### Work Items
67
61
  ```bash
68
62
  # Read work item
69
- rtk az boards work-item show --id <id>
63
+ az boards work-item show --id <id>
70
64
 
71
65
  # Update work item state
72
- rtk az boards work-item update --id <id> --state "Active"
66
+ az boards work-item update --id <id> --state "Active"
73
67
  ```
74
68
 
75
69
  ### PR Threads (Comments)
76
70
  ```bash
77
71
  # Read all threads
78
- rtk az devops invoke \
72
+ az devops invoke \
79
73
  --area git --resource pullRequestThreads \
80
74
  --route-parameters project={project} repositoryId=<repo> pullRequestId=<id> \
81
75
  --http-method GET --api-version 7.1
82
76
 
83
77
  # Post new comment thread (requires body.json)
84
- rtk az devops invoke \
78
+ az devops invoke \
85
79
  --area git --resource pullRequestThreads \
86
80
  --route-parameters project={project} repositoryId=<repo> pullRequestId=<id> \
87
81
  --http-method POST --api-version 7.1 --in-file body.json
88
82
 
89
83
  # Reply to existing thread
90
- rtk az devops invoke \
84
+ az devops invoke \
91
85
  --area git --resource pullRequestThreadComments \
92
86
  --route-parameters project={project} repositoryId=<repo> pullRequestId=<id> threadId=<tid> \
93
87
  --http-method POST --api-version 7.1 --in-file reply.json
@@ -165,7 +159,7 @@ After outputting the above, the lead MUST run `/opsx-propose` to generate the pr
165
159
  ## Guardrails
166
160
 
167
161
  - ✅ Parse Azure DevOps URL and create OpenSpec change
168
- - ✅ Use `rtk` for all Azure CLI operations
162
+ - ✅ Use `az` CLI for all Azure DevOps operations
169
163
  - ✅ Always run `/opsx-propose` after parsing, never skip to implementation
170
164
  - ✅ Always stop and confirm with user after propose, before running `/opsx-apply`
171
165
  - ❌ Browser MCP tools for Azure DevOps operations, FORBIDDEN
@@ -8,14 +8,6 @@ metadata:
8
8
  version: "1.1"
9
9
  ---
10
10
 
11
- **RTK - MANDATORY**
12
-
13
- Use `rtk` wrapper for ALL CLI commands:
14
- - `rtk gh issue view` NOT `gh issue view`
15
- - `rtk gh issue list` NOT `gh issue list`
16
- - `rtk gh issue edit` NOT `gh issue edit`
17
- - `rtk openspec new change` NOT `openspec new change`
18
-
19
11
  **ALL GitHub data MUST come from `gh` CLI. NEVER use webfetch, HTTP requests, or browser MCP tools to fetch GitHub URLs, even if gh CLI fails. If `gh` is unavailable, report it as a blocker.**
20
12
 
21
13
  ---
@@ -41,7 +33,7 @@ gh auth status
41
33
 
42
34
  2. **Fetch Issue**, always pass `--repo` explicitly, never rely on git context:
43
35
  ```bash
44
- rtk gh issue view 42 --repo {owner}/{repo} --json number,title,body,labels,milestone,state
36
+ gh issue view 42 --repo {owner}/{repo} --json number,title,body,labels,milestone,state
45
37
  ```
46
38
  If this returns an auth error or 404, report as a blocker, do NOT fall back to webfetch or web search.
47
39
 
@@ -55,7 +47,7 @@ gh auth status
55
47
 
56
48
  4. **Create OpenSpec Change**
57
49
  ```bash
58
- rtk openspec new change "gh-{number}-{slug}"
50
+ openspec new change "gh-{number}-{slug}"
59
51
  ```
60
52
 
61
53
  ---
@@ -67,13 +59,13 @@ Use these for ALL GitHub operations, browser MCP and webfetch are FORBIDDEN. Alw
67
59
  ### Issues
68
60
  ```bash
69
61
  # Read issue
70
- rtk gh issue view <number> --repo {owner}/{repo}
62
+ gh issue view <number> --repo {owner}/{repo}
71
63
 
72
64
  # List open issues
73
- rtk gh issue list --repo {owner}/{repo} --state open --limit 10
65
+ gh issue list --repo {owner}/{repo} --state open --limit 10
74
66
 
75
67
  # Update issue
76
- rtk gh issue edit <number> --repo {owner}/{repo} --add-label "in-progress"
68
+ gh issue edit <number> --repo {owner}/{repo} --add-label "in-progress"
77
69
  ```
78
70
 
79
71
  ---
@@ -129,7 +121,7 @@ After outputting the above, the lead MUST run `/opsx-propose` to generate the pr
129
121
  ## Guardrails
130
122
 
131
123
  - ✅ Parse GitHub Issue URL and create OpenSpec change
132
- - ✅ Use `rtk gh` for all GitHub CLI operations
124
+ - ✅ Use `gh` CLI for all GitHub operations
133
125
  - ✅ Always run `/opsx-propose` after parsing, never skip to implementation
134
126
  - ✅ Always stop and confirm with user after propose, before running `/opsx-apply`
135
127
  - ❌ `webfetch` or HTTP requests to GitHub URLs, FORBIDDEN, use `gh` CLI only
@@ -0,0 +1,8 @@
1
+ ---
2
+ description: Initialize the project — runs the bootstrap sequence defined in AGENTS.md if not yet initialized.
3
+ ---
4
+
5
+ Check if `AGENTS.md` is in bootstrap mode (contains `<!-- AGENTS-TEMPLATE-START -->`).
6
+
7
+ - If yes: run the full initialization sequence defined in `AGENTS.md` now.
8
+ - If no: tell the user the project is already initialized.
@@ -0,0 +1,17 @@
1
+ ---
2
+ description: Quick direct implementation — no OpenSpec, no ensemble, no PRs. Just do it.
3
+ ---
4
+
5
+ Implement the task described after `/main` directly and immediately.
6
+
7
+ **Rules:**
8
+ - No OpenSpec artifacts (no proposal, no specs, no tasks.md)
9
+ - No ensemble team (no team_create, no team_spawn)
10
+ - No branches, no PRs
11
+ - Work directly in the current branch
12
+ - Keep changes minimal and focused on exactly what was asked
13
+ - Use Read/Glob/Grep to locate relevant files before editing
14
+ - After editing, run `pnpm run typecheck` to catch type errors; fix any that are caused by your changes
15
+ - Do NOT run lint or tests unless the user asks
16
+
17
+ **Input**: Everything after `/main` is the task. Execute it now.