@event4u/agent-config 8.3.0 → 8.4.1
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/.claude-plugin/marketplace.json +4 -426
- package/.claude-plugin/skills/install-agent-config/SKILL.md +32 -0
- package/CHANGELOG.md +25 -0
- package/dist/agent-src/templates/agents/agent-project-settings.example.yml +1 -1
- package/dist/cli/registry.js +1 -0
- package/dist/cli/registry.js.map +1 -1
- package/dist/discovery/deprecation-report.md +1 -1
- package/dist/discovery/discovery-manifest.json +1 -1
- package/dist/discovery/discovery-manifest.json.sha256 +1 -1
- package/dist/discovery/discovery-manifest.summary.md +1 -1
- package/dist/discovery/orphan-report.md +1 -1
- package/dist/discovery/packs.json +1 -1
- package/dist/discovery/trust-report.md +1 -1
- package/dist/discovery/workspaces.json +1 -1
- package/dist/mcp/registry-manifest.json +1 -1
- package/docs/contracts/surface-matrix.md +103 -0
- package/package.json +4 -1
- package/src/agent-src/README.md +64 -0
- package/src/agent-src/scripts/archive_completed_roadmaps.ts +497 -0
- package/src/agent-src/scripts/scan-seeder-violations.php +145 -0
- package/src/agent-src/scripts/update_roadmap_progress.ts +1087 -0
- package/src/agent-src/templates/AGENTS.md +34 -0
- package/src/agent-src/templates/scripts/README.md +195 -0
- package/src/agent-src/templates/scripts/check_memory.ts +662 -0
- package/src/agent-src/templates/scripts/check_memory_proposal.ts +370 -0
- package/src/agent-src/templates/scripts/historical-bug-patterns.example.yml +84 -0
- package/src/agent-src/templates/scripts/implement_ticket/__main__.ts +27 -0
- package/src/agent-src/templates/scripts/memory_hash.ts +355 -0
- package/src/agent-src/templates/scripts/memory_lookup.ts +1089 -0
- package/src/agent-src/templates/scripts/memory_report.ts +868 -0
- package/src/agent-src/templates/scripts/memory_signal.ts +444 -0
- package/src/agent-src/templates/scripts/memory_status.ts +215 -0
- package/src/agent-src/templates/scripts/ownership-map.example.yml +87 -0
- package/src/agent-src/templates/scripts/pr-risk-config.example.yml +76 -0
- package/src/agent-src/templates/scripts/pr_review_routing.ts +544 -0
- package/src/agent-src/templates/scripts/pr_risk_review.ts +0 -0
- package/src/agent-src/templates/scripts/telemetry/aggregator.ts +0 -0
- package/src/agent-src/templates/scripts/telemetry/boundary.ts +164 -0
- package/src/agent-src/templates/scripts/telemetry/engagement.ts +479 -0
- package/src/agent-src/templates/scripts/telemetry/report_renderer.ts +394 -0
- package/src/agent-src/templates/scripts/telemetry/settings.ts +210 -0
- package/src/agent-src/templates/scripts/telemetry_record.ts +276 -0
- package/src/agent-src/templates/scripts/telemetry_report.ts +211 -0
- package/src/agent-src/templates/scripts/telemetry_status.ts +333 -0
- package/src/agent-src/templates/scripts/tier_usage_report.ts +619 -0
- package/src/agent-src/templates/scripts/work_engine/__main__.ts +14 -0
- package/src/agent-src/templates/scripts/work_engine/_lib/agent_settings.ts +1261 -0
- package/src/agent-src/templates/scripts/work_engine/_lib/user_global_paths.ts +329 -0
- package/src/agent-src/templates/scripts/work_engine/cli.ts +206 -0
- package/src/agent-src/templates/scripts/work_engine/cli_args.ts +249 -0
- package/src/agent-src/templates/scripts/work_engine/delivery_state.ts +225 -0
- package/src/agent-src/templates/scripts/work_engine/directives/backend/analyze.ts +125 -0
- package/src/agent-src/templates/scripts/work_engine/directives/backend/implement.ts +189 -0
- package/src/agent-src/templates/scripts/work_engine/directives/backend/index.ts +94 -0
- package/src/agent-src/templates/scripts/work_engine/directives/backend/memory.ts +193 -0
- package/src/agent-src/templates/scripts/work_engine/directives/backend/plan.ts +267 -0
- package/src/agent-src/templates/scripts/work_engine/directives/backend/refine.ts +518 -0
- package/src/agent-src/templates/scripts/work_engine/directives/backend/report.ts +379 -0
- package/src/agent-src/templates/scripts/work_engine/directives/backend/test.ts +268 -0
- package/src/agent-src/templates/scripts/work_engine/directives/backend/verify.ts +258 -0
- package/src/agent-src/templates/scripts/work_engine/directives/index.ts +32 -0
- package/src/agent-src/templates/scripts/work_engine/directives/mixed/contract.ts +243 -0
- package/src/agent-src/templates/scripts/work_engine/directives/mixed/index.ts +108 -0
- package/src/agent-src/templates/scripts/work_engine/directives/mixed/stitch.ts +259 -0
- package/src/agent-src/templates/scripts/work_engine/directives/mixed/ui.ts +216 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/_passthrough.ts +40 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/app_spec.ts +241 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/apply.ts +216 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/audit.ts +506 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/design.ts +325 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/index.ts +102 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/polish.ts +462 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/review.ts +474 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/scaffold.ts +352 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui_trivial/_skipped.ts +33 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui_trivial/apply.ts +213 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui_trivial/index.ts +111 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui_trivial/refine.ts +126 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui_trivial/report.ts +112 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui_trivial/test.ts +164 -0
- package/src/agent-src/templates/scripts/work_engine/dispatcher.ts +515 -0
- package/src/agent-src/templates/scripts/work_engine/emitters.ts +119 -0
- package/src/agent-src/templates/scripts/work_engine/errors.ts +24 -0
- package/src/agent-src/templates/scripts/work_engine/hook_bootstrap.ts +104 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/builtin/_chat_history_base.ts +189 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/builtin/chat_history_append.ts +41 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/builtin/chat_history_halt_append.ts +89 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/builtin/decision_gate.ts +193 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/builtin/decision_trace.ts +304 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/builtin/directive_set_guard.ts +110 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/builtin/halt_surface_audit.ts +118 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/builtin/index.ts +17 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/builtin/memory_visibility.ts +161 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/builtin/state_shape_validation.ts +45 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/builtin/trace.ts +134 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/context.ts +94 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/events.ts +58 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/exceptions.ts +85 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/index.ts +27 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/registry.ts +66 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/runner.ts +90 -0
- package/src/agent-src/templates/scripts/work_engine/hooks/settings.ts +260 -0
- package/src/agent-src/templates/scripts/work_engine/input_builders.ts +260 -0
- package/src/agent-src/templates/scripts/work_engine/intent/classify.ts +466 -0
- package/src/agent-src/templates/scripts/work_engine/migration/v0_to_v1.ts +531 -0
- package/src/agent-src/templates/scripts/work_engine/orchestration.ts +366 -0
- package/src/agent-src/templates/scripts/work_engine/persona_policy.ts +97 -0
- package/src/agent-src/templates/scripts/work_engine/resolvers/diff.ts +135 -0
- package/src/agent-src/templates/scripts/work_engine/resolvers/file.ts +175 -0
- package/src/agent-src/templates/scripts/work_engine/resolvers/prompt.ts +115 -0
- package/src/agent-src/templates/scripts/work_engine/scoring/confidence.ts +415 -0
- package/src/agent-src/templates/scripts/work_engine/scoring/decision_engine.ts +466 -0
- package/src/agent-src/templates/scripts/work_engine/scoring/decision_trace.ts +298 -0
- package/src/agent-src/templates/scripts/work_engine/scoring/memory_visibility.ts +444 -0
- package/src/agent-src/templates/scripts/work_engine/stack/detect.ts +252 -0
- package/src/agent-src/templates/scripts/work_engine/stack/runner.ts +745 -0
- package/src/agent-src/templates/scripts/work_engine/state.ts +1151 -0
- package/src/agent-src/templates/scripts/work_engine/state_io.ts +413 -0
- package/src/config/surface-matrix.yml +213 -0
- package/src/install/atomic.ts +111 -0
- package/src/install/conflict.ts +226 -0
- package/src/install/detect.ts +280 -0
- package/src/install/paths.ts +90 -0
- package/src/install/plan.ts +205 -0
- package/src/install/preflight.ts +210 -0
- package/src/install/selectedTools.ts +52 -0
- package/src/install/toolDetection.ts +120 -0
- package/src/install/txlog.ts +161 -0
- package/src/install/types.ts +175 -0
- package/src/install/wizard-plan.ts +216 -0
- package/src/scripts/_cli/cmd_converge.ts +399 -0
- package/src/scripts/_cli/cmd_doctor.ts +94 -0
- package/src/scripts/_cli/cmd_upgrade.ts +40 -16
- package/src/scripts/_dispatch.bash +13 -0
- package/src/scripts/condense.ts +67 -36
- package/src/scripts/hook_manifest.yaml +16 -7
- package/src/scripts/lint_marketplace.ts +54 -56
- package/src/scripts/lint_surface_matrix.ts +200 -0
- package/src/scripts/prepack-check.mjs +108 -5
- package/src/scripts/surface_probe_hook.ts +231 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
# {{project_name}}
|
|
2
|
+
|
|
3
|
+
<!--
|
|
4
|
+
Fill placeholders or run `/agents init`, then delete this
|
|
5
|
+
comment. Iron Law — capability bullets, not path lists; paths rot.
|
|
6
|
+
Tool stubs (`CLAUDE.md`, `GEMINI.md`, `.cursorrules`) link here.
|
|
7
|
+
Anatomy + recipes: `.augment/contexts/contracts/agents-md-anatomy.md`.
|
|
8
|
+
-->
|
|
9
|
+
|
|
10
|
+
> {{project_description}}
|
|
11
|
+
|
|
12
|
+
## Layers
|
|
13
|
+
|
|
14
|
+
| Layer | Location | Edits |
|
|
15
|
+
|---|---|---|
|
|
16
|
+
| Installed package | `.augment/`, `dist/agent-src/` | hands-off — managed by `event4u/agent-config` |
|
|
17
|
+
| Project layer | `agents/`, `agents/overrides/`, `.agent-settings.yml` | your customizations and config |
|
|
18
|
+
|
|
19
|
+
## Pointers
|
|
20
|
+
|
|
21
|
+
- **Filling out this AGENTS.md** — section templates, capability bullets, multi-agent entry flow, monorepo per-package layout: [`.augment/contexts/contracts/consumer-agents-md-guide.md`](.augment/contexts/contracts/consumer-agents-md-guide.md).
|
|
22
|
+
- **Behavior rules (always active)** — Iron Laws and routed rules that fire automatically while you work in this project: [`.augment/rules/`](.augment/rules/).
|
|
23
|
+
- **Skills (on-demand expertise)** — domain skills surfaced by description; invoked when their trigger fires: [`.augment/skills/`](.augment/skills/).
|
|
24
|
+
- **Commands (workflows)** — slash-commands the agent runs end-to-end (`/work`, `/implement-ticket`, `/commit`, `/create-pr`, …): [`.augment/commands/`](.augment/commands/).
|
|
25
|
+
- **Project-specific docs** — your own architecture notes, roadmaps, sessions, contexts: [`agents/`](agents/).
|
|
26
|
+
|
|
27
|
+
## Emergency triage — read this when nothing else is reachable
|
|
28
|
+
|
|
29
|
+
1. **What is this repo?** — Consumer project; agent-config is installed as a shared skill / rule / command suite at `.augment/` and `dist/agent-src/`.
|
|
30
|
+
2. **What language?** — Project-specific; agents mirror the user's language at runtime.
|
|
31
|
+
3. **Where do I edit agent-config?** — Do not edit `.augment/` or `dist/agent-src/` here; they are installed artifacts. Project edits live in `agents/` and project source.
|
|
32
|
+
4. **Lint / test / sync entry point?** — Project-specific (see project README); agent-config reinstalls via `composer update event4u/agent-config` or `npm update @event4u/agent-config`.
|
|
33
|
+
5. **Where do the always-active rules live?** — `dist/agent-src/rules/` (kernel = 9 Iron-Law rules; tier-1 / tier-2 routed via `dist/agent-src/router.json`).
|
|
34
|
+
6. **Per-module agent docs?** — If `modules.enabled: true`, each module under `modules.root_paths` may carry its own `{agent_folder}/` (default `agents/`). See `module-management` skill.
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
# PR Risk Review — installation
|
|
2
|
+
|
|
3
|
+
Heuristic PR risk classifier **and** review routing. Posts two sticky
|
|
4
|
+
comments on every non-draft PR:
|
|
5
|
+
|
|
6
|
+
- **PR Risk** — `low / medium / high` label plus matched hotspots;
|
|
7
|
+
applies a `risk:<level>` label.
|
|
8
|
+
- **Review Routing** — owner-mapped reviewer roles from
|
|
9
|
+
`ownership-map.yml` and any matched entries from
|
|
10
|
+
`historical-bug-patterns.yml`.
|
|
11
|
+
|
|
12
|
+
Both are **informational** — conversation starters for reviewers, not
|
|
13
|
+
merge gates. Add a separate required check if you want a hard stop on
|
|
14
|
+
high-risk PRs.
|
|
15
|
+
|
|
16
|
+
## What gets installed
|
|
17
|
+
|
|
18
|
+
| File in package | Copy to | Purpose |
|
|
19
|
+
|---|---|---|
|
|
20
|
+
| `templates/github-workflows/pr-risk-review.yml` | `.github/workflows/pr-risk-review.yml` | GitHub Actions workflow |
|
|
21
|
+
| `templates/scripts/pr_risk_review.ts` | `scripts/pr_risk_review.ts` | Risk classifier (TypeScript, run via tsx) |
|
|
22
|
+
| `templates/scripts/pr_review_routing.ts` | `scripts/pr_review_routing.ts` | Routing classifier |
|
|
23
|
+
| `templates/scripts/pr-risk-config.example.yml` | `.github/pr-risk-config.yml` | Risk patterns (optional) |
|
|
24
|
+
| `templates/scripts/ownership-map.example.yml` | `.github/ownership-map.yml` | Ownership entries (optional) |
|
|
25
|
+
| `templates/scripts/historical-bug-patterns.example.yml` | `.github/historical-bug-patterns.yml` | Registered failure modes (optional) |
|
|
26
|
+
|
|
27
|
+
## Install
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
# from the consumer repo root
|
|
31
|
+
cp .augment/templates/github-workflows/pr-risk-review.yml .github/workflows/
|
|
32
|
+
cp .augment/templates/scripts/pr_risk_review.ts scripts/
|
|
33
|
+
cp .augment/templates/scripts/pr_review_routing.ts scripts/
|
|
34
|
+
cp .augment/templates/scripts/pr-risk-config.example.yml .github/pr-risk-config.yml
|
|
35
|
+
cp .augment/templates/scripts/ownership-map.example.yml .github/ownership-map.yml
|
|
36
|
+
cp .augment/templates/scripts/historical-bug-patterns.example.yml .github/historical-bug-patterns.yml
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
The routing step in the workflow is **conditional** — it only runs if
|
|
40
|
+
`scripts/pr_review_routing.ts` exists, so risk classification alone works
|
|
41
|
+
without routing being installed.
|
|
42
|
+
|
|
43
|
+
Create the three labels once (or let them be auto-created on first run):
|
|
44
|
+
|
|
45
|
+
```bash
|
|
46
|
+
for level in low medium high; do
|
|
47
|
+
gh label create "risk:$level" --color "$(case $level in
|
|
48
|
+
high) echo b60205 ;; medium) echo fbca04 ;; low) echo 0e8a16 ;;
|
|
49
|
+
esac)" --description "PR risk: $level" --force
|
|
50
|
+
done
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
Commit the workflow and config. The first PR you open afterwards triggers
|
|
54
|
+
the action.
|
|
55
|
+
|
|
56
|
+
## Customize
|
|
57
|
+
|
|
58
|
+
Edit `.github/pr-risk-config.yml`:
|
|
59
|
+
|
|
60
|
+
- **Add** patterns to `high` for paths where review must be careful
|
|
61
|
+
(payment code, tenant boundaries, feature flags you care about).
|
|
62
|
+
- **Add** patterns to `medium` for shared services, public endpoints,
|
|
63
|
+
non-critical jobs.
|
|
64
|
+
- **Add** patterns to `ignore` for paths that should never influence the
|
|
65
|
+
level (docs, generated files, snapshot tests).
|
|
66
|
+
|
|
67
|
+
Matching uses `fnmatch` glob syntax (`**/auth/**`, `composer.lock`, …).
|
|
68
|
+
|
|
69
|
+
If you do not want a config file, delete it — the script falls back to
|
|
70
|
+
defaults that cover migrations, lockfiles, auth, workflows, and infra
|
|
71
|
+
across Laravel, Symfony, Django, Rails, Node, and Next.js.
|
|
72
|
+
|
|
73
|
+
## What the PR comment looks like
|
|
74
|
+
|
|
75
|
+
```
|
|
76
|
+
## 🟡 PR Risk: medium
|
|
77
|
+
|
|
78
|
+
_14 changed file(s), 2 risk signal(s)._
|
|
79
|
+
|
|
80
|
+
### 🟡 Medium
|
|
81
|
+
- `**/app/Http/Controllers/**` — 2 file(s)
|
|
82
|
+
- `app/Http/Controllers/Api/OrderController.php`
|
|
83
|
+
- `app/Http/Controllers/Api/PaymentController.php`
|
|
84
|
+
- `composer.json` — 1 file(s)
|
|
85
|
+
- `composer.json`
|
|
86
|
+
|
|
87
|
+
---
|
|
88
|
+
_Classifier is heuristic. Merge is not blocked by this check._
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
The same comment is **updated** (not re-posted) on every new push thanks
|
|
92
|
+
to `marocchino/sticky-pull-request-comment`.
|
|
93
|
+
|
|
94
|
+
## Routing comment format
|
|
95
|
+
|
|
96
|
+
```
|
|
97
|
+
## 🔴 Review Routing: high
|
|
98
|
+
|
|
99
|
+
_3 changed file(s), 2 historical pattern(s) matched._
|
|
100
|
+
|
|
101
|
+
### Suggested reviewers (role-based)
|
|
102
|
+
- primary: finance-engineering — focus: tax calculation + idempotency
|
|
103
|
+
- secondary: security — focus: tax calculation + idempotency
|
|
104
|
+
|
|
105
|
+
### Historical patterns matched
|
|
106
|
+
- 🔴 queue-job-not-idempotent — Queue job without idempotency key
|
|
107
|
+
required test: assert a retried job does not double-write
|
|
108
|
+
- 🔴 blade-unsafe-html — Blade component renders user input with {!! !!}
|
|
109
|
+
|
|
110
|
+
_Data source: ownership-map.yml + historical-bug-patterns.yml. …_
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
Curate `ownership-map.yml` and `historical-bug-patterns.yml` over time —
|
|
114
|
+
see `../../../docs/guidelines/agent-infra/review-routing-data-format.md` for
|
|
115
|
+
the full schema.
|
|
116
|
+
|
|
117
|
+
## Uninstall
|
|
118
|
+
|
|
119
|
+
```bash
|
|
120
|
+
rm .github/workflows/pr-risk-review.yml
|
|
121
|
+
rm scripts/pr_risk_review.ts
|
|
122
|
+
rm scripts/pr_review_routing.ts
|
|
123
|
+
rm .github/pr-risk-config.yml .github/ownership-map.yml .github/historical-bug-patterns.yml
|
|
124
|
+
gh label delete risk:low risk:medium risk:high
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
## Verifying locally
|
|
128
|
+
|
|
129
|
+
```bash
|
|
130
|
+
./scripts-run src/agent-src/templates/scripts/pr_risk_review \
|
|
131
|
+
--base origin/main --head HEAD \
|
|
132
|
+
--config .github/pr-risk-config.yml \
|
|
133
|
+
--output /tmp/risk-report.md \
|
|
134
|
+
--level-file /tmp/risk-level.txt
|
|
135
|
+
|
|
136
|
+
./scripts-run src/agent-src/templates/scripts/pr_review_routing \
|
|
137
|
+
--base origin/main --head HEAD \
|
|
138
|
+
--ownership-map .github/ownership-map.yml \
|
|
139
|
+
--patterns .github/historical-bug-patterns.yml \
|
|
140
|
+
--output /tmp/routing-report.md \
|
|
141
|
+
--level-file /tmp/routing-level.txt
|
|
142
|
+
|
|
143
|
+
cat /tmp/risk-report.md /tmp/routing-report.md
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
## Limitations
|
|
147
|
+
|
|
148
|
+
- **Heuristic only.** A PR with no matched patterns is labeled `low` even
|
|
149
|
+
if it changes business-critical logic. Reviewers still need to read.
|
|
150
|
+
- **No semantic analysis.** The classifier looks at paths, not diff
|
|
151
|
+
content. A whitespace-only edit to `composer.lock` is still `high`.
|
|
152
|
+
- **Not a policy engine.** Use CODEOWNERS + required reviews for
|
|
153
|
+
enforcement; use this workflow for triage and discussion.
|
|
154
|
+
|
|
155
|
+
---
|
|
156
|
+
|
|
157
|
+
# Memory Hygiene — installation
|
|
158
|
+
|
|
159
|
+
Weekly staleness report for the four engineering-memory files under
|
|
160
|
+
`agents/memory/`. Opens (or updates) a single tracking issue with the
|
|
161
|
+
`memory-hygiene` label when entries are past their
|
|
162
|
+
`review_after_days` window. Closes the issue automatically once all
|
|
163
|
+
entries are fresh again. Purely informational — it does **not** block
|
|
164
|
+
PRs.
|
|
165
|
+
|
|
166
|
+
## What gets installed
|
|
167
|
+
|
|
168
|
+
| File in package | Copy to | Purpose |
|
|
169
|
+
|---|---|---|
|
|
170
|
+
| `templates/github-workflows/memory-hygiene.yml` | `.github/workflows/memory-hygiene.yml` | Weekly staleness workflow |
|
|
171
|
+
| `templates/scripts/check_memory.ts` | `scripts/check_memory.ts` | YAML schema + staleness validator |
|
|
172
|
+
|
|
173
|
+
## Install
|
|
174
|
+
|
|
175
|
+
```bash
|
|
176
|
+
# from the consumer repo root
|
|
177
|
+
cp .augment/templates/github-workflows/memory-hygiene.yml .github/workflows/
|
|
178
|
+
cp .augment/templates/scripts/check_memory.ts scripts/
|
|
179
|
+
```
|
|
180
|
+
|
|
181
|
+
Commit both. The first scheduled run (Mondays 06:00 UTC) reports on
|
|
182
|
+
whatever is under `agents/memory/`. Trigger manually with
|
|
183
|
+
`gh workflow run memory-hygiene.yml`.
|
|
184
|
+
|
|
185
|
+
## Verifying locally
|
|
186
|
+
|
|
187
|
+
```bash
|
|
188
|
+
./scripts-run src/scripts/check_memory --path agents/memory
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
Exit `0` = clean, `1` = violations (missing required fields, duplicate
|
|
192
|
+
ids, or obvious secrets — staleness alone is informational).
|
|
193
|
+
|
|
194
|
+
Schema reference: `../../../docs/guidelines/agent-infra/engineering-memory-data-format.md`.
|
|
195
|
+
Schema examples: `.augment/templates/agents/memory/*.example.yml`.
|