@event4u/agent-config 1.20.0 → 1.22.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.
- package/.agent-src/commands/agents.md +1 -1
- package/.agent-src/commands/bug-fix.md +2 -1
- package/.agent-src/commands/bug-investigate.md +3 -2
- package/.agent-src/commands/challenge-me/vision.md +348 -0
- package/.agent-src/commands/challenge-me/with-docs.md +333 -0
- package/.agent-src/commands/challenge-me.md +61 -0
- package/.agent-src/commands/chat-history/import.md +60 -64
- package/.agent-src/commands/compress.md +12 -0
- package/.agent-src/commands/context/create.md +2 -2
- package/.agent-src/commands/context.md +1 -1
- package/.agent-src/commands/copilot-agents.md +1 -1
- package/.agent-src/commands/council/default.md +69 -10
- package/.agent-src/commands/council.md +1 -1
- package/.agent-src/commands/create-pr.md +7 -3
- package/.agent-src/commands/e2e-heal.md +1 -1
- package/.agent-src/commands/e2e-plan.md +1 -1
- package/.agent-src/commands/feature/dev.md +3 -3
- package/.agent-src/commands/feature.md +1 -1
- package/.agent-src/commands/fix/seeder.md +2 -2
- package/.agent-src/commands/fix.md +1 -1
- package/.agent-src/commands/grill-me.md +38 -0
- package/.agent-src/commands/jira-ticket.md +1 -1
- package/.agent-src/commands/judge/steps.md +1 -1
- package/.agent-src/commands/judge.md +2 -2
- package/.agent-src/commands/memory.md +1 -1
- package/.agent-src/commands/mode.md +5 -5
- package/.agent-src/commands/module.md +1 -1
- package/.agent-src/commands/onboard.md +4 -4
- package/.agent-src/commands/optimize/augmentignore.md +1 -1
- package/.agent-src/commands/optimize-prompt.md +61 -0
- package/.agent-src/commands/optimize.md +1 -1
- package/.agent-src/commands/override.md +1 -1
- package/.agent-src/commands/review-changes.md +1 -1
- package/.agent-src/commands/review-routing.md +1 -1
- package/.agent-src/commands/roadmap/ai-council.md +183 -0
- package/.agent-src/commands/roadmap/create.md +6 -1
- package/.agent-src/commands/roadmap/process-full.md +58 -0
- package/.agent-src/commands/roadmap/process-phase.md +69 -0
- package/.agent-src/commands/roadmap/process-step.md +57 -0
- package/.agent-src/commands/roadmap.md +45 -17
- package/.agent-src/commands/set-cost-profile.md +3 -3
- package/.agent-src/commands/sync-agent-settings.md +2 -2
- package/.agent-src/commands/tests/create.md +2 -2
- package/.agent-src/commands/tests.md +1 -1
- package/.agent-src/commands/threat-model.md +5 -4
- package/.agent-src/contexts/augment-infrastructure.md +1 -1
- package/.agent-src/contexts/authority/commit-mechanics.md +14 -1
- package/.agent-src/contexts/authority/destructive-mechanics.md +14 -1
- package/.agent-src/contexts/authority/scope-mechanics.md +5 -0
- package/.agent-src/contexts/communication/rules-auto/guidelines-mechanics.md +76 -0
- package/.agent-src/contexts/communication/rules-auto/slash-command-routing-policy-mechanics.md +54 -19
- package/.agent-src/contexts/communication/rules-auto/think-before-action-mechanics.md +98 -0
- package/.agent-src/contexts/communication/rules-auto/token-efficiency-mechanics.md +93 -0
- package/.agent-src/contexts/communication/rules-auto/user-interaction-mechanics.md +128 -5
- package/.agent-src/contexts/execution/autonomy-mechanics.md +44 -0
- package/.agent-src/contexts/execution/roadmap-process-loop.md +125 -0
- package/.agent-src/contexts/model-recommendations.md +2 -2
- package/.agent-src/contexts/override-system.md +1 -1
- package/.agent-src/contexts/skills-and-commands.md +1 -1
- package/.agent-src/personas/product-owner.md +2 -2
- package/.agent-src/personas/qa.md +1 -1
- package/.agent-src/rules/agent-authority.md +5 -6
- package/.agent-src/rules/agent-docs.md +11 -53
- package/.agent-src/rules/analysis-skill-routing.md +10 -40
- package/.agent-src/rules/architecture.md +6 -1
- package/.agent-src/rules/artifact-drafting-protocol.md +5 -0
- package/.agent-src/rules/artifact-engagement-recording.md +23 -59
- package/.agent-src/rules/ask-when-uncertain.md +24 -47
- package/.agent-src/rules/augment-portability.md +14 -62
- package/.agent-src/rules/augment-source-of-truth.md +10 -1
- package/.agent-src/rules/autonomous-execution.md +17 -98
- package/.agent-src/rules/capture-learnings.md +9 -80
- package/.agent-src/rules/cli-output-handling.md +12 -42
- package/.agent-src/rules/command-suggestion-policy.md +25 -73
- package/.agent-src/rules/commit-conventions.md +9 -58
- package/.agent-src/rules/commit-policy.md +16 -47
- package/.agent-src/rules/context-hygiene.md +5 -0
- package/.agent-src/rules/direct-answers.md +21 -50
- package/.agent-src/rules/docker-commands.md +11 -45
- package/.agent-src/rules/docs-sync.md +10 -56
- package/.agent-src/rules/downstream-changes.md +5 -0
- package/.agent-src/rules/e2e-testing.md +9 -44
- package/.agent-src/rules/guidelines.md +13 -75
- package/.agent-src/rules/improve-before-implement.md +11 -2
- package/.agent-src/rules/invite-challenge.md +71 -0
- package/.agent-src/rules/language-and-tone.md +41 -106
- package/.agent-src/rules/laravel-translations.md +11 -40
- package/.agent-src/rules/markdown-safe-codeblocks.md +4 -0
- package/.agent-src/rules/minimal-safe-diff.md +4 -0
- package/.agent-src/rules/missing-tool-handling.md +4 -0
- package/.agent-src/rules/model-recommendation.md +9 -61
- package/.agent-src/rules/no-attribution-footers.md +5 -0
- package/.agent-src/rules/no-cheap-questions.md +11 -27
- package/.agent-src/rules/no-council-references.md +76 -0
- package/.agent-src/rules/no-roadmap-references.md +7 -0
- package/.agent-src/rules/non-destructive-by-default.md +13 -43
- package/.agent-src/rules/onboarding-gate.md +9 -117
- package/.agent-src/rules/package-ci-checks.md +10 -37
- package/.agent-src/rules/php-coding.md +10 -55
- package/.agent-src/rules/preservation-guard.md +9 -0
- package/.agent-src/rules/review-routing-awareness.md +9 -97
- package/.agent-src/rules/reviewer-awareness.md +8 -83
- package/.agent-src/rules/roadmap-progress-sync.md +7 -170
- package/.agent-src/rules/role-mode-adherence.md +6 -2
- package/.agent-src/rules/rule-type-governance.md +8 -66
- package/.agent-src/rules/runtime-safety.md +5 -0
- package/.agent-src/rules/scope-control.md +17 -62
- package/.agent-src/rules/security-sensitive-stop.md +7 -1
- package/.agent-src/rules/size-enforcement.md +6 -1
- package/.agent-src/rules/skill-improvement-trigger.md +9 -49
- package/.agent-src/rules/skill-quality.md +7 -113
- package/.agent-src/rules/slash-command-routing-policy.md +11 -63
- package/.agent-src/rules/think-before-action.md +22 -87
- package/.agent-src/rules/token-efficiency.md +10 -74
- package/.agent-src/rules/token-optimizer-maintenance.md +68 -0
- package/.agent-src/rules/tool-safety.md +4 -0
- package/.agent-src/rules/ui-audit-gate.md +25 -61
- package/.agent-src/rules/upstream-proposal.md +9 -67
- package/.agent-src/rules/user-interaction.md +22 -108
- package/.agent-src/rules/verify-before-complete.md +1 -1
- package/.agent-src/skills/adversarial-review/SKILL.md +1 -0
- package/.agent-src/skills/agent-docs-writing/SKILL.md +1 -1
- package/.agent-src/skills/ai-council/SKILL.md +197 -8
- package/.agent-src/skills/analysis-autonomous-mode/SKILL.md +1 -1
- package/.agent-src/skills/analysis-skill-router/SKILL.md +3 -3
- package/.agent-src/skills/artisan-commands/SKILL.md +2 -2
- package/.agent-src/skills/authz-review/SKILL.md +1 -1
- package/.agent-src/skills/aws-infrastructure/SKILL.md +5 -5
- package/.agent-src/skills/blast-radius-analyzer/SKILL.md +8 -8
- package/.agent-src/skills/bug-analyzer/SKILL.md +6 -5
- package/.agent-src/skills/code-refactoring/SKILL.md +4 -4
- package/.agent-src/skills/code-review/SKILL.md +2 -2
- package/.agent-src/skills/command-writing/SKILL.md +11 -0
- package/.agent-src/skills/composer-packages/SKILL.md +2 -2
- package/.agent-src/skills/context-authoring/SKILL.md +11 -0
- package/.agent-src/skills/context-document/SKILL.md +1 -1
- package/.agent-src/skills/copilot-agents-optimization/SKILL.md +23 -0
- package/.agent-src/skills/copilot-config/SKILL.md +1 -1
- package/.agent-src/skills/dependency-upgrade/SKILL.md +2 -2
- package/.agent-src/skills/devcontainer/SKILL.md +2 -2
- package/.agent-src/skills/developer-like-execution/SKILL.md +1 -1
- package/.agent-src/skills/docker/SKILL.md +1 -1
- package/.agent-src/skills/dto-creator/SKILL.md +1 -1
- package/.agent-src/skills/estimate-ticket/SKILL.md +2 -2
- package/.agent-src/skills/fe-design/SKILL.md +4 -4
- package/.agent-src/skills/feature-planning/SKILL.md +5 -5
- package/.agent-src/skills/funnel-analysis/SKILL.md +1 -1
- package/.agent-src/skills/laravel/SKILL.md +1 -1
- package/.agent-src/skills/laravel-notifications/SKILL.md +5 -5
- package/.agent-src/skills/laravel-pennant/SKILL.md +1 -1
- package/.agent-src/skills/laravel-pulse/SKILL.md +4 -4
- package/.agent-src/skills/laravel-reverb/SKILL.md +2 -2
- package/.agent-src/skills/laravel-scheduling/SKILL.md +1 -1
- package/.agent-src/skills/migration-creator/SKILL.md +7 -7
- package/.agent-src/skills/multi-tenancy/SKILL.md +8 -8
- package/.agent-src/skills/performance-analysis/SKILL.md +3 -3
- package/.agent-src/skills/pest-testing/SKILL.md +6 -6
- package/.agent-src/skills/php-service/SKILL.md +2 -2
- package/.agent-src/skills/project-analysis-hypothesis-driven/SKILL.md +3 -3
- package/.agent-src/skills/project-analysis-react/SKILL.md +1 -1
- package/.agent-src/skills/project-analysis-symfony/SKILL.md +1 -1
- package/.agent-src/skills/project-analysis-zend-laminas/SKILL.md +2 -2
- package/.agent-src/skills/project-analyzer/SKILL.md +4 -4
- package/.agent-src/skills/prompt-optimizer/SKILL.md +108 -0
- package/.agent-src/skills/readme-reviewer/SKILL.md +1 -1
- package/.agent-src/skills/roadmap-management/SKILL.md +7 -7
- package/.agent-src/skills/rule-writing/SKILL.md +33 -0
- package/.agent-src/skills/sentry-integration/SKILL.md +1 -1
- package/.agent-src/skills/skill-writing/SKILL.md +14 -0
- package/.agent-src/skills/systematic-debugging/SKILL.md +22 -2
- package/.agent-src/skills/technical-specification/SKILL.md +58 -1
- package/.agent-src/skills/terraform/SKILL.md +2 -2
- package/.agent-src/skills/terragrunt/SKILL.md +8 -8
- package/.agent-src/skills/test-performance/SKILL.md +5 -5
- package/.agent-src/skills/threat-modeling/SKILL.md +3 -2
- package/.agent-src/skills/token-optimizer/SKILL.md +110 -0
- package/.agent-src/skills/universal-project-analysis/SKILL.md +1 -1
- package/.agent-src/templates/AGENTS.md +1 -1
- package/.agent-src/templates/agent-settings.md +35 -19
- package/.agent-src/templates/command.md +17 -1
- package/.agent-src/templates/contexts/tenant-boundaries.md +2 -2
- package/.agent-src/templates/contexts.md +1 -1
- package/.agent-src/templates/copilot-instructions.md +21 -0
- package/.agent-src/templates/copilot-review-instructions.md +76 -0
- package/.agent-src/templates/features.md +1 -1
- package/.agent-src/templates/roadmaps.md +10 -2
- package/.agent-src/templates/rule.md +129 -0
- package/.agent-src/templates/skill.md +17 -0
- package/.claude-plugin/marketplace.json +12 -2
- package/AGENTS.md +32 -5
- package/CHANGELOG.md +107 -3
- package/README.md +22 -21
- package/config/agent-settings.template.yml +66 -10
- package/config/gitignore-block.txt +7 -0
- package/docs/architecture.md +86 -5
- package/docs/catalog.md +16 -6
- package/docs/contracts/agent-memory-contract.md +1 -1
- package/docs/contracts/command-clusters.md +45 -1
- package/docs/contracts/context-paths.md +2 -1
- package/docs/contracts/file-ownership-matrix.json +354 -500
- package/docs/contracts/iron-law-overrides.txt +25 -0
- package/docs/contracts/kernel-membership.md +273 -0
- package/docs/contracts/load-context-schema.md +26 -11
- package/docs/contracts/pilot/agent-authority.md +24 -0
- package/docs/contracts/pilot/direct-answers.md +70 -0
- package/docs/contracts/pilot/language-and-tone.md +63 -0
- package/docs/contracts/rule-classification.md +170 -0
- package/docs/contracts/rule-router.md +153 -0
- package/docs/customization.md +17 -6
- package/docs/decisions/ADR-001-kernel-swap-deferred.md +109 -0
- package/docs/decisions/ADR-002-kernel-bucket-overrides.md +124 -0
- package/docs/decisions/ADR-003-flat-cluster-subs-and-colon-syntax.md +126 -0
- package/docs/decisions/ADR-rule-kernel-and-router.md +122 -0
- package/docs/getting-started.md +2 -2
- package/docs/guidelines/agent-infra/naming.md +1 -1
- package/docs/guidelines/agent-infra/roadmap-progress-mechanics.md +176 -0
- package/docs/guidelines/agent-infra/rule-type-governance.md +73 -0
- package/docs/guidelines/agent-infra/size-and-scope.md +13 -2
- package/docs/guidelines/agent-infra/skill-quality-checklist.md +119 -0
- package/docs/guidelines/augment-portability-patterns.md +68 -0
- package/docs/guidelines/php/php-coding-patterns.md +62 -0
- package/package.json +1 -1
- package/scripts/_p43_bodies.py +235 -0
- package/scripts/_p43_compress.py +118 -0
- package/scripts/_p4_migrate.py +199 -0
- package/scripts/_phase2_shim_helper.py +1 -1
- package/scripts/_pilot_council_question.py +57 -0
- package/scripts/_pilot_measure.py +53 -0
- package/scripts/ai_council/session.py +107 -5
- package/scripts/build_linear_digest.py +3 -5
- package/scripts/check_always_budget.py +39 -6
- package/scripts/check_compressed_paths.py +213 -0
- package/scripts/check_compression.py +15 -0
- package/scripts/check_context_paths.py +1 -0
- package/scripts/check_council_layout.py +105 -0
- package/scripts/check_council_references.py +145 -0
- package/scripts/check_portability.py +2 -0
- package/scripts/check_references.py +2 -0
- package/scripts/check_token_optimizer_freshness.py +131 -0
- package/scripts/compile_router.py +148 -0
- package/scripts/compress.py +219 -11
- package/scripts/council_cli.py +132 -11
- package/scripts/council_prune.py +81 -0
- package/scripts/count_token_optimizer_usage.sh +54 -0
- package/scripts/install.sh +44 -2
- package/scripts/iron_law_sha.py +98 -0
- package/scripts/lint_load_context.py +35 -5
- package/scripts/measure_rule_budget.py +314 -0
- package/scripts/migrate_command_suggestions.py +2 -2
- package/scripts/prototype_lint_contradictions.py +150 -0
- package/scripts/schemas/command.schema.json +5 -0
- package/scripts/schemas/rule.schema.json +60 -6
- package/scripts/schemas/skill.schema.json +5 -0
- package/scripts/skill_linter.py +197 -7
- package/scripts/smoke_path_resolution.py +93 -0
- package/scripts/validate_frontmatter.py +41 -1
- package/.agent-src/commands/roadmap/execute.md +0 -109
- package/.agent-src/contexts/communication/rules-auto/artifact-engagement-recording-mechanics.md +0 -72
- package/.agent-src/contexts/communication/rules-auto/augment-portability-mechanics.md +0 -79
- package/.agent-src/contexts/communication/rules-auto/cli-output-handling-mechanics.md +0 -87
- package/.agent-src/contexts/communication/rules-auto/command-suggestion-policy-mechanics.md +0 -62
- package/.agent-src/contexts/communication/rules-auto/docs-sync-mechanics.md +0 -78
- package/.agent-src/contexts/communication/rules-auto/package-ci-checks-mechanics.md +0 -85
- package/.agent-src/contexts/communication/rules-auto/review-routing-awareness-mechanics.md +0 -65
- package/.agent-src/contexts/communication/rules-auto/roadmap-progress-sync-mechanics.md +0 -78
- package/.agent-src/contexts/communication/rules-auto/ui-audit-gate-mechanics.md +0 -53
- /package/{docs → .agent-src/contexts}/contracts/artifact-engagement-flow.md +0 -0
- /package/{docs → .agent-src/contexts}/contracts/command-suggestion-flow.md +0 -0
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
# Roadmap-Process Loop
|
|
2
|
+
|
|
3
|
+
Loaded by [`/roadmap:process-step`](../../commands/roadmap/process-step.md),
|
|
4
|
+
[`/roadmap:process-phase`](../../commands/roadmap/process-phase.md), and
|
|
5
|
+
[`/roadmap:process-full`](../../commands/roadmap/process-full.md). Holds
|
|
6
|
+
the canonical autonomous-execution loop, roadmap discovery, cadence
|
|
7
|
+
resolution, commit-step pre-scan, halt conditions, and archival check.
|
|
8
|
+
The three command files are thin wrappers that bind only the **scope
|
|
9
|
+
delta**.
|
|
10
|
+
|
|
11
|
+
**Size budget:** ≤ 4,000 chars.
|
|
12
|
+
|
|
13
|
+
## 1. Resolve roadmap
|
|
14
|
+
|
|
15
|
+
Search both locations:
|
|
16
|
+
|
|
17
|
+
- `agents/roadmaps/*.md` (project root)
|
|
18
|
+
- `app/Modules/*/agents/roadmaps/*.md` (module-scoped)
|
|
19
|
+
|
|
20
|
+
**Exclude** `template.md`, `archive/`, and `skipped/`.
|
|
21
|
+
|
|
22
|
+
- User named one (path, partial name, title) → use it.
|
|
23
|
+
- None named, single active roadmap (`count_open > 0`) → use it.
|
|
24
|
+
- None named, multiple active → default = **most recently modified**;
|
|
25
|
+
surface alternatives in the pre-run summary.
|
|
26
|
+
- None active → tell the user; suggest [`/roadmap:create`](../../commands/roadmap/create.md).
|
|
27
|
+
|
|
28
|
+
## 2. Pre-run summary — single confirmation gate
|
|
29
|
+
|
|
30
|
+
Before the loop runs, show the resolved config in the user's language:
|
|
31
|
+
|
|
32
|
+
> Roadmap: `<resolved-path>`
|
|
33
|
+
> Phase 1: `<name>` — 3/5 done
|
|
34
|
+
> Phase 2: `<name>` — 0/4
|
|
35
|
+
> Next open step: `<description>`
|
|
36
|
+
> Scope: **step | phase | full**
|
|
37
|
+
> AI council: **on | off** (`<member list or "no members configured">`)
|
|
38
|
+
> Quality cadence: **end_of_roadmap | per_phase | per_step**
|
|
39
|
+
> Commit steps in roadmap: **N** (see § 3)
|
|
40
|
+
>
|
|
41
|
+
> 1. Go — start processing autonomously
|
|
42
|
+
> 2. Different roadmap · 3. Different scope · 4. Toggle council · 5. Abort
|
|
43
|
+
|
|
44
|
+
Skip the gate when scope, roadmap, and council are all unambiguous in
|
|
45
|
+
the invocation (e.g. `/roadmap:process-phase road-to-X.md with council`).
|
|
46
|
+
|
|
47
|
+
## 3. Commit-step pre-scan — one upfront ask
|
|
48
|
+
|
|
49
|
+
Before step 4, scan the roadmap for explicit commit steps (lines
|
|
50
|
+
matching `commit:` / `git commit` / `Commit phase` patterns).
|
|
51
|
+
|
|
52
|
+
- **No commit steps** → nothing to ask. Never commit, never re-ask
|
|
53
|
+
per [`commit-policy`](../../rules/commit-policy.md).
|
|
54
|
+
- **Commit steps present, autonomous mode** (`personal.autonomy: on`,
|
|
55
|
+
or `auto` after opt-in) → ask **once** upfront:
|
|
56
|
+
> "Roadmap contains N commit steps. Authorize all of them for this
|
|
57
|
+
> run? (yes / no / list them)"
|
|
58
|
+
Cache the answer for the whole run; do **not** re-ask per step.
|
|
59
|
+
Hard-Floor diffs (bulk deletions, infra) still trigger the
|
|
60
|
+
per-commit gate from [`commit-mechanics`](../authority/commit-mechanics.md).
|
|
61
|
+
- **Commit steps present, non-autonomous** → ask before each commit
|
|
62
|
+
step inside the loop.
|
|
63
|
+
|
|
64
|
+
## 4. Resolve quality cadence
|
|
65
|
+
|
|
66
|
+
Read `roadmap.quality_cadence` from `.agent-settings.yml` once:
|
|
67
|
+
|
|
68
|
+
| Value | Pipeline runs |
|
|
69
|
+
|---|---|
|
|
70
|
+
| `end_of_roadmap` (default) | Once, before archival (§ 6) |
|
|
71
|
+
| `per_phase` | At every phase boundary + § 6 |
|
|
72
|
+
| `per_step` | After every step + § 6 |
|
|
73
|
+
|
|
74
|
+
Missing / unreadable / unknown → fall back to `end_of_roadmap`.
|
|
75
|
+
The Iron Law [`verify-before-complete`](../../rules/verify-before-complete.md)
|
|
76
|
+
still mandates fresh quality output before any "complete" claim.
|
|
77
|
+
|
|
78
|
+
## 5. Step loop
|
|
79
|
+
|
|
80
|
+
For each open step in the working set (scope-bound — see wrapper):
|
|
81
|
+
|
|
82
|
+
1. Read the step description and inline notes.
|
|
83
|
+
2. Analyze the codebase for what the step requires.
|
|
84
|
+
3. Decide and act — implement. **No "should I implement this?" prompt.**
|
|
85
|
+
4. **Open question handling:**
|
|
86
|
+
- **Council on** → invoke per [`ai-council`](../../skills/ai-council/SKILL.md),
|
|
87
|
+
integrate convergence, proceed. Token spend was opted in.
|
|
88
|
+
- **Council off** → halt, surface once, wait. Resume on next turn.
|
|
89
|
+
5. Mark the checkbox: `[x]` done · `[~]` partial · `[-]` skipped.
|
|
90
|
+
6. Regenerate the dashboard — `./agent-config roadmap:progress` — in
|
|
91
|
+
the **same response** per [`roadmap-progress-sync`](../../rules/roadmap-progress-sync.md).
|
|
92
|
+
7. Run quality pipeline if cadence is `per_step`.
|
|
93
|
+
|
|
94
|
+
### Halt conditions
|
|
95
|
+
|
|
96
|
+
- Hard-Floor trigger ([`non-destructive-by-default`](../../rules/non-destructive-by-default.md))
|
|
97
|
+
- Security-sensitive path ([`security-sensitive-stop`](../../rules/security-sensitive-stop.md))
|
|
98
|
+
- Step reveals work outside the roadmap's scope
|
|
99
|
+
- Test failure or quality red on `per_step`
|
|
100
|
+
- Council off + true ambiguity
|
|
101
|
+
|
|
102
|
+
On halt: stop, surface state, do **not** auto-fix outside the failing step.
|
|
103
|
+
|
|
104
|
+
## 6. Final report and archival
|
|
105
|
+
|
|
106
|
+
- Summary: scope-bound (steps/phases done in this run), council
|
|
107
|
+
consultations count (if on), steps remaining, halts.
|
|
108
|
+
- Final dashboard regen.
|
|
109
|
+
- **If the entire roadmap reached `count_open == 0`** → run the full
|
|
110
|
+
project quality pipeline. On green → archival via the
|
|
111
|
+
[`roadmap-management`](../../skills/roadmap-management/SKILL.md) skill
|
|
112
|
+
(`git mv` to `agents/roadmaps/archive/`, regenerate dashboard). On
|
|
113
|
+
red → stop, surface failures, do **not** archive.
|
|
114
|
+
|
|
115
|
+
## Scope deltas — what each wrapper binds
|
|
116
|
+
|
|
117
|
+
| Wrapper | Working set | Stop after |
|
|
118
|
+
|---|---|---|
|
|
119
|
+
| `process-step` | Single first open step | One iteration of § 5 |
|
|
120
|
+
| `process-phase` | All open steps in first phase with `count_open > 0` | Phase boundary; per-phase quality if cadence ≠ `end_of_roadmap` |
|
|
121
|
+
| `process-full` | Every open step across every phase, in order | Roadmap fully closed (or halt) |
|
|
122
|
+
|
|
123
|
+
`process-full` runs the per-phase quality pipeline at every phase
|
|
124
|
+
boundary when cadence is `per_phase` or `per_step`; on red it halts
|
|
125
|
+
before the next phase.
|
|
@@ -91,7 +91,7 @@ produce opus-level quality by enforcing habits that weaker models skip by defaul
|
|
|
91
91
|
- **Default to `sonnet`** — it's the cost-efficient workhorse.
|
|
92
92
|
- **Escalate to `opus`** only when architecture, refactoring, or unclear debugging is involved.
|
|
93
93
|
- **After Opus work** (architecture plan, refactoring design, root cause found):
|
|
94
|
-
→ Recommend switching back to `sonnet` for
|
|
94
|
+
→ Recommend switching back to `sonnet` for impl.
|
|
95
95
|
- **Use `gpt`** for large-scale analysis, searching across many files, or automation.
|
|
96
96
|
|
|
97
97
|
## Recommendation Flow
|
|
@@ -121,7 +121,7 @@ When user says they want to continue with the current model:
|
|
|
121
121
|
### Downgrade reminder
|
|
122
122
|
|
|
123
123
|
After completing an opus-level task (architecture plan done, refactoring complete, root cause found),
|
|
124
|
-
remind the user to switch back to sonnet for the
|
|
124
|
+
remind the user to switch back to sonnet for the impl phase:
|
|
125
125
|
|
|
126
126
|
```
|
|
127
127
|
> 💡 The {architecture/debugging/design} phase is done.
|
|
@@ -155,7 +155,7 @@ When a project using this package wants to **optimize** a shared rule or skill:
|
|
|
155
155
|
|
|
156
156
|
### Anti-patterns
|
|
157
157
|
|
|
158
|
-
- Keeping the override after upstream merge →
|
|
158
|
+
- Keeping the override after upstream merge → → drift
|
|
159
159
|
- Submitting only the compressed version → breaks source-of-truth workflow
|
|
160
160
|
- Submitting project-specific behavior as universal improvement
|
|
161
161
|
- Forgetting to create the PR → improvement stays siloed
|
|
@@ -30,7 +30,7 @@ Commands often chain together. Here are the main workflows:
|
|
|
30
30
|
### Feature Development
|
|
31
31
|
|
|
32
32
|
```
|
|
33
|
-
/feature-explore → /feature-plan → /feature-roadmap → /roadmap-
|
|
33
|
+
/feature-explore → /feature-plan → /feature-roadmap → /roadmap:process-phase
|
|
34
34
|
↓ ↓ ↓ ↓
|
|
35
35
|
Brainstorm Structure Phases/Steps Implement
|
|
36
36
|
```
|
|
@@ -52,12 +52,12 @@ Concrete and user-facing. Each finding names a missing outcome, an
|
|
|
52
52
|
unverifiable AC, or a scope item whose removal would not hurt the
|
|
53
53
|
user. When the persona proposes a rewritten AC, it is a single
|
|
54
54
|
sentence in the form "the user can X when Y". Findings that are
|
|
55
|
-
purely
|
|
55
|
+
purely impl concerns are out of scope — escalate to
|
|
56
56
|
`developer` or `senior-engineer`.
|
|
57
57
|
|
|
58
58
|
## Anti-Patterns
|
|
59
59
|
|
|
60
|
-
- Do NOT write
|
|
60
|
+
- Do NOT write impl details or technical designs — that
|
|
61
61
|
is the `developer` and `senior-engineer` space.
|
|
62
62
|
- Do NOT invoke "business value" as an argument without naming the
|
|
63
63
|
user and the outcome.
|
|
@@ -38,7 +38,7 @@ It is the lens that refuses to confuse coverage with confidence.
|
|
|
38
38
|
test would catch?
|
|
39
39
|
- Which assertion is missing — the one that would have caught the
|
|
40
40
|
bug we just fixed, or the bug one ticket away?
|
|
41
|
-
- Where is the test verifying the
|
|
41
|
+
- Where is the test verifying the impl instead of the
|
|
42
42
|
behavior?
|
|
43
43
|
- Which boundary — empty, null, max, concurrent, re-entrant — is
|
|
44
44
|
not represented in the test suite for this code path?
|
|
@@ -8,7 +8,7 @@ source: package
|
|
|
8
8
|
|
|
9
9
|
# Agent Authority — Priority Index
|
|
10
10
|
|
|
11
|
-
Four rules answer **"may the agent do this autonomously?"**
|
|
11
|
+
Four rules answer **"may the agent do this autonomously?"** Higher band wins.
|
|
12
12
|
|
|
13
13
|
| Band | Trigger | Canonical rule |
|
|
14
14
|
|---|---|---|
|
|
@@ -17,9 +17,8 @@ Four rules answer **"may the agent do this autonomously?"** Check bands in order
|
|
|
17
17
|
| **3. Commit Default** | About to commit — never, unless one of four exceptions fires | [`commit-policy`](commit-policy.md) |
|
|
18
18
|
| **4. Trivial-vs-Blocking** | Routine workflow question — act or ask | [`autonomous-execution`](autonomous-execution.md) |
|
|
19
19
|
|
|
20
|
-
##
|
|
20
|
+
## Rules
|
|
21
21
|
|
|
22
|
-
-
|
|
23
|
-
-
|
|
24
|
-
-
|
|
25
|
-
- **Unsure → ask.** [`ask-when-uncertain`](ask-when-uncertain.md) is the universal escape hatch.
|
|
22
|
+
- Hard Floor wins, always — autonomy / roadmap / standing instruction never lift.
|
|
23
|
+
- Higher band wins on conflict — commit exception ≠ Hard Floor override; scope permission ≠ commit override.
|
|
24
|
+
- Unsure → [`ask-when-uncertain`](ask-when-uncertain.md).
|
|
@@ -3,60 +3,18 @@ type: "auto"
|
|
|
3
3
|
tier: "2a"
|
|
4
4
|
description: "Reading, creating, or updating agent documentation, module docs, roadmaps, or AGENTS.md"
|
|
5
5
|
source: package
|
|
6
|
+
triggers:
|
|
7
|
+
- path_prefix: "agents/"
|
|
8
|
+
- path_prefix: ".github/copilot-instructions"
|
|
9
|
+
- keyword: "AGENTS.md"
|
|
10
|
+
- keyword: "roadmap"
|
|
11
|
+
routes_to:
|
|
12
|
+
- "skill:agent-docs-writing"
|
|
6
13
|
---
|
|
7
14
|
|
|
8
|
-
# Agent
|
|
15
|
+
# Agent Docs
|
|
9
16
|
|
|
10
|
-
|
|
17
|
+
**Iron Law.** Read agent docs (`AGENTS.md`, `agents/`, module `agents/`) before work; update them after structural changes.
|
|
11
18
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
1. **Always read** `AGENTS.md` (if it exists in the project root) for project-level setup and conventions.
|
|
15
|
-
2. **Always read** `./agents/` for project-specific architecture, guidelines, and domain docs.
|
|
16
|
-
3. **If domain contexts exist** (`agents/contexts/domain/`) → read any that are relevant to the current work area.
|
|
17
|
-
4. **If working on a module** → also read `app/Modules/{Module}/agents/` for module-specific docs,
|
|
18
|
-
including `agents/contexts/` within the module if it exists.
|
|
19
|
-
5. **If working on a package** → read the package's `./agents/` directory.
|
|
20
|
-
6. **If a roadmap exists** for the current work → read it first and follow its steps.
|
|
21
|
-
|
|
22
|
-
## When to update agent docs
|
|
23
|
-
|
|
24
|
-
After making changes, check if any agent docs need to be updated:
|
|
25
|
-
|
|
26
|
-
- **New module created** → create `app/Modules/{Module}/agents/` with at least a module description.
|
|
27
|
-
- **Database schema changed** → update `agents/docs/database-setup.md` or equivalent.
|
|
28
|
-
- **New service/pattern introduced** → update relevant guideline docs.
|
|
29
|
-
- **Roadmap step completed** → mark it as done in the roadmap file (`[x]`).
|
|
30
|
-
- **Structural changes** (new conventions, renamed classes, moved files) → update affected docs.
|
|
31
|
-
|
|
32
|
-
If unsure whether a doc needs updating, **ask the user**.
|
|
33
|
-
|
|
34
|
-
## When to create roadmaps
|
|
35
|
-
|
|
36
|
-
When working on a **significant change** that spans multiple steps or sessions:
|
|
37
|
-
|
|
38
|
-
- Ask the user whether to create a roadmap in `agents/roadmaps/`.
|
|
39
|
-
- Use the `roadmap-create` command if yes.
|
|
40
|
-
- This ensures future sessions (and other agents) can pick up the work.
|
|
41
|
-
|
|
42
|
-
## Roadmap lifecycle
|
|
43
|
-
|
|
44
|
-
Every roadmap ends in exactly one folder — never leave stale files in `agents/roadmaps/`:
|
|
45
|
-
|
|
46
|
-
- `agents/roadmaps/` — active (in progress or planned)
|
|
47
|
-
- `agents/roadmaps/archive/` — finished (work happened, fully or partially)
|
|
48
|
-
- `agents/roadmaps/skipped/` — not pursued (typically 0 items `[x]`, scope rejected or superseded)
|
|
49
|
-
|
|
50
|
-
The `roadmap-management` skill owns the trigger matrix and user-confirmation flow.
|
|
51
|
-
Never delete a roadmap — always move it.
|
|
52
|
-
|
|
53
|
-
## Documentation language
|
|
54
|
-
|
|
55
|
-
- All `.md` files must be written in **English**.
|
|
56
|
-
- If an existing file is in German or another language, translate it to English when you touch it.
|
|
57
|
-
|
|
58
|
-
## Do NOT
|
|
59
|
-
|
|
60
|
-
- Do NOT create docs unless there's a real need (new module, significant change, etc.).
|
|
61
|
-
- Do NOT duplicate information that's already in `AGENTS.md` or `.github/copilot-instructions.md`.
|
|
62
|
-
- Do NOT write docs just to document what you did — only document things others need to know.
|
|
19
|
+
Body migrated to `skill:agent-docs-writing` (per P4 of `road-to-kernel-and-router.md`).
|
|
20
|
+
Trigger-set above activates this routing under the `balanced` and `full` profiles.
|
|
@@ -1,49 +1,19 @@
|
|
|
1
1
|
---
|
|
2
|
-
type: auto
|
|
2
|
+
type: "auto"
|
|
3
3
|
tier: "3"
|
|
4
4
|
description: "When choosing an analysis skill, route to the narrowest matching skill instead of defaulting to broad analysis"
|
|
5
5
|
source: package
|
|
6
|
+
triggers:
|
|
7
|
+
- keyword: "analyze"
|
|
8
|
+
- keyword: "analysis"
|
|
9
|
+
- phrase: "dig into the codebase"
|
|
10
|
+
routes_to:
|
|
11
|
+
- "skill:analysis-skill-router"
|
|
6
12
|
---
|
|
7
13
|
|
|
8
14
|
# Analysis Skill Routing
|
|
9
15
|
|
|
10
|
-
|
|
16
|
+
**Iron Law.** Route analysis tasks to the narrowest matching `project-analysis-*` skill, not the broad fallback.
|
|
11
17
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
* full project analysis
|
|
15
|
-
* deep architecture review
|
|
16
|
-
* broad multi-layer debugging
|
|
17
|
-
* unclear systems where the stack or boundaries must first be discovered
|
|
18
|
-
|
|
19
|
-
Use framework-specific project-analysis skills only after the framework is known.
|
|
20
|
-
|
|
21
|
-
Use root-cause analysis skills when the problem is concrete and hypothesis-driven.
|
|
22
|
-
|
|
23
|
-
Do not use broad analysis skills for:
|
|
24
|
-
|
|
25
|
-
* small isolated code questions
|
|
26
|
-
* normal feature work
|
|
27
|
-
* obvious local fixes
|
|
28
|
-
* framework-specific issues that already have a dedicated skill
|
|
29
|
-
|
|
30
|
-
Prefer:
|
|
31
|
-
|
|
32
|
-
* narrow specialist skill over broad analysis skill
|
|
33
|
-
* framework-specific skill over universal router when the framework is already explicit
|
|
34
|
-
* root-cause skill over full-project analysis when the issue is already localized
|
|
35
|
-
|
|
36
|
-
If the stack is unclear:
|
|
37
|
-
|
|
38
|
-
* start broad
|
|
39
|
-
* then narrow quickly
|
|
40
|
-
|
|
41
|
-
## Routing quality gate
|
|
42
|
-
|
|
43
|
-
Only route to the narrower skill if it still has:
|
|
44
|
-
|
|
45
|
-
* executable workflow (concrete procedure steps)
|
|
46
|
-
* concrete validation (specific checks, not "verify it works")
|
|
47
|
-
* real decision power (not just "read the guideline")
|
|
48
|
-
|
|
49
|
-
If the narrow skill is too weak or hollowed out, route through the broader skill and note the gap.
|
|
18
|
+
Body migrated to `skill:analysis-skill-router` (per P4 of `road-to-kernel-and-router.md`).
|
|
19
|
+
Trigger-set above activates this routing under the `balanced` and `full` profiles.
|
|
@@ -4,6 +4,11 @@ tier: "3"
|
|
|
4
4
|
alwaysApply: false
|
|
5
5
|
description: "Architecture rules for creating new files, classes, controllers, modules, or making structural decisions about project organization"
|
|
6
6
|
source: package
|
|
7
|
+
triggers:
|
|
8
|
+
- keyword: "controller"
|
|
9
|
+
- keyword: "service"
|
|
10
|
+
- keyword: "module"
|
|
11
|
+
- intent: "structural decision"
|
|
7
12
|
---
|
|
8
13
|
|
|
9
14
|
# Architecture Rules
|
|
@@ -11,7 +16,7 @@ source: package
|
|
|
11
16
|
## General Principles
|
|
12
17
|
|
|
13
18
|
- **Controllers are thin** — no business logic, delegate to services.
|
|
14
|
-
- **Only Single Action Controllers** — every new controller MUST use `__invoke()`. No multi-action / resource controllers. See
|
|
19
|
+
- **Only Single Action Controllers** — every new controller MUST use `__invoke()`. No multi-action / resource controllers. See `../docs/guidelines/php/controllers.md` for naming conventions.
|
|
15
20
|
- **Every controller needs a FormRequest** — never validate inline with `$request->validate()`. Use a dedicated `FormRequest` subclass.
|
|
16
21
|
- **Services contain business logic** — calculations, orchestration, validation.
|
|
17
22
|
- **Models have no business logic** — only relationships, scopes, accessors/mutators.
|
|
@@ -4,6 +4,11 @@ tier: "2a"
|
|
|
4
4
|
alwaysApply: false
|
|
5
5
|
description: "Creating a new skill, rule, command, or guideline, or significantly rewriting one — runs a mandatory Understand → Research → Draft sequence before any artifact content is written."
|
|
6
6
|
source: package
|
|
7
|
+
triggers:
|
|
8
|
+
- intent: "create new skill"
|
|
9
|
+
- intent: "create new rule"
|
|
10
|
+
- intent: "create new command"
|
|
11
|
+
- intent: "create new guideline"
|
|
7
12
|
---
|
|
8
13
|
|
|
9
14
|
# Artifact Drafting Protocol
|
|
@@ -4,75 +4,39 @@ tier: "mechanical-already"
|
|
|
4
4
|
alwaysApply: false
|
|
5
5
|
description: "After a /implement-ticket or /work phase-step (refine/memory/analyze/plan/implement/test/verify/report) or full task — emit one telemetry:record call with consulted+applied ids when enabled"
|
|
6
6
|
source: package
|
|
7
|
+
triggers:
|
|
8
|
+
- phrase: "/implement-ticket"
|
|
9
|
+
- phrase: "/work"
|
|
10
|
+
- keyword: "telemetry"
|
|
11
|
+
routes_to:
|
|
12
|
+
- "contract:artifact-engagement-flow"
|
|
7
13
|
load_context:
|
|
8
|
-
-
|
|
14
|
+
- "../contexts/contracts/artifact-engagement-flow.md"
|
|
9
15
|
---
|
|
10
16
|
|
|
11
17
|
<!-- cloud_safe: noop -->
|
|
12
18
|
|
|
13
19
|
# Artifact Engagement Recording
|
|
14
20
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
Default-off; opt-in via `.agent-settings.yml`. Zero overhead when
|
|
21
|
+
**Iron Law.** After a `/implement-ticket` or `/work` phase-step, emit one
|
|
22
|
+
`telemetry:record` call with consulted + applied ids when telemetry is
|
|
23
|
+
enabled. Default-off; opt-in via `.agent-settings.yml`. Zero overhead when
|
|
24
|
+
disabled. Recording contract + privacy floor:
|
|
25
|
+
[`contexts/contracts/artifact-engagement-flow.md`](../contexts/contracts/artifact-engagement-flow.md).
|
|
18
26
|
|
|
19
|
-
The schema, CLI, and storage layer are owned by
|
|
20
|
-
|
|
21
|
-
`./agent-config telemetry:record` / `telemetry:status` commands. The
|
|
22
|
-
recording contract lives in
|
|
23
|
-
[`docs/contracts/artifact-engagement-flow.md`](../../docs/contracts/artifact-engagement-flow.md).
|
|
24
|
-
This rule says **when** to call the CLI, not how the file is structured.
|
|
27
|
+
The schema, CLI, and storage layer are owned by `scripts/telemetry/` and
|
|
28
|
+
the `./agent-config telemetry:record` / `telemetry:status` commands.
|
|
25
29
|
|
|
26
|
-
## Activation gate — read settings ONCE per task
|
|
30
|
+
## Activation gate — read settings ONCE per task
|
|
27
31
|
|
|
28
|
-
Before the first
|
|
29
|
-
`telemetry.artifact_engagement.enabled
|
|
30
|
-
|
|
32
|
+
Before the first phase-step runs, read
|
|
33
|
+
`telemetry.artifact_engagement.enabled`. Cache the value (and
|
|
34
|
+
`granularity`) for the whole task.
|
|
31
35
|
|
|
32
|
-
- `enabled: false` or section missing → rule is a **no-op**.
|
|
33
|
-
|
|
34
|
-
of this rule.
|
|
35
|
-
- `enabled: true` → continue with the cadence below.
|
|
36
|
+
- `enabled: false` or section missing → rule is a **no-op**.
|
|
37
|
+
- `enabled: true` → continue with the cadence in the contract.
|
|
36
38
|
|
|
37
|
-
|
|
38
|
-
not already in working memory; the call is read-only and never touches
|
|
39
|
-
the log file.
|
|
39
|
+
## Cloud Behavior
|
|
40
40
|
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
| `granularity` | When to emit | Coalescing |
|
|
44
|
-
|---|---|---|
|
|
45
|
-
| `task` *(default)* | Once, when the eight-step flow ends (success, blocked, partial — any terminal state) | All consulted/applied artefacts from refine through report merged into a single event |
|
|
46
|
-
| `phase-step` | At the close of each phase-step (refine, memory, analyze, plan, implement, test, verify, report) | One event per step; per-step consulted/applied lists only |
|
|
47
|
-
|
|
48
|
-
Within a single boundary, **dedupe** consulted and applied lists. A skill
|
|
49
|
-
consulted three times in the same boundary records once.
|
|
50
|
-
|
|
51
|
-
## What counts as consulted vs applied
|
|
52
|
-
|
|
53
|
-
- **`consulted`** — the agent **read** the artefact this boundary: opened
|
|
54
|
-
its `SKILL.md`, scanned its rule body, viewed its frontmatter,
|
|
55
|
-
referenced its guideline, checked its persona contract, dispatched its
|
|
56
|
-
command. Reading does not imply behaviour change.
|
|
57
|
-
- **`applied`** — the artefact **influenced the output** this boundary:
|
|
58
|
-
its instructions changed how the agent answered, what code it wrote,
|
|
59
|
-
what tools it ran, or what halt surface it produced. Applied is a
|
|
60
|
-
strict subset of consulted.
|
|
61
|
-
|
|
62
|
-
When in doubt → record as `consulted` only. Over-recording `applied`
|
|
63
|
-
inflates the engagement signal and defeats the purpose.
|
|
64
|
-
|
|
65
|
-
## Mechanics — CLI invocation, privacy contract, failure handling
|
|
66
|
-
|
|
67
|
-
The exact `telemetry:record` call shape with all flags, the privacy
|
|
68
|
-
contract (what NEVER goes into a record), the failure-mode handling
|
|
69
|
-
(do NOT block the user's task), and the "what this rule does NOT do"
|
|
70
|
-
catalog live in
|
|
71
|
-
[`contexts/communication/rules-auto/artifact-engagement-recording-mechanics.md`](../contexts/communication/rules-auto/artifact-engagement-recording-mechanics.md).
|
|
72
|
-
|
|
73
|
-
## See also
|
|
74
|
-
|
|
75
|
-
- [`docs/contracts/artifact-engagement-flow.md`](../../docs/contracts/artifact-engagement-flow.md) — recording contract details
|
|
76
|
-
- [`/implement-ticket`](../commands/implement-ticket.md) and [`/work`](../commands/work.md) — boundary points where this rule fires
|
|
77
|
-
- [`scripts/telemetry/`](../../../scripts/telemetry/) — engine source
|
|
78
|
-
- [`agent-settings`](../templates/agent-settings.md) — `telemetry.artifact_engagement.*` reference
|
|
41
|
+
The `cloud_safe: noop` marker keeps this rule inert on cloud surfaces
|
|
42
|
+
(Claude.ai Web, Skills API). The cloud-bundle pipeline skips it.
|
|
@@ -8,8 +8,7 @@ source: package
|
|
|
8
8
|
|
|
9
9
|
# Ask When Uncertain
|
|
10
10
|
|
|
11
|
-
**When in doubt, ask
|
|
12
|
-
Asking one question too many is always better than a wrong assumption.
|
|
11
|
+
**When in doubt, ask.** Don't guess, assume, or improvise. One question too many beats one wrong assumption.
|
|
13
12
|
|
|
14
13
|
## Iron Law — one question per turn, ALWAYS
|
|
15
14
|
|
|
@@ -18,22 +17,19 @@ ONE QUESTION PER TURN. NO EXCEPTIONS.
|
|
|
18
17
|
ASK. WAIT FOR THE ANSWER. THEN ASK THE NEXT.
|
|
19
18
|
```
|
|
20
19
|
|
|
21
|
-
Absolute.
|
|
22
|
-
has **exactly one**. Even if trivial, independent, or batchable.
|
|
23
|
-
Self-check, ordering, handoff under [How to ask](#how-to-ask).
|
|
20
|
+
Absolute. Every turn with a question has **exactly one** — even if trivial, independent, or batchable.
|
|
24
21
|
|
|
25
22
|
## When to ask
|
|
26
23
|
|
|
27
|
-
- Requirement ambiguous or multi-interpretable
|
|
28
|
-
- Not 100% sure which approach is correct
|
|
29
|
-
- About to touch code you haven't fully understood
|
|
30
|
-
- Choosing between multiple valid approaches
|
|
31
|
-
- A fix "seems to work" but you can't explain why
|
|
24
|
+
- Requirement ambiguous or multi-interpretable.
|
|
25
|
+
- Not 100 % sure which approach is correct.
|
|
26
|
+
- About to touch code you haven't fully understood.
|
|
27
|
+
- Choosing between multiple valid approaches.
|
|
28
|
+
- A fix "seems to work" but you can't explain why.
|
|
32
29
|
|
|
33
30
|
## Vague-request triggers — MUST ask
|
|
34
31
|
|
|
35
|
-
|
|
36
|
-
context → ask **before** touching code:
|
|
32
|
+
Match without further context → ask **before** touching code:
|
|
37
33
|
|
|
38
34
|
- "improve / optimize this" — metric? speed, readability, memory?
|
|
39
35
|
- "add caching" — store? scope? invalidation?
|
|
@@ -45,52 +41,33 @@ context → ask **before** touching code:
|
|
|
45
41
|
- "handle errors properly" — which errors? log/retry/propagate?
|
|
46
42
|
- "add a UI/component/tile/page" in mixed-framework repo — which stack?
|
|
47
43
|
|
|
48
|
-
|
|
49
|
-
[`asking-and-brevity-examples`](../../docs/guidelines/agent-infra/asking-and-brevity-examples.md#vague-request-triggers--example-questions).
|
|
44
|
+
Examples: [`asking-and-brevity-examples § vague-triggers`](../docs/guidelines/agent-infra/asking-and-brevity-examples.md#vague-request-triggers--example-questions).
|
|
50
45
|
|
|
51
|
-
**Escape hatch:**
|
|
52
|
-
the answer unambiguous, proceed — but state the assumption.
|
|
46
|
+
**Escape hatch:** unambiguous from ticket / open file / prior turn → proceed, state the assumption.
|
|
53
47
|
|
|
54
48
|
## How to ask
|
|
55
49
|
|
|
56
|
-
Numbered options (per `user-interaction`). Short.
|
|
57
|
-
the top; this section adds self-check and ordering.
|
|
58
|
-
|
|
59
|
-
The user must never track sub-numbers, scroll stacked option blocks,
|
|
60
|
-
or split a reply across multiple questions. Rationale shorthand: if
|
|
61
|
-
the user has to *think* about an answer, that answer almost always
|
|
62
|
-
reframes the next question. Full rationale:
|
|
63
|
-
[`asking-and-brevity-examples`](../../docs/guidelines/agent-infra/asking-and-brevity-examples.md#one-question-per-turn--why-serial-always-wins).
|
|
50
|
+
Numbered options (per [`user-interaction`](user-interaction.md)). Short.
|
|
64
51
|
|
|
65
52
|
### Self-check before asking
|
|
66
53
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
2. Does this turn present two or more separate numbered-option blocks?
|
|
71
|
-
3. Would the user need to reply with a structured answer (`1a, 2b`)
|
|
72
|
-
instead of a single number or word?
|
|
54
|
+
1. More than one `?` directed at the user this turn?
|
|
55
|
+
2. Two or more separate numbered-option blocks?
|
|
56
|
+
3. User would need a structured reply (`1a, 2b`) instead of a single number?
|
|
73
57
|
|
|
74
|
-
|
|
75
|
-
every other question for its own turn. No exceptions, no "but these
|
|
76
|
-
are related".
|
|
58
|
+
Any "yes" → **collapse to ONE question**. Hold the rest for their own turn. Rationale: [`asking-and-brevity-examples § serial-wins`](../docs/guidelines/agent-infra/asking-and-brevity-examples.md#one-question-per-turn--why-serial-always-wins).
|
|
77
59
|
|
|
78
60
|
### Ordering & handoff
|
|
79
61
|
|
|
80
|
-
- **Session handoff** (`/agent-handoff`, fresh-chat
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
- **Model switch**: different phase — [`model-recommendation`](model-recommendation.md)
|
|
85
|
-
triggers at task start with its own STOP-AND-WAIT gate, standalone, not
|
|
86
|
-
appended to a Q&A block. Do not conflate the two.
|
|
87
|
-
- **Blocking clarification** (can't proceed without it): ask FIRST,
|
|
88
|
-
alone, before any research or planning output.
|
|
89
|
-
- **Optional refinement**: don't ask at all — state the assumption
|
|
90
|
-
and proceed.
|
|
62
|
+
- **Session handoff** (`/agent-handoff`, fresh-chat) — ask LAST, after domain / clarifying questions, so answers fold into the handoff. Full: [`agent-interaction-and-decision-quality § handoff`](../docs/guidelines/agent-infra/agent-interaction-and-decision-quality.md#handoff--model-switch-questions).
|
|
63
|
+
- **Model switch** — [`model-recommendation`](model-recommendation.md) STOP-AND-WAIT gate is standalone, not appended.
|
|
64
|
+
- **Blocking clarification** — ask FIRST, alone, before any research or planning output.
|
|
65
|
+
- **Optional refinement** — don't ask; state the assumption, proceed.
|
|
91
66
|
|
|
92
67
|
## Creating new agent artifacts
|
|
93
68
|
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
69
|
+
Skill / rule / command / guideline creation or major rewrite → [`artifact-drafting-protocol`](artifact-drafting-protocol.md) (Understand → Research → Draft). Don't improvise questions.
|
|
70
|
+
|
|
71
|
+
## Examples
|
|
72
|
+
|
|
73
|
+
Pattern Memory (wrong / right / why): [`ask-when-uncertain-demos`](../docs/guidelines/agent-infra/ask-when-uncertain-demos.md). Outcome baseline: [`tests/golden/outcomes/ask_when_uncertain.json`](../../tests/golden/outcomes/ask_when_uncertain.json).
|