@event4u/agent-config 1.28.0 → 1.31.0

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 (52) hide show
  1. package/.agent-src/commands/agents/audit.md +101 -197
  2. package/.agent-src/commands/{copilot-agents → agents}/init.md +18 -10
  3. package/.agent-src/commands/agents/optimize.md +181 -0
  4. package/.agent-src/commands/agents.md +19 -12
  5. package/.agent-src/commands/optimize/agents-dir.md +111 -0
  6. package/.agent-src/commands/optimize.md +10 -8
  7. package/.agent-src/contexts/communication/rules-auto/guidelines-mechanics.md +6 -0
  8. package/.agent-src/contexts/communication/rules-auto/slash-command-routing-policy-mechanics.md +2 -3
  9. package/.agent-src/contexts/contracts/agents-md-anatomy.md +132 -0
  10. package/.agent-src/skills/agents-md-thin-root/SKILL.md +8 -1
  11. package/.agent-src/skills/async-python-patterns/SKILL.md +147 -0
  12. package/.agent-src/skills/command-writing/SKILL.md +49 -0
  13. package/.agent-src/skills/copilot-agents-optimization/SKILL.md +3 -3
  14. package/.agent-src/skills/defense-in-depth/SKILL.md +152 -0
  15. package/.agent-src/skills/error-handling-patterns/SKILL.md +134 -0
  16. package/.agent-src/skills/mcp-builder/SKILL.md +108 -0
  17. package/.agent-src/skills/prompt-engineering-patterns/SKILL.md +145 -0
  18. package/.agent-src/skills/repomix-packer/SKILL.md +135 -0
  19. package/.agent-src/skills/roadmap-writing/SKILL.md +9 -0
  20. package/.agent-src/skills/rule-writing/SKILL.md +21 -0
  21. package/.agent-src/skills/secrets-management/SKILL.md +142 -0
  22. package/.agent-src/skills/skill-writing/SKILL.md +19 -0
  23. package/.agent-src/skills/testing-anti-patterns/SKILL.md +152 -0
  24. package/.agent-src/templates/AGENTS.md +9 -10
  25. package/.claude-plugin/marketplace.json +12 -7
  26. package/AGENTS.md +1 -2
  27. package/CHANGELOG.md +113 -0
  28. package/CONTRIBUTING.md +90 -0
  29. package/README.md +3 -3
  30. package/docs/architecture.md +3 -3
  31. package/docs/catalog.md +19 -13
  32. package/docs/contracts/command-clusters.md +20 -3
  33. package/docs/contracts/file-ownership-matrix.json +511 -48
  34. package/docs/contracts/package-self-orientation.md +1 -1
  35. package/docs/getting-started.md +1 -1
  36. package/docs/guidelines/code-clarity.md +95 -0
  37. package/docs/guidelines/php/general.md +8 -0
  38. package/docs/guidelines/php/php-coding-patterns.md +1 -0
  39. package/docs/skills-catalog.md +27 -3
  40. package/llms.txt +26 -2
  41. package/package.json +1 -1
  42. package/scripts/chat_history.py +166 -36
  43. package/scripts/check_command_count_messaging.py +12 -3
  44. package/scripts/check_portability.py +1 -0
  45. package/scripts/lint_agents_md.py +33 -0
  46. package/scripts/release.py +77 -2
  47. package/scripts/skill_linter.py +10 -3
  48. package/.agent-src/commands/agents/cleanup.md +0 -194
  49. package/.agent-src/commands/agents/prepare.md +0 -141
  50. package/.agent-src/commands/copilot-agents/optimize.md +0 -255
  51. package/.agent-src/commands/copilot-agents.md +0 -44
  52. package/.agent-src/commands/optimize/agents.md +0 -144
@@ -1,194 +0,0 @@
1
- ---
2
- name: agents:cleanup
3
- cluster: agents
4
- sub: cleanup
5
- skills: [agent-docs-writing]
6
- description: Execute cleanup actions from an agents-audit — move, merge, delete, and update agent docs
7
- disable-model-invocation: true
8
- suggestion:
9
- eligible: false
10
- rationale: "Consumes prior audit output; only meaningful right after /agents-audit."
11
- ---
12
-
13
- # /agents cleanup
14
- ## Instructions
15
-
16
- ### 1. Check for audit roadmap
17
-
18
- Check the audit-roadmap path created by `/agents audit`:
19
-
20
- ```
21
- agents/roadmaps/agents-cleanup.md
22
- ```
23
-
24
- - If it exists → load it and show the phases.
25
- - If not → ask:
26
-
27
- ```
28
- ⚠️ No audit roadmap found.
29
-
30
- 1. 🔍 Run /agents-audit first
31
- 2. 💬 I know what to do — start directly
32
- ```
33
-
34
- **Recommendation: 1 — Run /agents-audit first** — without an audit roadmap, the cleanup is shooting in the dark. Caveat: pick 2 only if you already know exactly which docs to touch.
35
-
36
- If option 2, ask what to clean up.
37
-
38
- ### 2. Show action plan
39
-
40
- If a roadmap exists, display the phases:
41
-
42
- ```
43
- ═══════════════════════════════════════════════
44
- 🧹 AGENTS CLEANUP
45
- ═══════════════════════════════════════════════
46
-
47
- Phase 1: Critical fixes ({count} actions)
48
- - [ ] {action}
49
- - [ ] {action}
50
-
51
- Phase 2: Structural cleanup ({count} actions)
52
- - [ ] {action}
53
- - [ ] {action}
54
-
55
- Phase 3: Fill gaps ({count} actions)
56
- - [ ] {action}
57
-
58
- Phase 4: Cleanup ({count} actions)
59
- - [ ] {action}
60
-
61
- ═══════════════════════════════════════════════
62
-
63
- Which phase to work on?
64
-
65
- 1. Start Phase 1 (recommended — top to bottom)
66
- 2. Choose a specific phase
67
- 3. Choose a specific action
68
- ```
69
-
70
- ### 3. Execute actions
71
-
72
- For each action, follow the appropriate workflow:
73
-
74
- **Move file:**
75
- ```
76
- 📁 Move: {source} → {target}
77
- Reason: {why}
78
-
79
- Confirm? (y/n)
80
- ```
81
- - Move the file.
82
- - Update all references in other docs that link to the old path.
83
- - Check `.augment/skills/` and `.augment/commands/` for references.
84
-
85
- **Merge files:**
86
- ```
87
- 🔗 Merge:
88
- {file1} + {file2} → {target}
89
- Reason: {why — what overlaps}
90
-
91
- Confirm? (y/n)
92
- ```
93
- - Read both files.
94
- - Show the proposed merged content.
95
- - Create the merged file, delete the originals.
96
- - Update references.
97
-
98
- **Delete file:**
99
- ```
100
- 🗑️ Delete: {file}
101
- Reason: {why — what's obsolete}
102
-
103
- Content (preview):
104
- {first 5 lines}
105
-
106
- Confirm? (y/n)
107
- ```
108
- - Delete the file.
109
- - Check for and remove references in other docs.
110
-
111
- **Update file:**
112
- ```
113
- ✏️ Update: {file}
114
- Reason: {what's outdated}
115
-
116
- Changes:
117
- - {reference to deleted class} → remove
118
- - {outdated section} → update
119
- - {missing info} → add
120
-
121
- Confirm? (y/n)
122
- ```
123
- - Read the file.
124
- - Make the changes.
125
- - Show a summary of what changed.
126
-
127
- **Create context:**
128
- ```
129
- 📄 Create context: {area}
130
- Reason: {why it's needed}
131
-
132
- > 1. Yes — start /context-create
133
- > 2. Skip
134
- ```
135
- - Transition to `/context-create` with the area pre-selected.
136
-
137
- ### 4. Update roadmap progress
138
-
139
- After each action:
140
- - Mark the step as `[x]` in the roadmap file.
141
- - Show progress:
142
-
143
- ```
144
- ✅ Action complete: {description}
145
-
146
- Progress Phase {n}: [{completed}/{total}]
147
- ██████████░░░░░░ 60%
148
- ```
149
-
150
- Per `verbosity.routine_confirmations` (default `false`):
151
-
152
- - `false` → continue to the next action silently. User can interrupt
153
- any time; "continue" is dominant once cleanup is in flight.
154
- - `true` → ask:
155
- ```
156
- > 1. Continue with next action
157
- > 2. Stop here
158
- ```
159
-
160
- ### 5. Summary (verbosity-gated)
161
-
162
- After completing a phase or all actions, read
163
- `verbosity.post_action_reports` from `.agent-settings.yml` (default
164
- `minimal`).
165
-
166
- - `off` → emit nothing on success; surface errors only.
167
- - `minimal` (default) → one line:
168
- `→ Cleanup: {moved} moved · {deleted} deleted · {updated} updated · {remaining} remaining`.
169
- - `full` → multi-line block:
170
-
171
- ```
172
- ═══════════════════════════════════════════════
173
- ✅ CLEANUP SUMMARY
174
- ═══════════════════════════════════════════════
175
-
176
- 📁 Moved: {count} files
177
- 🔗 Merged: {count} files
178
- 🗑️ Deleted: {count} files
179
- ✏️ Updated: {count} files
180
- 📄 Created: {count} contexts
181
-
182
- Remaining: {count} actions in {phases} phases
183
-
184
- ═══════════════════════════════════════════════
185
- ```
186
-
187
- ### Rules
188
-
189
- - **Do NOT commit or push.**
190
- - **Always confirm before each destructive action** (delete, merge, move).
191
- - **Always update references** when moving or renaming files.
192
- - **Update the roadmap** after each completed action.
193
- - **Show file content** before deleting — the user should see what's being removed.
194
- - **Check `.augment/` references too** — skills and commands may link to agents docs.
@@ -1,141 +0,0 @@
1
- ---
2
- name: agents:prepare
3
- cluster: agents
4
- sub: prepare
5
- skills: [agent-docs-writing]
6
- description: Scaffold the agents/ directory structure with all required subdirectories and .gitkeep files
7
- disable-model-invocation: true
8
- suggestion:
9
- eligible: false
10
- rationale: "One-shot project scaffolding; only run during initial setup."
11
- ---
12
-
13
- # /agents prepare
14
- ## Instructions
15
-
16
- ### 1. Check project root
17
-
18
- Verify you're in the project root (look for `composer.json`, `artisan`, or `package.json`).
19
-
20
- ### 2. Create directory structure
21
-
22
- Create the following directories if they don't exist, with a `.gitkeep` in each **empty** directory:
23
-
24
- ```
25
- agents/
26
- ├── roadmaps/
27
- │ └── .gitkeep
28
- ├── features/
29
- │ └── .gitkeep
30
- └── contexts/
31
- └── .gitkeep
32
- ```
33
-
34
- Also create the guidelines directory in `.augment/` if it doesn't exist:
35
-
36
- ```
37
- .augment/guidelines/
38
- └── php/
39
- └── .gitkeep
40
- ```
41
-
42
- **Rules:**
43
- - Only add `.gitkeep` to directories that have **no other files** in them.
44
- - Do NOT overwrite existing files.
45
- - Do NOT create directories that already exist with content.
46
-
47
- ### 3. Check for module support
48
-
49
- Check if the project has a module system (`app/Modules/` directory):
50
-
51
- - If `app/Modules/` exists → list all modules.
52
- - For each module, create the agent directories if they don't exist:
53
-
54
- ```
55
- app/Modules/{Module}/agents/
56
- ├── roadmaps/
57
- │ └── .gitkeep
58
- ├── features/
59
- │ └── .gitkeep
60
- ├── contexts/
61
- │ └── .gitkeep
62
- ```
63
-
64
- ### 4. Verify templates exist
65
-
66
- Check that `.augment/templates/` contains the required templates:
67
-
68
- ```
69
- .augment/templates/
70
- ├── features.md # Feature plan template
71
- ├── roadmaps.md # Roadmap template
72
- └── contexts.md # Context document template
73
- ```
74
-
75
- If any template is missing, warn:
76
-
77
- ```
78
- ⚠️ Missing templates in .augment/templates/:
79
- - {missing-file}
80
-
81
- These templates are required by the Feature/Roadmap commands.
82
- ```
83
-
84
- ### 5. Clean up old templates
85
-
86
- Check for **old template files** in the agents directories and offer to remove them:
87
-
88
- ```
89
- agents/features/template.md
90
- agents/roadmaps/template.md
91
- app/Modules/*/agents/roadmaps/template.md
92
- app/Modules/*/agents/features/template.md
93
- ```
94
-
95
- If any are found:
96
-
97
- ```
98
- ℹ️ Old template files found (now in .augment/templates/):
99
-
100
- - agents/features/template.md
101
- - agents/roadmaps/template.md
102
-
103
- Delete these? (y/n)
104
- ```
105
-
106
- If yes → delete them.
107
-
108
- ### 6. Show summary
109
-
110
- ```
111
- ═══════════════════════════════════════════════
112
- ✅ AGENTS-VERZEICHNIS VORBEREITET
113
- ═══════════════════════════════════════════════
114
-
115
- 📁 Projekt-Root:
116
- agents/roadmaps/ {✅ existiert | 🆕 erstellt}
117
- agents/features/ {✅ existiert | 🆕 erstellt}
118
- .augment/guidelines/ {✅ existiert | 🆕 erstellt}
119
-
120
- 📁 Templates:
121
- .augment/templates/features.md {✅ | ⚠️ fehlt}
122
- .augment/templates/roadmaps.md {✅ | ⚠️ fehlt}
123
-
124
- {If modules exist:}
125
- 📁 Module:
126
- {Module}/agents/roadmaps/ {✅ | 🆕}
127
- {Module}/agents/features/ {✅ | 🆕}
128
- ...
129
-
130
- {If old templates were cleaned up:}
131
- 🗑️ Old templates removed: {count}
132
-
133
- ═══════════════════════════════════════════════
134
- ```
135
-
136
- ### Rules
137
-
138
- - **Do NOT commit or push.**
139
- - **Do NOT overwrite existing files.**
140
- - **Do NOT create `.gitkeep` in directories that already have files.**
141
- - **Always ask before deleting** old template files.
@@ -1,255 +0,0 @@
1
- ---
2
- name: copilot-agents:optimize
3
- cluster: copilot-agents
4
- sub: optimize
5
- description: Analyzes and refactors AGENTS.md and copilot-instructions.md — removes duplications, enforces line budgets, and ensures both files are optimized for their audience.
6
- skills: [copilot-agents-optimization, copilot-config, agent-docs-writing]
7
- disable-model-invocation: true
8
- suggestion:
9
- eligible: false
10
- rationale: "Maintenance refactor; only when the maintainer chooses to run it."
11
- ---
12
-
13
- # /copilot-agents optimize
14
- Analyzes and refactors `AGENTS.md` and `.github/copilot-instructions.md` against the `.augment/` ecosystem.
15
-
16
- ## Steps
17
-
18
- ### 1. Measure current state
19
-
20
- ```bash
21
- wc -l AGENTS.md .github/copilot-instructions.md
22
- ```
23
-
24
- Report line counts with budget status:
25
-
26
- | File | Lines | Budget | Status |
27
- |---|---|---|---|
28
- | `AGENTS.md` | {n} | ≤ 500 ideal, max 1000 | 🟢/🟡/🔴 |
29
- | `copilot-instructions.md` | {n} | ≤ 500 ideal, max 1000 | 🟢/🟡/🔴 |
30
-
31
- ### 2. Scan for duplications
32
-
33
- Read both files and compare against `.augment/` content:
34
-
35
- **Check against rules:**
36
- ```bash
37
- ls .augment/rules/*.md
38
- ```
39
- For each rule, check if AGENTS.md or copilot-instructions.md duplicates its content.
40
-
41
- **Check against guidelines:**
42
- ```bash
43
- find .augment/guidelines/ -name '*.md'
44
- ```
45
- For each guideline, check if either file repeats the same conventions.
46
-
47
- **Check against skills:**
48
- ```bash
49
- ls .augment/skills/*/SKILL.md
50
- ```
51
- For each skill, check if either file contains domain knowledge that belongs in the skill.
52
-
53
- **Check between the two files:**
54
- Compare sections — anything duplicated between AGENTS.md and copilot-instructions.md
55
- that isn't required for Copilot's self-containment.
56
-
57
- ### 2.5. Scan for legacy identifiers and stack mismatches
58
-
59
- Before deduplicating, verify the content still **applies to the current
60
- project**. Files drift in three ways:
61
-
62
- - **Legacy leakage** — identifiers from a former, forked, or adjacent
63
- project (renamed repo, split monorepo, content copied from a sibling).
64
- - **Stack mismatch** — the file claims tech the project no longer uses
65
- (e.g. "Laravel 11 + MariaDB" in a repo that is now a pure Python
66
- library).
67
- - **Dead commands** — Make targets, Artisan commands, docker services
68
- that no longer exist.
69
-
70
- **A. Legacy-identifier scan**
71
-
72
- Use the package's portability blocklist as the baseline:
73
-
74
- ```bash
75
- python3 -c "import sys; sys.path.insert(0, 'scripts'); \
76
- from check_portability import FORBIDDEN_IDENTIFIERS; \
77
- [print(i) for i in FORBIDDEN_IDENTIFIERS]" 2>/dev/null
78
- ```
79
-
80
- Plus any identifier from `agents/` module docs that does NOT match the
81
- current project name (see step 2.5.B to determine the current project).
82
-
83
- For each identifier, grep both files and report **every** hit:
84
-
85
- ```bash
86
- for ident in "${forbidden_identifiers[@]}"; do
87
- grep -n -iE "\b${ident}\b" AGENTS.md .github/copilot-instructions.md
88
- done
89
- ```
90
-
91
- Every hit is a 🔴 **blocker** — these must be fixed or removed before any
92
- other optimization. Leaking another project's name into the consumer's
93
- own docs is the failure mode that made this step exist.
94
-
95
- **B. Stack-coherence scan**
96
-
97
- Auto-detect the real stack (same logic as `/copilot-agents-init` step 2):
98
-
99
- | Source file | Signal |
100
- |---|---|
101
- | `composer.json` | PHP, Laravel/Symfony, package name, PHP version |
102
- | `package.json` | Node, Next.js/React/Vue, engines |
103
- | `pyproject.toml` / `requirements.txt` | Python + framework |
104
- | `Gemfile` | Ruby on Rails |
105
- | `go.mod`, `Cargo.toml`, `pom.xml`, `build.gradle` | Language |
106
- | `docker-compose.yml` | Service names actually used |
107
- | `Makefile` / `Taskfile.yml` / `package.json` scripts | Dev commands |
108
-
109
- Compare each claim in AGENTS.md / copilot-instructions.md against the
110
- detected stack. Flag mismatches:
111
-
112
- | Claim in doc | Reality | Severity |
113
- |---|---|---|
114
- | "Laravel 11" | no `laravel/framework` in composer.json | 🔴 |
115
- | "MariaDB" | no DB driver or docker service | 🟡 |
116
- | service name `db` | `docker-compose.yml` has `mariadb` only | 🟡 |
117
- | `make start` | `Makefile` absent OR target missing | 🔴 |
118
- | "PHP 8.2" | `composer.json` requires `^8.1` | 🟡 |
119
-
120
- **C. Dead-command scan**
121
-
122
- Extract every invoked command from both files:
123
-
124
- ```bash
125
- grep -oE '(make|task|composer|npm|pnpm|yarn|php artisan|python|./)[a-zA-Z0-9 _:./-]+' \
126
- AGENTS.md .github/copilot-instructions.md | sort -u
127
- ```
128
-
129
- For each hit, verify it exists:
130
-
131
- - `make X` → `grep -q "^${X}:" Makefile`
132
- - `task X` → `task --list-all` contains X
133
- - `composer X` → `composer.json` `scripts` contains X
134
- - `php artisan X` → `php artisan list --no-ansi` contains X (skip if no
135
- container — just note "unverified")
136
- - `npm/pnpm/yarn X` → `package.json` `scripts` contains X
137
-
138
- Commands that no longer resolve are 🟡 stale — propose a replacement or
139
- removal.
140
-
141
- ### 3. Present findings
142
-
143
- Show a table of issues found, **grouped by severity**. Blockers from
144
- step 2.5 come first:
145
-
146
- | # | File | Section | Issue | Severity | Action |
147
- |---|---|---|---|---|---|
148
- | 1 | AGENTS.md | "Quick Setup" | Mentions a forbidden identifier from the blocklist | 🔴 | Replace or remove |
149
- | 2 | copilot | "Tech stack" | Claims Laravel 11, project is Python | 🔴 | Full rewrite |
150
- | 3 | AGENTS.md | "Commands" | `make start` target not in Makefile | 🟡 | Update or remove |
151
- | 4 | AGENTS.md | "Coding Standards" | Duplicates `.augment/rules/php-coding.md` | 🟢 | Remove, add reference |
152
- | 5 | copilot | "SOLID Principles" | Duplicates `.augment/rules/architecture.md` | 🟢 | Keep (Copilot needs it) |
153
- | 6 | copilot | "Trailing commas" | Auto-enforced by ECS | 🟢 | Remove |
154
-
155
- Classify each issue:
156
-
157
- | Action | Meaning |
158
- |---|---|
159
- | **Replace** | Legacy identifier → swap for the correct current name |
160
- | **Rewrite** | Entire section no longer matches reality — rewrite from stack detection |
161
- | **Remove** | Content exists in `.augment/` and the file can reference it, or command is dead |
162
- | **Keep** | Content is needed self-contained (copilot-instructions.md) |
163
- | **Compress** | Content is valid but too verbose — shorten |
164
- | **Extract** | Move to a dedicated file in `agents/` and link |
165
- | **Update** | Content is outdated or references have changed |
166
-
167
- If the 🔴 blockers exceed a reasonable rewrite effort (e.g. the entire
168
- "Tech stack" and "Commands" sections are wrong), offer
169
- `/copilot-agents-init` as an alternative instead of patching in place:
170
-
171
- > ⚠️ Detected severe drift: {N} blockers, including a completely wrong
172
- > tech stack.
173
- >
174
- > 1. Continue optimizing (patch in place — may require large rewrites)
175
- > 2. Back up current files and run `/copilot-agents-init` for a clean scaffold
176
- > 3. Abort
177
-
178
- ### 4. Ask for confirmation
179
-
180
- > Found {n} optimizations:
181
- > - {x} duplicates to remove (AGENTS.md)
182
- > - {y} sections to compress
183
- > - {z} sections to extract to `agents/`
184
- >
185
- > 1. Apply all changes
186
- > 2. Confirm each change individually
187
- > 3. Only optimize AGENTS.md
188
- > 4. Only optimize copilot-instructions.md
189
-
190
- ### 5. Apply changes
191
-
192
- For each approved change:
193
-
194
- 1. **Remove duplicates** — Delete the section, add a reference line if needed
195
- 2. **Compress** — Rewrite verbose sections as concise tables/bullets
196
- 3. **Extract** — Create file in `agents/`, move content, add link in original
197
- 4. **Update** — Fix outdated references, paths, or descriptions
198
-
199
- After each file is modified, verify:
200
- - Line count is within budget
201
- - No broken references
202
- - Self-containment preserved for copilot-instructions.md
203
-
204
- ### 6. Verify cross-references
205
-
206
- Check that all references in both files are valid:
207
-
208
- ```bash
209
- # Find all markdown links in both files
210
- grep -oE '\[.*\]\(.*\)' AGENTS.md .github/copilot-instructions.md
211
- ```
212
-
213
- For each link, verify the target file exists.
214
-
215
- ### 7. Report results
216
-
217
- > ✅ Optimization complete:
218
- >
219
- > | File | Before | After | Δ |
220
- > |---|---|---|---|
221
- > | `AGENTS.md` | {old} lines | {new} lines | -{diff} |
222
- > | `copilot-instructions.md` | {old} lines | {new} lines | -{diff} |
223
- >
224
- > **Removed duplicates:** {n}
225
- > **Compressed sections:** {n}
226
- > **Extracted content:** {n} (to `agents/`)
227
-
228
- ### 8. Suggest follow-ups
229
-
230
- If issues were found that need manual attention:
231
-
232
- > ⚠️ Manual review recommended:
233
- > - {issue description}
234
-
235
- If `.augment/` content is missing that both files reference:
236
-
237
- > 💡 Missing `.augment/` content:
238
- > - {missing skill/rule/guideline}
239
-
240
- ## Rules
241
-
242
- - **Step 2.5 is mandatory.** Never skip the portability + stack scan —
243
- that is the step that catches the "legacy identifier from another
244
- project" failure mode. Duplication cleanup without this scan means the
245
- command approves stale, wrong content.
246
- - **🔴 blockers are fixed first.** Don't deduplicate a section that is
247
- about to be rewritten anyway.
248
- - **NEVER strip strong language** — "Do NOT", "NEVER", "MUST" are load-bearing words.
249
- See the Iron Laws in `/optimize-agents` — they apply here too.
250
- - **NEVER remove examples** from `copilot-instructions.md` — Copilot Code Review cannot
251
- read other files, so examples must be self-contained.
252
- - **`copilot-instructions.md` MUST remain self-contained** — it cannot reference `.augment/`
253
- files because Copilot Code Review has no access to them. Only Copilot Chat can read other files.
254
- - **`AGENTS.md` MAY reference `.augment/`** — it is read by tools that can follow links.
255
- - **Ask before removing** — present findings first, apply after approval.
@@ -1,44 +0,0 @@
1
- ---
2
- name: copilot-agents
3
- description: Copilot agents-doc orchestrator — routes to init, optimize
4
- cluster: copilot-agents
5
- disable-model-invocation: true
6
- suggestion:
7
- eligible: true
8
- trigger_description: "create AGENTS.md, optimize copilot-instructions.md, scaffold copilot agent docs"
9
- trigger_context: "user wants to author or tune AGENTS.md / copilot-instructions.md"
10
- ---
11
-
12
- # /copilot-agents
13
-
14
- Top-level orchestrator for the `/copilot-agents` family. Replaces 2
15
- standalone commands with a single entry point + sub-command dispatch.
16
-
17
- ## Sub-commands
18
-
19
- | Sub-command | Routes to | Purpose |
20
- |---|---|---|
21
- | `/copilot-agents init` | `commands/copilot-agents/init.md` | Create AGENTS.md and `.github/copilot-instructions.md` from scratch |
22
- | `/copilot-agents optimize` | `commands/copilot-agents/optimize.md` | Refactor existing AGENTS.md and copilot-instructions.md for line budgets |
23
-
24
- Sub-command names match the locked contract in
25
- [`docs/contracts/command-clusters.md`](../docs/contracts/command-clusters.md).
26
-
27
- ## Dispatch
28
-
29
- 1. Parse the user's argument: `/copilot-agents <sub-command> [args]`.
30
- 2. Look up the sub-command in the table above.
31
- 3. Load the body of the routed file and follow its `## Instructions` section
32
- verbatim with the remaining args.
33
- 4. If the sub-command is unknown or missing, print the table above and ask:
34
-
35
- > 1. init — scaffold AGENTS.md + copilot-instructions.md from scratch
36
- > 2. optimize — refactor existing files for budget and audience
37
-
38
- ## Rules
39
-
40
- - **Do NOT commit, push, or open a PR** unless the sub-command explicitly
41
- authorizes it.
42
- - **Do NOT chain sub-commands.** One `/copilot-agents <sub>` per turn.
43
- - If the user invokes `/copilot-agents` with no argument, **show the
44
- menu** — do not guess which sub-command they meant.