@event4u/agent-config 1.16.0 → 1.17.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-audit.md → agents/audit.md} +4 -3
- package/.agent-src/commands/{agents-cleanup.md → agents/cleanup.md} +12 -6
- package/.agent-src/commands/{agents-prepare.md → agents/prepare.md} +4 -3
- package/.agent-src/commands/agents.md +46 -0
- package/.agent-src/commands/{chat-history-checkpoint.md → chat-history/checkpoint.md} +4 -4
- package/.agent-src/commands/{chat-history-clear.md → chat-history/clear.md} +4 -4
- package/.agent-src/commands/{chat-history-resume.md → chat-history/resume.md} +4 -4
- package/.agent-src/commands/chat-history/show.md +107 -0
- package/.agent-src/commands/chat-history.md +33 -89
- package/.agent-src/commands/{commit-in-chunks.md → commit/in-chunks.md} +15 -13
- package/.agent-src/commands/commit.md +22 -2
- package/.agent-src/commands/{context-create.md → context/create.md} +4 -3
- package/.agent-src/commands/{context-refactor.md → context/refactor.md} +4 -3
- package/.agent-src/commands/context.md +44 -0
- package/.agent-src/commands/{copilot-agents-init.md → copilot-agents/init.md} +4 -3
- package/.agent-src/commands/{copilot-agents-optimize.md → copilot-agents/optimize.md} +4 -3
- package/.agent-src/commands/copilot-agents.md +44 -0
- package/.agent-src/commands/council/default.md +221 -0
- package/.agent-src/commands/{council-design.md → council/design.md} +6 -5
- package/.agent-src/commands/{council-optimize.md → council/optimize.md} +7 -6
- package/.agent-src/commands/{council-pr.md → council/pr.md} +6 -5
- package/.agent-src/commands/council.md +47 -212
- package/.agent-src/commands/{create-pr-description.md → create-pr/description-only.md} +4 -2
- package/.agent-src/commands/create-pr.md +26 -5
- package/.agent-src/commands/{feature-dev.md → feature/dev.md} +5 -10
- package/.agent-src/commands/{feature-explore.md → feature/explore.md} +4 -8
- package/.agent-src/commands/{feature-plan.md → feature/plan.md} +4 -8
- package/.agent-src/commands/{feature-refactor.md → feature/refactor.md} +4 -8
- package/.agent-src/commands/{feature-roadmap.md → feature/roadmap.md} +6 -10
- package/.agent-src/commands/feature.md +6 -12
- package/.agent-src/commands/{fix-ci.md → fix/ci.md} +4 -8
- package/.agent-src/commands/{fix-portability.md → fix/portability.md} +4 -8
- package/.agent-src/commands/{fix-pr-bot-comments.md → fix/pr-bots.md} +4 -8
- package/.agent-src/commands/{fix-pr-developer-comments.md → fix/pr-developers.md} +4 -8
- package/.agent-src/commands/{fix-pr-comments.md → fix/pr.md} +7 -11
- package/.agent-src/commands/{fix-references.md → fix/refs.md} +4 -8
- package/.agent-src/commands/{fix-seeder.md → fix/seeder.md} +4 -8
- package/.agent-src/commands/fix.md +7 -13
- package/.agent-src/commands/{do-and-judge.md → judge/on-diff.md} +4 -3
- package/.agent-src/commands/judge/solo.md +90 -0
- package/.agent-src/commands/{do-in-steps.md → judge/steps.md} +4 -3
- package/.agent-src/commands/judge.md +35 -70
- package/.agent-src/commands/{memory-add.md → memory/add.md} +4 -3
- package/.agent-src/commands/{memory-full.md → memory/load.md} +4 -3
- package/.agent-src/commands/{memory-promote.md → memory/promote.md} +4 -3
- package/.agent-src/commands/{propose-memory.md → memory/propose.md} +4 -3
- package/.agent-src/commands/memory.md +48 -0
- package/.agent-src/commands/{module-create.md → module/create.md} +4 -3
- package/.agent-src/commands/{module-explore.md → module/explore.md} +4 -3
- package/.agent-src/commands/module.md +44 -0
- package/.agent-src/commands/{optimize-agents.md → optimize/agents.md} +4 -8
- package/.agent-src/commands/{optimize-augmentignore.md → optimize/augmentignore.md} +4 -9
- package/.agent-src/commands/{optimize-rtk-filters.md → optimize/rtk.md} +4 -8
- package/.agent-src/commands/{optimize-skills.md → optimize/skills.md} +4 -8
- package/.agent-src/commands/optimize.md +4 -10
- package/.agent-src/commands/{override-create.md → override/create.md} +4 -3
- package/.agent-src/commands/{override-manage.md → override/manage.md} +4 -3
- package/.agent-src/commands/override.md +44 -0
- package/.agent-src/commands/{roadmap-create.md → roadmap/create.md} +4 -3
- package/.agent-src/commands/{roadmap-execute.md → roadmap/execute.md} +4 -3
- package/.agent-src/commands/roadmap.md +44 -0
- package/.agent-src/commands/{tests-create.md → tests/create.md} +4 -3
- package/.agent-src/commands/{tests-execute.md → tests/execute.md} +4 -3
- package/.agent-src/commands/tests.md +44 -0
- package/.agent-src/contexts/communication/rules-auto/artifact-engagement-recording-mechanics.md +72 -0
- package/.agent-src/contexts/communication/rules-auto/augment-portability-mechanics.md +79 -0
- package/.agent-src/contexts/communication/rules-auto/augment-source-of-truth-mechanics.md +98 -0
- package/.agent-src/contexts/communication/rules-auto/cli-output-handling-mechanics.md +87 -0
- package/.agent-src/contexts/communication/rules-auto/command-suggestion-policy-mechanics.md +62 -0
- package/.agent-src/contexts/communication/rules-auto/docs-sync-mechanics.md +78 -0
- package/.agent-src/contexts/communication/rules-auto/package-ci-checks-mechanics.md +85 -0
- package/.agent-src/contexts/communication/rules-auto/review-routing-awareness-mechanics.md +65 -0
- package/.agent-src/contexts/communication/rules-auto/roadmap-progress-sync-mechanics.md +78 -0
- package/.agent-src/contexts/communication/rules-auto/skill-quality-mechanics.md +62 -0
- package/.agent-src/contexts/communication/rules-auto/slash-command-routing-policy-mechanics.md +55 -0
- package/.agent-src/contexts/communication/rules-auto/ui-audit-gate-mechanics.md +53 -0
- package/.agent-src/contexts/communication/rules-auto/user-interaction-mechanics.md +77 -0
- package/.agent-src/contexts/judges/no-consolidate-rationale.md +102 -0
- package/.agent-src/contexts/judges/persona-voice-rubric.md +140 -0
- package/.agent-src/rules/artifact-engagement-recording.md +13 -69
- package/.agent-src/rules/ask-when-uncertain.md +27 -42
- package/.agent-src/rules/augment-portability.md +15 -61
- package/.agent-src/rules/augment-source-of-truth.md +27 -93
- package/.agent-src/rules/cli-output-handling.md +10 -76
- package/.agent-src/rules/command-suggestion-policy.md +18 -59
- package/.agent-src/rules/commit-conventions.md +17 -14
- package/.agent-src/rules/direct-answers.md +34 -49
- package/.agent-src/rules/docker-commands.md +5 -5
- package/.agent-src/rules/docs-sync.md +15 -69
- package/.agent-src/rules/language-and-tone.md +48 -72
- package/.agent-src/rules/missing-tool-handling.md +28 -22
- package/.agent-src/rules/no-cheap-questions.md +45 -52
- package/.agent-src/rules/no-roadmap-references.md +73 -0
- package/.agent-src/rules/package-ci-checks.md +21 -61
- package/.agent-src/rules/preservation-guard.md +64 -29
- package/.agent-src/rules/review-routing-awareness.md +24 -43
- package/.agent-src/rules/roadmap-progress-sync.md +10 -71
- package/.agent-src/rules/security-sensitive-stop.md +8 -8
- package/.agent-src/rules/skill-quality.md +16 -48
- package/.agent-src/rules/slash-command-routing-policy.md +7 -4
- package/.agent-src/rules/think-before-action.md +52 -42
- package/.agent-src/rules/tool-safety.md +19 -16
- package/.agent-src/rules/ui-audit-gate.md +24 -38
- package/.agent-src/rules/user-interaction.md +13 -68
- package/.agent-src/skills/ai-council/SKILL.md +2 -0
- package/.agent-src/skills/api-testing/SKILL.md +1 -1
- package/.agent-src/skills/check-refs/SKILL.md +59 -40
- package/.agent-src/skills/conventional-commits-writing/SKILL.md +86 -28
- package/.agent-src/skills/copilot-agents-optimization/SKILL.md +5 -5
- package/.agent-src/skills/developer-like-execution/SKILL.md +4 -4
- package/.agent-src/skills/finishing-a-development-branch/SKILL.md +101 -65
- package/.agent-src/skills/flux/SKILL.md +30 -10
- package/.agent-src/skills/github-ci/SKILL.md +2 -2
- package/.agent-src/skills/judge-code-quality/SKILL.md +7 -8
- package/.agent-src/skills/judge-security-auditor/SKILL.md +4 -5
- package/.agent-src/skills/judge-test-coverage/SKILL.md +3 -4
- package/.agent-src/skills/lint-skills/SKILL.md +57 -39
- package/.agent-src/skills/md-language-check/SKILL.md +61 -39
- package/.agent-src/skills/override-management/SKILL.md +5 -5
- package/.agent-src/skills/quality-tools/SKILL.md +2 -2
- package/.agent-src/skills/react-shadcn-ui/SKILL.md +116 -43
- package/.agent-src/skills/readme-reviewer/SKILL.md +30 -29
- package/.agent-src/skills/readme-writing/SKILL.md +78 -53
- package/.agent-src/skills/readme-writing-package/SKILL.md +50 -47
- package/.agent-src/skills/receiving-code-review/SKILL.md +52 -47
- package/.agent-src/skills/refine-prompt/SKILL.md +0 -1
- package/.agent-src/skills/requesting-code-review/SKILL.md +35 -30
- package/.agent-src/skills/security/SKILL.md +7 -2
- package/.agent-src/skills/security-audit/SKILL.md +7 -3
- package/.agent-src/skills/systematic-debugging/SKILL.md +68 -60
- package/.agent-src/skills/test-driven-development/SKILL.md +59 -57
- package/.agent-src/skills/test-performance/SKILL.md +0 -1
- package/.agent-src/skills/traefik/SKILL.md +4 -4
- package/.agent-src/skills/verify-completion-evidence/SKILL.md +28 -26
- package/.claude-plugin/marketplace.json +22 -11
- package/AGENTS.md +2 -2
- package/CHANGELOG.md +90 -1
- package/README.md +18 -17
- package/docs/architecture.md +4 -6
- package/docs/catalog.md +67 -39
- package/docs/contracts/STABILITY.md +13 -7
- package/docs/contracts/adr-chat-history-split.md +1 -3
- package/docs/contracts/adr-command-suggestion.md +0 -2
- package/docs/contracts/adr-implement-ticket-runtime.md +1 -2
- package/docs/contracts/adr-product-ui-track.md +3 -6
- package/docs/contracts/adr-prompt-driven-execution.md +3 -4
- package/docs/contracts/agent-memory-contract.md +6 -11
- package/docs/contracts/artifact-engagement-flow.md +6 -9
- package/docs/contracts/command-clusters.md +56 -46
- package/docs/contracts/command-suggestion-flow.md +1 -3
- package/docs/contracts/context-paths.md +99 -0
- package/docs/contracts/file-ownership-matrix.json +6722 -0
- package/docs/contracts/file-ownership-matrix.md +134 -0
- package/docs/contracts/implement-ticket-flow.md +6 -9
- package/docs/contracts/linear-ai-rules-inclusion.md +0 -1
- package/docs/contracts/linear-ai-three-layers.md +0 -2
- package/docs/contracts/load-context-budget-model.md +178 -0
- package/docs/contracts/load-context-schema.md +1 -3
- package/docs/contracts/rule-interactions.md +0 -1
- package/docs/contracts/rule-priority-hierarchy.md +1 -1
- package/docs/contracts/ui-track-flow.md +7 -17
- package/docs/customization.md +2 -0
- package/docs/getting-started.md +5 -4
- package/docs/guidelines/agent-infra/asking-and-brevity-examples.md +100 -0
- package/package.json +1 -1
- package/scripts/_one_off_phase4_dispatch_latency.py +108 -0
- package/scripts/_one_off_phase6_trigger_jaccard.py +92 -0
- package/scripts/_phase2_shim_helper.py +109 -0
- package/scripts/agent-config +10 -0
- package/scripts/ai_council/_one_off_2a4_acceptance.py +208 -0
- package/scripts/ai_council/_one_off_context_layer_v1_estimate.py +67 -0
- package/scripts/ai_council/_one_off_context_layer_v1_review.py +292 -0
- package/scripts/ai_council/_one_off_followups_review.py +259 -0
- package/scripts/ai_council/_one_off_nondestructive_inline_audit.py +209 -0
- package/scripts/ai_council/_one_off_phase_2a_budget_rebalance.py +257 -0
- package/scripts/ai_council/_one_off_phase_2a_post_revert.py +197 -0
- package/scripts/ai_council/_one_off_rule_hardening_v1.py +251 -0
- package/scripts/ai_council/_one_off_structural_open_questions.py +232 -0
- package/scripts/ai_council/_one_off_structural_optimization.py +144 -0
- package/scripts/ai_council/_one_off_structural_v3_gaps.py +252 -0
- package/scripts/ai_council/_one_off_structural_v3_review.py +240 -0
- package/scripts/check_always_budget.py +363 -45
- package/scripts/check_cluster_patterns.py +159 -0
- package/scripts/check_command_count_messaging.py +14 -7
- package/scripts/check_context_paths.py +201 -0
- package/scripts/check_no_roadmap_refs.py +155 -0
- package/scripts/check_phase_coupling.py +148 -0
- package/scripts/check_portability.py +2 -0
- package/scripts/check_references.py +29 -2
- package/scripts/check_safety_floor_untouched.py +125 -0
- package/scripts/command_suggester/loader.py +4 -1
- package/scripts/compress.py +59 -13
- package/scripts/generate_index.py +6 -2
- package/scripts/generate_ownership_matrix.py +323 -0
- package/scripts/hooks/augment-roadmap-progress.sh +57 -0
- package/scripts/install.py +49 -28
- package/scripts/lint_no_new_atomic_commands.py +12 -11
- package/scripts/requirements-evals.txt +1 -0
- package/scripts/roadmap_progress_hook.py +159 -0
- package/scripts/schemas/command.schema.json +4 -3
- package/scripts/skill_linter.py +1 -0
- package/scripts/sync_agent_settings.py +25 -2
- package/scripts/update_counts.py +7 -0
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
---
|
|
2
|
-
name: tests
|
|
2
|
+
name: tests:execute
|
|
3
|
+
cluster: tests
|
|
4
|
+
sub: execute
|
|
3
5
|
skills: [pest-testing]
|
|
4
6
|
description: Run PHP tests inside the Docker container
|
|
5
7
|
disable-model-invocation: true
|
|
@@ -9,8 +11,7 @@ suggestion:
|
|
|
9
11
|
trigger_context: "code changes pending verification"
|
|
10
12
|
---
|
|
11
13
|
|
|
12
|
-
# tests
|
|
13
|
-
|
|
14
|
+
# /tests execute
|
|
14
15
|
## Instructions
|
|
15
16
|
|
|
16
17
|
### 1. Detect the test runner
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: tests
|
|
3
|
+
description: Tests orchestrator — routes to create, execute
|
|
4
|
+
cluster: tests
|
|
5
|
+
disable-model-invocation: true
|
|
6
|
+
suggestion:
|
|
7
|
+
eligible: true
|
|
8
|
+
trigger_description: "write tests for these changes, run the test suite"
|
|
9
|
+
trigger_context: "user wants to author or run tests for the current branch"
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
# /tests
|
|
13
|
+
|
|
14
|
+
Top-level orchestrator for the `/tests` family. Replaces 2 standalone
|
|
15
|
+
commands with a single entry point + sub-command dispatch.
|
|
16
|
+
|
|
17
|
+
## Sub-commands
|
|
18
|
+
|
|
19
|
+
| Sub-command | Routes to | Purpose |
|
|
20
|
+
|---|---|---|
|
|
21
|
+
| `/tests create` | `commands/tests/create.md` | Write meaningful tests for the changes in the current branch |
|
|
22
|
+
| `/tests execute` | `commands/tests/execute.md` | Run PHP tests inside the Docker container |
|
|
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: `/tests <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. create — author tests for current-branch changes
|
|
36
|
+
> 2. execute — run the test suite in Docker
|
|
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 `/tests <sub>` per turn.
|
|
43
|
+
- If the user invokes `/tests` with no argument, **show the menu** — do
|
|
44
|
+
not guess which sub-command they meant.
|
package/.agent-src/contexts/communication/rules-auto/artifact-engagement-recording-mechanics.md
ADDED
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
# Artifact Engagement Recording — mechanics
|
|
2
|
+
|
|
3
|
+
CLI invocation, privacy contract, failure-mode handling, and "what
|
|
4
|
+
this rule does NOT do" catalog for the
|
|
5
|
+
[`artifact-engagement-recording`](../../../rules/artifact-engagement-recording.md)
|
|
6
|
+
rule. The activation gate, cadence table, and consulted-vs-applied
|
|
7
|
+
definitions live in the rule; this file is the lookup material for
|
|
8
|
+
the actual `telemetry:record` call and the privacy floor.
|
|
9
|
+
|
|
10
|
+
## What to record — id-only, no payload
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
./agent-config telemetry:record \
|
|
14
|
+
--task-id "$TASK_ID" \
|
|
15
|
+
--boundary task \
|
|
16
|
+
--consulted skills:php-coder \
|
|
17
|
+
--consulted skills:eloquent \
|
|
18
|
+
--consulted rules:scope-control \
|
|
19
|
+
--applied skills:php-coder \
|
|
20
|
+
--applied rules:scope-control
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
- `--task-id` — the ticket key (`PROJ-123`) for `/implement-ticket`, or a
|
|
24
|
+
short opaque slug derived from the prompt for `/work`. **Never** a
|
|
25
|
+
branch name, a file path, or a free-text title.
|
|
26
|
+
- `--boundary` — `task` or `phase-step`, matching the cadence in the rule.
|
|
27
|
+
- `--consulted <kind>:<id>` — repeat per artefact. `<kind>` is one of
|
|
28
|
+
`skills`, `rules`, `commands`, `guidelines`, `personas`.
|
|
29
|
+
- `--applied <kind>:<id>` — repeat per artefact actually applied.
|
|
30
|
+
- Exit `0` always when disabled (silent). Exit `1` on schema validation
|
|
31
|
+
failure (rule must NOT swallow this — surface to the user). Exit `2`
|
|
32
|
+
on IO failure.
|
|
33
|
+
|
|
34
|
+
## Privacy contract — what NEVER goes into a record
|
|
35
|
+
|
|
36
|
+
The CLI rejects most violations on the input boundary, but the agent must
|
|
37
|
+
not even attempt these:
|
|
38
|
+
|
|
39
|
+
- ❌ File paths (`src/Foo.php`, `tests/...`) — id fields are
|
|
40
|
+
artefact identifiers only.
|
|
41
|
+
- ❌ Source code, prompt text, ticket body, AC text.
|
|
42
|
+
- ❌ Branch names, commit shas, PR numbers, URLs.
|
|
43
|
+
- ❌ Secrets, env vars, credentials, customer data.
|
|
44
|
+
- ❌ Free-text strings longer than 200 chars (CLI enforces; agent must
|
|
45
|
+
not generate).
|
|
46
|
+
|
|
47
|
+
When in doubt → **don't record**. A missing event is cheap; a leaked
|
|
48
|
+
prompt is not.
|
|
49
|
+
|
|
50
|
+
## Failure modes — DO NOT block the user's task
|
|
51
|
+
|
|
52
|
+
- Schema rejection (CLI exit `1`) → log the message internally, continue
|
|
53
|
+
the user's task. Do **not** halt the dispatch loop.
|
|
54
|
+
- IO failure (CLI exit `2`) → same. The telemetry is **observation**, not
|
|
55
|
+
a delivery requirement.
|
|
56
|
+
- Settings malformed → already handled by the CLI: it falls back to
|
|
57
|
+
disabled and exits `0`. Agent treats it as "disabled this task".
|
|
58
|
+
|
|
59
|
+
The only error the agent surfaces is when the user explicitly asked for
|
|
60
|
+
recording (`telemetry:status` confirms enabled) but no event reached the
|
|
61
|
+
log — that is a real bug, not a swallowed error.
|
|
62
|
+
|
|
63
|
+
## What this rule does NOT do
|
|
64
|
+
|
|
65
|
+
- Run when `enabled: false` (cost floor is zero — see
|
|
66
|
+
[`tests/telemetry/test_cost_floor.py`](../../../../tests/telemetry/test_cost_floor.py)).
|
|
67
|
+
- Track the agent's tool calls, file reads, or token spend — that is
|
|
68
|
+
out of scope, see the roadmap's "out-of-scope" section.
|
|
69
|
+
- Decide retirement. Phase 4's aggregator + report renderer are the only
|
|
70
|
+
consumers that may interpret the JSONL.
|
|
71
|
+
- Run on cloud surfaces (Claude.ai Web, Skills API). The
|
|
72
|
+
`cloud_safe: noop` marker keeps it inert there.
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
# Augment portability — mechanics
|
|
2
|
+
|
|
3
|
+
`task`-to-script translation table, the `./agent-config` consumer-CLI
|
|
4
|
+
table, and the rationale behind both for the
|
|
5
|
+
[`augment-portability`](../../../rules/augment-portability.md) rule.
|
|
6
|
+
The portability obligation, the agnostic-content rules, and the
|
|
7
|
+
enforcement script reference live in the rule; this file is the
|
|
8
|
+
lookup material when an agent is about to write or edit an artefact
|
|
9
|
+
that mentions a runtime invocation.
|
|
10
|
+
|
|
11
|
+
## Why no `task` commands inside artefacts
|
|
12
|
+
|
|
13
|
+
Skills, rules, commands, guidelines, personas, and context docs
|
|
14
|
+
shipped by this package run in **consumer projects**. Consumer
|
|
15
|
+
projects may not have [Task](https://taskfile.dev) installed —
|
|
16
|
+
they might use npm scripts, Composer scripts, Make, or nothing at
|
|
17
|
+
all. A skill that instructs an agent to run `task <something>`
|
|
18
|
+
silently breaks in every project without a `Taskfile.yml`.
|
|
19
|
+
|
|
20
|
+
Task remains a convenience shortcut for maintainers working on the
|
|
21
|
+
package repo itself — `task ci` is the recommended local gate before
|
|
22
|
+
a PR and lives in `Taskfile.yml`, `AGENTS.md`, and the package README.
|
|
23
|
+
Those maintainer-facing surfaces are outside the scope of this rule.
|
|
24
|
+
Artefact files must assume Task is absent.
|
|
25
|
+
|
|
26
|
+
The detection pattern *"if the consumer has a `Makefile` / build
|
|
27
|
+
script, prefer its targets over raw commands"* is still allowed when
|
|
28
|
+
the skill adapts to the **consumer's own** tooling (e.g.
|
|
29
|
+
`tests-execute` detecting `php artisan test` vs `vendor/bin/pest`).
|
|
30
|
+
It is not allowed to reference `task <name>` as the detected target —
|
|
31
|
+
every direct invocation must resolve to a real script path.
|
|
32
|
+
|
|
33
|
+
## Translation table — `task` → script
|
|
34
|
+
|
|
35
|
+
| ❌ Forbidden | ✅ Portable |
|
|
36
|
+
|---|---|
|
|
37
|
+
| `task sync` | `bash scripts/compress.sh --sync` |
|
|
38
|
+
| `task sync-check` | `bash scripts/compress.sh --check` |
|
|
39
|
+
| `task sync-check-hashes` | `bash scripts/compress.sh --check-hashes` |
|
|
40
|
+
| `task sync-changed` | `bash scripts/compress.sh --changed` |
|
|
41
|
+
| `task sync-mark-done -- X` | `bash scripts/compress.sh --mark-done X` |
|
|
42
|
+
| `task generate-tools` | `python3 scripts/compress.py --generate-tools` |
|
|
43
|
+
| `task lint-skills` | `python3 scripts/skill_linter.py --all` |
|
|
44
|
+
| `task check-refs` | `python3 scripts/check_references.py` |
|
|
45
|
+
| `task check-portability` | `python3 scripts/check_portability.py` |
|
|
46
|
+
| `task check-compression` | `python3 scripts/check_compression.py` |
|
|
47
|
+
| `task validate-schema` | `python3 scripts/validate_frontmatter.py` |
|
|
48
|
+
| `task counts-check` | `python3 scripts/update_counts.py --check` |
|
|
49
|
+
| `task roadmap-progress` | `./agent-config roadmap:progress` |
|
|
50
|
+
| `task ci` | run each underlying script directly (no single portable equivalent) |
|
|
51
|
+
|
|
52
|
+
## Consumer CLI — `./agent-config`
|
|
53
|
+
|
|
54
|
+
A subset of package scripts is exposed through a project-local CLI
|
|
55
|
+
wrapper `./agent-config` (written into the project root by the
|
|
56
|
+
installer, gitignored). Artefacts MUST prefer the CLI over raw
|
|
57
|
+
`python3 scripts/…` paths for every command the CLI already covers,
|
|
58
|
+
because the raw paths only resolve inside the package repo — in a
|
|
59
|
+
consumer project the scripts live under `node_modules/` or `vendor/`.
|
|
60
|
+
|
|
61
|
+
| ❌ Forbidden in artefacts | ✅ Portable |
|
|
62
|
+
|---|---|
|
|
63
|
+
| `python3 scripts/mcp_render.py` | `./agent-config mcp:render` |
|
|
64
|
+
| `python3 scripts/mcp_render.py --check` | `./agent-config mcp:check` |
|
|
65
|
+
| `python3 .augment/scripts/update_roadmap_progress.py` | `./agent-config roadmap:progress` |
|
|
66
|
+
| `python3 .augment/scripts/update_roadmap_progress.py --check` | `./agent-config roadmap:progress-check` |
|
|
67
|
+
| `bash scripts/first-run.sh` | `./agent-config first-run` |
|
|
68
|
+
| `PYTHONPATH=… python3 -m implement_ticket` | `./agent-config implement-ticket` |
|
|
69
|
+
| `python3 scripts/memory_lookup.py` | `./agent-config memory:lookup` |
|
|
70
|
+
| `python3 scripts/memory_signal.py` | `./agent-config memory:signal` |
|
|
71
|
+
| `python3 scripts/memory_hash.py` | `./agent-config memory:hash` |
|
|
72
|
+
| `python3 scripts/check_memory.py` | `./agent-config memory:check` |
|
|
73
|
+
| `python3 scripts/check_memory_proposal.py` | `./agent-config memory:check-proposal` |
|
|
74
|
+
| `python3 scripts/check_proposal.py` | `./agent-config proposal:check` |
|
|
75
|
+
| `python3 scripts/refine_ticket_detect.py` | `./agent-config refine-ticket:detect` |
|
|
76
|
+
|
|
77
|
+
Commands not covered by the CLI stay as direct script invocations
|
|
78
|
+
(e.g. `bash scripts/compress.sh --sync`) — those are maintainer-only
|
|
79
|
+
and not reachable from a consumer project anyway.
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
# Source of Truth — mechanics
|
|
2
|
+
|
|
3
|
+
Workflow, compression rules, commands workflow, symlink mapping, and
|
|
4
|
+
quick reference for the
|
|
5
|
+
[`augment-source-of-truth`](../../../rules/augment-source-of-truth.md)
|
|
6
|
+
rule. The Iron Rule and the "never edit generated layers" obligation
|
|
7
|
+
live in the rule; this file is the lookup material the rule pulls
|
|
8
|
+
when authoring or pre-review verification fires.
|
|
9
|
+
|
|
10
|
+
## Workflow
|
|
11
|
+
|
|
12
|
+
1. **Create or edit** the file in `.agent-src.uncompressed/{path}`
|
|
13
|
+
2. **Do NOT auto-compress.** Continue working.
|
|
14
|
+
3. **Before commit/push:** Check if compression is needed
|
|
15
|
+
(`bash scripts/compress.sh --changed`). If files need compression,
|
|
16
|
+
ask the user:
|
|
17
|
+
```
|
|
18
|
+
> 📦 {N} .agent-src files need compression before commit.
|
|
19
|
+
>
|
|
20
|
+
> 1. Compress now — run /compress
|
|
21
|
+
> 2. Later — commit without compression
|
|
22
|
+
```
|
|
23
|
+
4. If compressing: run `/compress` command, then
|
|
24
|
+
`bash scripts/compress.sh --mark-done {path}`
|
|
25
|
+
|
|
26
|
+
For new non-.md files (`.php`, configs):
|
|
27
|
+
`bash scripts/compress.sh --sync` copies them automatically.
|
|
28
|
+
|
|
29
|
+
**Key change:** Compression happens once before commit/push — not after every edit.
|
|
30
|
+
This avoids interruptions when work is still in progress.
|
|
31
|
+
|
|
32
|
+
## What "compress" means
|
|
33
|
+
|
|
34
|
+
- Remove articles (a, an, the), filler, hedging, connective fluff
|
|
35
|
+
- Shorten phrases: "in order to" → "to", "make sure to" → "ensure"
|
|
36
|
+
- Fragments OK: "Run tests before commit" not "You should always run tests before committing"
|
|
37
|
+
- Merge redundant bullets
|
|
38
|
+
|
|
39
|
+
## What NEVER changes during compression
|
|
40
|
+
|
|
41
|
+
- Code blocks, inline code, URLs, file paths, commands
|
|
42
|
+
- Headings (exact text preserved)
|
|
43
|
+
- Tables (structure preserved, compress cell text only)
|
|
44
|
+
- YAML frontmatter
|
|
45
|
+
- Technical terms, library names, API names
|
|
46
|
+
- Strong language: "NEVER", "MUST", "Do NOT" — these are load-bearing
|
|
47
|
+
|
|
48
|
+
## Commands workflow
|
|
49
|
+
|
|
50
|
+
Commands live in `.agent-src.uncompressed/commands/{name}.md` (single source of truth).
|
|
51
|
+
Claude Code reads them via symlinks in `.claude/skills/{name}/SKILL.md`.
|
|
52
|
+
|
|
53
|
+
**Required frontmatter for commands:**
|
|
54
|
+
|
|
55
|
+
```yaml
|
|
56
|
+
name: {command-name}
|
|
57
|
+
description: {what it does}
|
|
58
|
+
disable-model-invocation: true
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
- `name` and `disable-model-invocation: true` are required for Claude Code compatibility
|
|
62
|
+
- Augment ignores unknown frontmatter fields — no conflict
|
|
63
|
+
- Template: `.agent-src.uncompressed/templates/command.md`
|
|
64
|
+
|
|
65
|
+
**Creating a new command:**
|
|
66
|
+
|
|
67
|
+
1. Create `.agent-src.uncompressed/commands/{name}.md` (use template)
|
|
68
|
+
2. Run `python3 scripts/skill_linter.py` — must be 0 FAIL
|
|
69
|
+
3. Compress via `/compress`, which writes to `.agent-src/commands/`
|
|
70
|
+
4. Run `python3 scripts/compress.py --generate-tools` — creates Claude symlink automatically
|
|
71
|
+
|
|
72
|
+
**Never** create `.claude/skills/{name}/SKILL.md` manually for commands — always use the symlink workflow.
|
|
73
|
+
|
|
74
|
+
## Multi-agent symlink mapping
|
|
75
|
+
|
|
76
|
+
`.claude/skills/` contains symlinks to **both** `.agent-src/skills/` and `.agent-src/commands/`.
|
|
77
|
+
Claude Code treats both as "skills" — but they are different artifact types in our taxonomy.
|
|
78
|
+
|
|
79
|
+
| `.claude/skills/{name}/SKILL.md` points to... | Actual type |
|
|
80
|
+
|---|---|
|
|
81
|
+
| `.agent-src/skills/{name}/SKILL.md` | **Skill** (workflow) |
|
|
82
|
+
| `.agent-src/commands/{name}.md` | **Command** (slash-invoked procedure) |
|
|
83
|
+
|
|
84
|
+
Always check the symlink target to determine the actual artifact type.
|
|
85
|
+
Commands have `disable-model-invocation: true` in their frontmatter.
|
|
86
|
+
|
|
87
|
+
## Quick reference
|
|
88
|
+
|
|
89
|
+
| Task | What to do |
|
|
90
|
+
|---|---|
|
|
91
|
+
| Edit existing file | Edit in `.agent-src.uncompressed/`, compress to `.agent-src/` |
|
|
92
|
+
| Create new `.md` | Create in `.agent-src.uncompressed/`, compress to `.agent-src/` |
|
|
93
|
+
| Create new non-`.md` | Create in `.agent-src.uncompressed/`, run `bash scripts/compress.sh --sync` |
|
|
94
|
+
| Create new command | Create in `.agent-src.uncompressed/commands/`, sync, `python3 scripts/compress.py --generate-tools` |
|
|
95
|
+
| Delete a file | Delete from `.agent-src.uncompressed/` and `.agent-src/` |
|
|
96
|
+
| Check what needs compression | `bash scripts/compress.sh --changed` |
|
|
97
|
+
| Mark file as compressed | `bash scripts/compress.sh --mark-done {path}` |
|
|
98
|
+
| Verify everything is in sync | `bash scripts/compress.sh --check` |
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
# CLI output handling — mechanics
|
|
2
|
+
|
|
3
|
+
Codebase navigation tips, the redirect-summarize-target fallback
|
|
4
|
+
pattern, the general rules around exit codes / summary lines, and the
|
|
5
|
+
CLI-over-MCP catalog for the
|
|
6
|
+
[`cli-output-handling`](../../../rules/cli-output-handling.md) rule.
|
|
7
|
+
The Iron Law, the detection rule (`rtk_installed`), the verbose-command
|
|
8
|
+
table, and the exceptions list live in the rule; this file is the
|
|
9
|
+
lookup material when the agent has to fall back from `rtk`.
|
|
10
|
+
|
|
11
|
+
## Codebase Navigation
|
|
12
|
+
|
|
13
|
+
### Use what you already have
|
|
14
|
+
|
|
15
|
+
- Edited a file → the edit tool already returned the result. Skip re-reading.
|
|
16
|
+
- Ran a command → you have the output. Skip re-running to "verify".
|
|
17
|
+
- File in context from recent messages → skip reloading.
|
|
18
|
+
- Found a symbol → use it. Skip searching again differently.
|
|
19
|
+
|
|
20
|
+
### Search before reading
|
|
21
|
+
|
|
22
|
+
- **Search first** — `codebase-retrieval`, `search_query_regex`, or `grep`.
|
|
23
|
+
- **Load only what you need** — use `view_range` or `search_query_regex`, not full files.
|
|
24
|
+
- **Small files** (< 50 lines) — OK to read fully.
|
|
25
|
+
|
|
26
|
+
### Ignored files (`.augmentignore`)
|
|
27
|
+
|
|
28
|
+
- `vendor/`, `node_modules/`, lock files, and generated files are excluded from `codebase-retrieval`.
|
|
29
|
+
- When you need to understand a vendor package (base class, interface, API), **read the specific file** with `view`. This bypasses the ignore.
|
|
30
|
+
- Load only the file you need — never browse entire vendor directories.
|
|
31
|
+
|
|
32
|
+
### Minimize tool calls
|
|
33
|
+
|
|
34
|
+
- **Parallel reads** — read multiple files in one batch, not sequentially.
|
|
35
|
+
- **`search_query_regex`** over full file reads.
|
|
36
|
+
- **`view_range`** when you know the exact lines.
|
|
37
|
+
- **One `codebase-retrieval` call** with all symbols — batch, not 5 separate calls.
|
|
38
|
+
|
|
39
|
+
## Fallback Pattern: Redirect, Summarize, Target
|
|
40
|
+
|
|
41
|
+
When `rtk` has no matching subcommand for the tool at hand, fall back to
|
|
42
|
+
this pattern. Every command that MAY produce more than ~30 lines of output:
|
|
43
|
+
|
|
44
|
+
### Step 1: Redirect to file
|
|
45
|
+
```bash
|
|
46
|
+
docker compose exec -T <service> <command> 2>&1 > /tmp/<tool>-output.txt
|
|
47
|
+
echo "EXIT=$?"
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
### Step 2: Read ONLY the summary
|
|
51
|
+
```bash
|
|
52
|
+
tail -5 /tmp/<tool>-output.txt
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
### Step 3: If errors exist, read ONLY what you need to fix
|
|
56
|
+
```bash
|
|
57
|
+
grep "ERROR\|error\|✏️" /tmp/<tool>-output.txt | head -20
|
|
58
|
+
grep "app/Services/MyService.php" /tmp/<tool>-output.txt
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
**NEVER** do:
|
|
62
|
+
- `cat /tmp/<tool>-output.txt` (loads everything)
|
|
63
|
+
- Read the full output of a passing command (waste)
|
|
64
|
+
- Read diffs you don't plan to act on
|
|
65
|
+
|
|
66
|
+
## General Rules
|
|
67
|
+
|
|
68
|
+
For tool-specific commands → see the `quality-tools` skill.
|
|
69
|
+
|
|
70
|
+
1. **Exit code first**: Check `$?` before reading ANY output. If 0, you're done — skip reading.
|
|
71
|
+
2. **Summary line**: Most tools print a summary as the last few lines. That's all you need.
|
|
72
|
+
3. **Targeted grep**: When you need details, `grep` for the specific file or error type.
|
|
73
|
+
4. **Read once, act, move on**: Once you've read output and acted on it, skip re-reading.
|
|
74
|
+
5. **Iterative fixing**: Fix one error at a time, re-run, check exit code.
|
|
75
|
+
Output becomes stale after each fix — always re-run before reading again.
|
|
76
|
+
|
|
77
|
+
## CLI Over MCP
|
|
78
|
+
|
|
79
|
+
MCP servers are **significantly more token-expensive** than CLI equivalents.
|
|
80
|
+
When both options exist, prefer the CLI tool.
|
|
81
|
+
|
|
82
|
+
- **Git**: `git` CLI, not Git MCP
|
|
83
|
+
- **Files**: shell commands, not filesystem MCP
|
|
84
|
+
- **APIs**: `curl`/`httpie`, not HTTP MCP
|
|
85
|
+
- **Database**: `mysql`/`psql` CLI, not DB MCP
|
|
86
|
+
|
|
87
|
+
Exception: MCPs with **unique capabilities** (Sentry, Playwright, Jira).
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
# Command Suggestion — mechanics
|
|
2
|
+
|
|
3
|
+
Output format, anti-noise specifics, and "what this rule does NOT do"
|
|
4
|
+
catalog for the
|
|
5
|
+
[`command-suggestion-policy`](../../../rules/command-suggestion-policy.md)
|
|
6
|
+
rule. The Iron Law (suggest, never invoke), the six-condition fire
|
|
7
|
+
gate, and the subordination list live in the rule; this file is the
|
|
8
|
+
lookup material for the rendered output and engine behavior.
|
|
9
|
+
|
|
10
|
+
## What to emit — exact format
|
|
11
|
+
|
|
12
|
+
Render exactly one numbered-options block conforming to
|
|
13
|
+
`user-interaction`:
|
|
14
|
+
|
|
15
|
+
```
|
|
16
|
+
> 💡 Your request matches a command. Pick one or run the prompt as-is:
|
|
17
|
+
>
|
|
18
|
+
> 1. /implement-ticket — drive ticket end-to-end through refine → plan → implement → test
|
|
19
|
+
> 2. /refine-ticket — tighten the AC and risks on a ticket before planning
|
|
20
|
+
> 3. Just run the prompt as-is, no command
|
|
21
|
+
|
|
22
|
+
**Recommendation: 1 — /implement-ticket** — the request matches its trigger description (`setze ticket abc-123 um`). Pick the last option to skip the command and run the prompt as written.
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
Rules — non-negotiable:
|
|
26
|
+
|
|
27
|
+
- The "run as-is" option is **always present**, **always last**, never removed.
|
|
28
|
+
- At most `commands.suggestion.max_options` command suggestions
|
|
29
|
+
precede the as-is option (default 4 → 5 total).
|
|
30
|
+
- Exactly **one** `Recommendation:` line follows the block, naming
|
|
31
|
+
the highest-scoring command — or no recommendation when the top
|
|
32
|
+
two scores are within 0.05 of each other (single-source-of-truth
|
|
33
|
+
Iron Law from `user-interaction`).
|
|
34
|
+
- Free-text replies count as the as-is option unless they
|
|
35
|
+
unambiguously name one of the listed commands.
|
|
36
|
+
|
|
37
|
+
## Anti-noise — silent when uncertain
|
|
38
|
+
|
|
39
|
+
The engine's `rank.py` already drops:
|
|
40
|
+
|
|
41
|
+
- Matches below the `confidence_floor` (default 0.6, per-command
|
|
42
|
+
override in frontmatter).
|
|
43
|
+
- Single matches scoring `< floor + 0.1` with no structural bonus
|
|
44
|
+
(high uncertainty isn't worth interrupting for).
|
|
45
|
+
- Short prompts (< 6 words) hitting > 2 commands with no structural
|
|
46
|
+
bonus (ticket key, file path) — too vague to disambiguate.
|
|
47
|
+
- Pure-continuation messages (`ok`, `weiter`, `mach weiter`, `go on`,
|
|
48
|
+
…) — no new intent signal, no structural bonus → silent.
|
|
49
|
+
- Suggestions that fired for the same `(command, evidence)` pair
|
|
50
|
+
within the cooldown window (default 10m, per-command override).
|
|
51
|
+
|
|
52
|
+
If the engine returns an empty list → emit nothing. The user's
|
|
53
|
+
prompt runs exactly as it would without this rule.
|
|
54
|
+
|
|
55
|
+
## What this rule does NOT do
|
|
56
|
+
|
|
57
|
+
- Invoke any command. Picking option N is what triggers `slash-command-routing-policy`.
|
|
58
|
+
- Stack with other questions. One numbered-options block per turn.
|
|
59
|
+
- Re-trigger on its own output. Command names emitted in the
|
|
60
|
+
suggestion block are excluded from the next-turn matcher input.
|
|
61
|
+
- Override `enabled: false`, blocklist entries, or per-conversation opt-out.
|
|
62
|
+
- Suggest commands that are not in the locked eligibility table.
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
# Docs Sync — mechanics
|
|
2
|
+
|
|
3
|
+
Update tables, distribution manifests, hook registries, and content
|
|
4
|
+
consistency check details for the
|
|
5
|
+
[`docs-sync`](../../../rules/docs-sync.md) rule. The Iron Rule, the
|
|
6
|
+
mandatory sequence, the two modes (reactive/proactive), the
|
|
7
|
+
settings-template sync, and the "Do NOT" list live in the rule; this
|
|
8
|
+
file is the lookup material when a sync trigger fires.
|
|
9
|
+
|
|
10
|
+
## What to update — count and category tables
|
|
11
|
+
|
|
12
|
+
When a file is **added, removed, or renamed**:
|
|
13
|
+
|
|
14
|
+
| Change | Files to update |
|
|
15
|
+
|---|---|
|
|
16
|
+
| Skill/command/rule count changes | `contexts/augment-infrastructure.md` (count + category table) |
|
|
17
|
+
| New skill category | `contexts/augment-infrastructure.md` + `contexts/skills-and-commands.md` |
|
|
18
|
+
| New workflow chain | `contexts/skills-and-commands.md` (workflow chains section) |
|
|
19
|
+
|
|
20
|
+
## Cross-reference updates
|
|
21
|
+
|
|
22
|
+
When a skill is **added or its scope changes**, check and update:
|
|
23
|
+
|
|
24
|
+
| What | Where to check |
|
|
25
|
+
|---|---|
|
|
26
|
+
| Inline routing hints | "see X skill" or "use X instead" references in other skills |
|
|
27
|
+
| Guideline cross-references | Guidelines that reference the changed skill |
|
|
28
|
+
| Command skill references | Commands that use the changed skill |
|
|
29
|
+
|
|
30
|
+
## Distribution manifests and hook registries
|
|
31
|
+
|
|
32
|
+
`.augment/`-internal sync (counts, contexts, cross-refs) is one half. The
|
|
33
|
+
other half is **distribution manifests** that ship the package to consumers
|
|
34
|
+
and **hook registries** that wire engine code into platform lifecycles.
|
|
35
|
+
These are not auto-derived — they drift silently until CI catches them, and
|
|
36
|
+
on cooperative platforms (no pre-commit) they can sit broken in a branch
|
|
37
|
+
for hours.
|
|
38
|
+
|
|
39
|
+
When a **skill** is added, renamed, or deleted under
|
|
40
|
+
`.agent-src.uncompressed/skills/`:
|
|
41
|
+
|
|
42
|
+
| Manifest | Required update |
|
|
43
|
+
|---|---|
|
|
44
|
+
| `.claude-plugin/marketplace.json` | Add/remove the `./.claude/skills/<name>` entry in `plugins[0].skills[]`, alphabetical position. Caught by `scripts/lint_marketplace.py` in CI. |
|
|
45
|
+
| `.augment-plugin/marketplace.json` | Skill-name-agnostic — no update needed. Touch only when plugin metadata (description, tags) changes. |
|
|
46
|
+
| `.github/plugin/marketplace.json` | Same as above — metadata-only manifest. |
|
|
47
|
+
|
|
48
|
+
When a **hook** is added, renamed, or deleted under
|
|
49
|
+
`.agent-src.uncompressed/templates/scripts/work_engine/hooks/builtin/`:
|
|
50
|
+
|
|
51
|
+
| Registry | Required update |
|
|
52
|
+
|---|---|
|
|
53
|
+
| `templates/scripts/work_engine/hooks/builtin/__init__.py` | New hook class → add the import + `__all__` entry. Single source of truth for engine-side registration. |
|
|
54
|
+
| `templates/consumer-settings/claude-settings.json` | Only when a **new platform event** is wired (e.g. first time a hook listens on `SessionEnd`). Existing hooks reuse the `./agent-config chat-history:hook --platform claude` dispatcher — no per-hook entry needed. |
|
|
55
|
+
| `templates/consumer-settings/augment-cli-hooks.json` | Same logic — new platform event → new `command` block; new hook on existing event → no update. |
|
|
56
|
+
|
|
57
|
+
Failure mode that motivated this section: a skill on disk without its
|
|
58
|
+
`marketplace.json` entry passes local edits, builds, and tests — only
|
|
59
|
+
CI catches it via `lint_marketplace`. The cooperative path is
|
|
60
|
+
"agent updates the manifest in the same response as the skill"; the
|
|
61
|
+
structural backstop is a pre-commit hook installed by
|
|
62
|
+
`scripts/install-hooks.sh` that runs `lint_marketplace` on every
|
|
63
|
+
commit. Run the installer once per clone; bypass for an unrelated WIP
|
|
64
|
+
commit is `git commit --no-verify`.
|
|
65
|
+
|
|
66
|
+
## Content consistency check
|
|
67
|
+
|
|
68
|
+
When a rule, skill, or guideline's **content** is changed (not just
|
|
69
|
+
metadata), search for all other artefacts that cover the same topic
|
|
70
|
+
and verify they are consistent:
|
|
71
|
+
|
|
72
|
+
```bash
|
|
73
|
+
grep -rl "TOPIC" .augment/rules/ .augment/skills/ .augment/guidelines/ --include="*.md"
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
If any file contradicts or is missing the updated information →
|
|
77
|
+
update it in the same response. Inconsistent documentation is worse
|
|
78
|
+
than no documentation.
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
# Package CI checks — mechanics
|
|
2
|
+
|
|
3
|
+
The five required local-CI checks, the quick one-liner, and the
|
|
4
|
+
post-edit workflow rules for the
|
|
5
|
+
[`package-ci-checks`](../../../rules/package-ci-checks.md) rule. The
|
|
6
|
+
Iron Law, the activation trigger, and the "Do NOT" list live in the
|
|
7
|
+
rule; this file is the lookup material when an agent is about to
|
|
8
|
+
push or open a PR in the `agent-config` package repo.
|
|
9
|
+
|
|
10
|
+
## Required checks (in order)
|
|
11
|
+
|
|
12
|
+
Run all of these before pushing — they match the GitHub Actions workflows exactly:
|
|
13
|
+
|
|
14
|
+
### 1. Sync check
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
bash scripts/compress.sh --check # .agent-src/ matches .agent-src.uncompressed/
|
|
18
|
+
bash scripts/compress.sh --check-hashes # compression hashes are clean
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
**Common failure:** Edited uncompressed file but forgot `bash scripts/compress.sh --mark-done {path}`.
|
|
22
|
+
|
|
23
|
+
### 2. Consistency checks
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
python3 scripts/check_compression.py # compressed variants are valid
|
|
27
|
+
python3 scripts/check_references.py # no broken cross-references
|
|
28
|
+
python3 scripts/check_portability.py # no project-specific references in shared files
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
**Common failure:** Changed code-blocks in uncompressed but didn't re-compress.
|
|
32
|
+
|
|
33
|
+
### 3. Linter
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
python3 scripts/skill_linter.py --all # 0 FAIL required
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
**Common failure:** New skill missing analysis/verification sections.
|
|
40
|
+
|
|
41
|
+
### 4. Tests
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
python3 -m pytest tests/ --tb=short # all tests must pass
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
**Common failure:** Changed `compress.py` behavior without updating test expectations.
|
|
48
|
+
|
|
49
|
+
### 5. README
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
python3 scripts/readme_linter.py README.md --root .
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
## Quick one-liner
|
|
56
|
+
|
|
57
|
+
Run all checks in sequence — stops on first failure:
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
bash scripts/compress.sh --check && \
|
|
61
|
+
bash scripts/compress.sh --check-hashes && \
|
|
62
|
+
python3 scripts/check_compression.py && \
|
|
63
|
+
python3 scripts/check_references.py && \
|
|
64
|
+
python3 scripts/check_portability.py && \
|
|
65
|
+
python3 scripts/skill_linter.py --all && \
|
|
66
|
+
python3 -m pytest tests/ --tb=short && \
|
|
67
|
+
python3 scripts/readme_linter.py README.md --root .
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
## After editing skills/rules
|
|
71
|
+
|
|
72
|
+
When you edit a file in `.agent-src.uncompressed/`:
|
|
73
|
+
|
|
74
|
+
1. Edit the uncompressed file
|
|
75
|
+
2. Edit the compressed file in `.agent-src/` to match
|
|
76
|
+
3. Run `bash scripts/compress.sh --mark-done {relative-path}` to update the hash
|
|
77
|
+
4. Verify with `bash scripts/compress.sh --check-hashes`
|
|
78
|
+
|
|
79
|
+
**If you skip step 3, the CI pipeline WILL fail.**
|
|
80
|
+
|
|
81
|
+
## After editing `scripts/compress.py`
|
|
82
|
+
|
|
83
|
+
Changes to `compress.py` often break existing tests in `tests/test_compress.py`.
|
|
84
|
+
Always run `python3 -m pytest tests/test_compress.py -v --tb=short` immediately
|
|
85
|
+
after changing `compress.py` — don't wait until the end.
|