agents-md-kit 0.0.0-stage → 0.1.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.
Files changed (89) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +162 -2
  3. package/bin/agent-kit.js +6 -0
  4. package/core/files/.claude/settings.json +16 -0
  5. package/core/files/.claude/skills/agent-memory-protocol/SKILL.md +117 -0
  6. package/core/files/.claude/skills/api-design-rest/SKILL.md +126 -0
  7. package/core/files/.claude/skills/backend-architecture-principles/SKILL.md +116 -0
  8. package/core/files/.claude/skills/backend-security/SKILL.md +117 -0
  9. package/core/files/.claude/skills/changelog-and-versioning/SKILL.md +169 -0
  10. package/core/files/.claude/skills/database-best-practices/SKILL.md +104 -0
  11. package/core/files/.claude/skills/git-commit-and-workflow/SKILL.md +140 -0
  12. package/core/files/.claude/skills/project-management-workflow/SKILL.md +181 -0
  13. package/core/files/CLAUDE.md +1 -0
  14. package/core/files/MEMORY.md +77 -0
  15. package/core/files/docs/adr/0000-template.md +21 -0
  16. package/core/fragments/agents-core.md +61 -0
  17. package/core/manifest.txt +21 -0
  18. package/docs/monorepo.md +72 -0
  19. package/package.json +50 -4
  20. package/packs/github/files/.github/ISSUE_TEMPLATE/bug_report.md +22 -0
  21. package/packs/github/files/.github/ISSUE_TEMPLATE/feature_request.md +20 -0
  22. package/packs/github/files/.github/pull_request_template.md +24 -0
  23. package/packs/github/files/.github/workflows/pr-title.yml +37 -0
  24. package/packs/github/manifest.txt +6 -0
  25. package/packs/web/files/.claude/skills/html-syntax-and-semantics/SKILL.md +127 -0
  26. package/packs/web/files/.claude/skills/seo-best-practices/SKILL.md +158 -0
  27. package/packs/web/fragments/agents-web.md +11 -0
  28. package/packs/web/manifest.txt +5 -0
  29. package/presets/node-backend/docs/node-backend.md +60 -0
  30. package/presets/node-backend/files/.editorconfig +12 -0
  31. package/presets/node-backend/files/.husky/commit-msg +1 -0
  32. package/presets/node-backend/files/.husky/pre-commit +1 -0
  33. package/presets/node-backend/files/.lintstagedrc.json +4 -0
  34. package/presets/node-backend/files/.prettierrc.json +7 -0
  35. package/presets/node-backend/files/.release-please-manifest.json +3 -0
  36. package/presets/node-backend/files/CHANGELOG.md +5 -0
  37. package/presets/node-backend/files/commitlint.config.mjs +12 -0
  38. package/presets/node-backend/files/eslint.config.mjs +38 -0
  39. package/presets/node-backend/files/release-please-config.json +25 -0
  40. package/presets/node-backend/fragments/agents-node-backend-github.md +7 -0
  41. package/presets/node-backend/fragments/agents-node-backend.md +13 -0
  42. package/presets/node-backend/fragments/gitignore.txt +19 -0
  43. package/presets/node-backend/fragments/prettierignore.txt +16 -0
  44. package/presets/node-backend/github/dependabot.yml +21 -0
  45. package/presets/node-backend/github/workflows/ci.yml +38 -0
  46. package/presets/node-backend/github/workflows/release-please.yml +21 -0
  47. package/presets/node-backend/manifest.txt +30 -0
  48. package/presets/python/docs/python.md +66 -0
  49. package/presets/python/files/.editorconfig +15 -0
  50. package/presets/python/files/.pre-commit-config.yaml +32 -0
  51. package/presets/python/files/.release-please-manifest.json +3 -0
  52. package/presets/python/files/CHANGELOG.md +5 -0
  53. package/presets/python/files/mypy.ini +5 -0
  54. package/presets/python/files/pytest.ini +6 -0
  55. package/presets/python/files/release-please-config.json +25 -0
  56. package/presets/python/files/ruff.toml +17 -0
  57. package/presets/python/fragments/agents-python-github.md +7 -0
  58. package/presets/python/fragments/agents-python.md +14 -0
  59. package/presets/python/fragments/gitignore.txt +25 -0
  60. package/presets/python/github/dependabot.yml +18 -0
  61. package/presets/python/github/workflows/ci.yml +37 -0
  62. package/presets/python/github/workflows/release-please.yml +21 -0
  63. package/presets/python/manifest.txt +25 -0
  64. package/presets/react-typescript/docs/react-typescript.md +71 -0
  65. package/presets/react-typescript/files/.claude/skills/react-principles/SKILL.md +264 -0
  66. package/presets/react-typescript/files/.editorconfig +12 -0
  67. package/presets/react-typescript/files/.husky/commit-msg +1 -0
  68. package/presets/react-typescript/files/.husky/pre-commit +1 -0
  69. package/presets/react-typescript/files/.lintstagedrc.json +4 -0
  70. package/presets/react-typescript/files/.prettierrc.json +7 -0
  71. package/presets/react-typescript/files/.release-please-manifest.json +3 -0
  72. package/presets/react-typescript/files/CHANGELOG.md +5 -0
  73. package/presets/react-typescript/files/commitlint.config.mjs +12 -0
  74. package/presets/react-typescript/files/eslint.config.mjs +55 -0
  75. package/presets/react-typescript/files/release-please-config.json +25 -0
  76. package/presets/react-typescript/fragments/agents-react-typescript-github.md +7 -0
  77. package/presets/react-typescript/fragments/agents-react-typescript.md +17 -0
  78. package/presets/react-typescript/fragments/gitignore.txt +22 -0
  79. package/presets/react-typescript/fragments/prettierignore.txt +17 -0
  80. package/presets/react-typescript/github/dependabot.yml +21 -0
  81. package/presets/react-typescript/github/workflows/ci.yml +38 -0
  82. package/presets/react-typescript/github/workflows/release-please.yml +21 -0
  83. package/presets/react-typescript/manifest.txt +32 -0
  84. package/src/blocks.js +132 -0
  85. package/src/cli.js +159 -0
  86. package/src/fsutil.js +123 -0
  87. package/src/install.js +223 -0
  88. package/src/manifest.js +187 -0
  89. package/src/validate.js +324 -0
@@ -0,0 +1,181 @@
1
+ ---
2
+ name: project-management-workflow
3
+ description: Lightweight project management workflow for AI-assisted development. Use when planning features, breaking down tasks, tracking progress, recording architectural decisions (ADRs), defining done, handing work between sessions or agents, or reporting status.
4
+ ---
5
+
6
+ # Project Management Workflow for Agents and Humans
7
+
8
+ Goal: ship small, verified increments with minimal ceremony, and keep the project's state understandable to anyone (or any agent) joining mid-way.
9
+
10
+ ## 1. Task Lifecycle
11
+
12
+ ```
13
+ Clarify → Plan → Implement → Verify → Document → Hand off
14
+ ```
15
+
16
+ 1. **Clarify:** restate the goal and the acceptance criteria. Identify unknowns, constraints and what is *out of scope*. Ask when requirements are ambiguous or the change is destructive/irreversible. Otherwise state assumptions and proceed.
17
+ 2. **Plan:** read `AGENTS.md` and `MEMORY.md`. Inspect relevant code. Write a short plan (section 3).
18
+ 3. **Implement:** small steps, one concern at a time, tests alongside. Commit atomically (`git-commit-and-workflow`).
19
+ 4. **Verify:** run tests, lint, type checks and the feature itself. Don't claim "done" on code that hasn't been run. Check the relevant skill checklists.
20
+ 5. **Document:** write the commit/PR title as a release note and update the changelog per the `changelog-and-versioning` skill; update docs/OpenAPI, ADRs and `MEMORY.md` (`agent-memory-protocol`).
21
+ 6. **Hand off:** summarize what changed, how it was verified, what's left and any risks or open questions.
22
+
23
+ ## 2. Work Breakdown
24
+
25
+ - Break work into tasks that can be completed and verified in **about half a day or less**, each with a clear outcome.
26
+ - Slice **vertically** (a thin end-to-end behavior: UI + API + DB) rather than horizontally (all DB first, all UI later), so each slice is shippable and testable.
27
+ - Order tasks by risk and dependency: tackle unknowns and riskiest assumptions first, using spikes (time-boxed investigations) for unknowns.
28
+ - A good task states: goal, acceptance criteria, scope boundaries, dependencies and how to verify.
29
+ - Track tasks in the team's tracker (GitHub Issues, Linear, Jira). For solo/agent work without one, use a `TASKS.md` checklist at the repo root. Keep one source of truth.
30
+
31
+ Task template:
32
+
33
+ ```markdown
34
+ ## Goal
35
+ <one sentence outcome>
36
+
37
+ ## Acceptance Criteria
38
+ - [ ] Given/When/Then or observable behavior
39
+ - [ ] Error and edge cases handled
40
+ - [ ] Tests added
41
+
42
+ ## Out of Scope
43
+ -
44
+
45
+ ## Notes / Dependencies
46
+ -
47
+ ```
48
+
49
+ ## 3. Planning Non-Trivial Changes
50
+
51
+ For anything touching more than a few files, a data model, an API contract or security, write a short plan before coding (in the PR description, issue, or `docs/plans/<topic>.md`):
52
+
53
+ ```markdown
54
+ # Plan: <title>
55
+ ## Problem and goal
56
+ ## Approach (and alternatives considered)
57
+ ## Steps (ordered, each independently verifiable)
58
+ ## Data/API/contract changes (and migration/rollback)
59
+ ## Risks and mitigations
60
+ ## Test strategy
61
+ ## Open questions
62
+ ```
63
+
64
+ Keep it to about a page. Update it if the approach changes. Delete or archive when merged if it has no lasting value (decisions go to an ADR).
65
+
66
+ ## 4. Architecture Decision Records (ADRs)
67
+
68
+ Record decisions that are hard to reverse or that future contributors will question (framework choice, data model, auth approach, major dependency, API style).
69
+
70
+ - Location: `docs/adr/NNNN-short-title.md` (numbered, immutable once accepted. Supersede with a new ADR instead of editing history).
71
+ - Keep each to one page.
72
+
73
+ ```markdown
74
+ # ADR-0004: Store money as integer minor units
75
+
76
+ - Status: Accepted (2026-11-11) <!-- Proposed | Accepted | Deprecated | Superseded by ADR-00XX -->
77
+ - Deciders: <names>
78
+
79
+ ## Context
80
+ What forces and constraints led to this decision?
81
+
82
+ ## Decision
83
+ What we will do.
84
+
85
+ ## Consequences
86
+ Positive, negative and follow-up work.
87
+
88
+ ## Alternatives considered
89
+ Option A: ... rejected because ...
90
+ ```
91
+
92
+ Add a one-line pointer in `MEMORY.md` for quick recall.
93
+
94
+ ## 5. Definition of Ready and Done
95
+
96
+ **Ready to start** (don't begin until true, or state assumptions):
97
+ - [ ] Goal and acceptance criteria are clear
98
+ - [ ] Dependencies and access are known
99
+ - [ ] Scope is small enough to finish and verify in one go
100
+
101
+ **Done** (see also `AGENTS.md`):
102
+ - [ ] Acceptance criteria met and demonstrated (tests and/or manual check)
103
+ - [ ] Code reviewed (self-review at minimum), lint/types/tests green in CI
104
+ - [ ] Security, accessibility, SEO and performance checks applied where relevant (see the skills listed in `AGENTS.md`)
105
+ - [ ] Migrations safe and reversible. API changes non-breaking or versioned
106
+ - [ ] Commit/PR title reads as a release note; changelog updated per the `changelog-and-versioning` skill; docs and `MEMORY.md` updated as needed
107
+ - [ ] Merged, and deployed or ready to deploy
108
+
109
+ ## 6. Scope and Change Control
110
+
111
+ - Do what was asked, no more. Note related improvements as follow-up tasks instead of expanding the change silently.
112
+ - If scope grows or the approach must change significantly, stop and report it, since the person deciding needs the new trade-offs.
113
+ - Never make destructive or irreversible changes (data deletion, schema drops, force pushes, production config) without explicit confirmation.
114
+ - Record deferred work as issues/TODOs with context. Don't leave anonymous `TODO` comments. Use `TODO(#123): ...`.
115
+
116
+ ## 7. Risk and Quality Management
117
+
118
+ - State assumptions explicitly, and flag any that are unverified.
119
+ - Prefer reversible changes: feature flags, small PRs, backward-compatible migrations, easy rollback.
120
+ - Identify blast radius before changing shared code, public APIs, auth, payments or data.
121
+ - Keep the build green. If you break `main`, fix forward or revert immediately.
122
+ - Treat flaky tests as bugs. Don't retry-until-green or disable without a tracked issue.
123
+ - Track technical debt visibly (issues labeled `tech-debt`) with impact and a proposed fix. Reserve regular capacity to pay it down.
124
+
125
+ ## 8. Communication and Status Reporting
126
+
127
+ Status updates should be short, factual and actionable:
128
+
129
+ ```markdown
130
+ **Done:** what is complete and verified
131
+ **In progress:** what's underway, and the next step
132
+ **Blocked / needs decision:** what, who, and by when
133
+ **Risks:** anything that could change scope, schedule or quality
134
+ ```
135
+
136
+ - Report outcomes and evidence ("tests pass: 142/142; checkout flow verified locally"), not just activity.
137
+ - Be honest about what was *not* verified or not completed. Never claim success you haven't confirmed.
138
+ - Surface blockers early and propose options with a recommendation.
139
+
140
+ ## 9. Handoffs Between Sessions and Agents
141
+
142
+ At the end of a session, leave the project so that a stranger could continue:
143
+ 1. Working tree clean or committed in meaningful commits. Branch pushed if requested.
144
+ 2. `MEMORY.md` → **Current State** shows what's done, what's next and blockers.
145
+ 3. Issues/`TASKS.md` reflect the real status.
146
+ 4. A final summary message with links to the PR/branch, how to run and verify, and open questions.
147
+
148
+ ## 10. Recommended Repository Layout
149
+
150
+ ```
151
+ /
152
+ ├── AGENTS.md # Rules for agents (stable, human-owned)
153
+ ├── MEMORY.md # Learned facts and current state (agent-maintained)
154
+ ├── CHANGELOG.md # User-facing release history
155
+ ├── TASKS.md # Optional: task list when no external tracker
156
+ ├── README.md # Humans: what it is, how to run it
157
+ ├── .github/
158
+ │ ├── pull_request_template.md
159
+ │ └── ISSUE_TEMPLATE/
160
+ ├── .claude/skills/ # Skill folders (each contains SKILL.md)
161
+ └── docs/
162
+ ├── adr/ # Architecture Decision Records
163
+ ├── plans/ # Optional: short implementation plans
164
+ └── memory/ # Optional: area-specific memory when MEMORY.md grows
165
+ ```
166
+
167
+ ## 11. Cadence (Optional, for Teams)
168
+
169
+ - **Daily:** keep the board current. Surface blockers.
170
+ - **Weekly:** review the backlog, re-prioritize, prune stale issues and `MEMORY.md`.
171
+ - **Per release:** update the changelog and version per the `changelog-and-versioning` skill, verify the release checklist, and run a short retro (what worked, what didn't, one improvement to try).
172
+
173
+ ## Review Checklist
174
+
175
+ - [ ] Goal, acceptance criteria and scope are written down before implementation
176
+ - [ ] Work is split into small, verifiable, vertical slices
177
+ - [ ] Significant decisions recorded in an ADR; plan written for non-trivial changes
178
+ - [ ] Verified by running tests and the feature; Definition of Done satisfied
179
+ - [ ] Scope respected; follow-ups tracked as issues; destructive actions confirmed
180
+ - [ ] Status report is factual, with blockers and risks surfaced
181
+ - [ ] Handoff state is in `MEMORY.md`, tracker and PR description
@@ -0,0 +1 @@
1
+ @AGENTS.md
@@ -0,0 +1,77 @@
1
+ # MEMORY.md
2
+
3
+ Persistent working memory for AI agents and contributors. Maintained under the rules in the `agent-memory-protocol` skill.
4
+
5
+ **Rules of thumb:** short, dated, verified when possible. No secrets. Prune obsolete entries. Under about 200 lines. Rules belong in `AGENTS.md`, history in git/`CHANGELOG.md`. If memory disagrees with the code, trust the code and fix this file.
6
+
7
+ _Last pruned: YYYY-MM-DD_
8
+
9
+ ---
10
+
11
+ ## Project Snapshot
12
+
13
+ <!-- What this is, who uses it, stack, key constraints. 3-6 lines. -->
14
+
15
+ - **Purpose:**
16
+ - **Stack:** (frontend / backend / DB / infra)
17
+ - **Environments:** (local / staging / production, how they differ)
18
+ - **Key constraints:** (compliance, performance targets, supported browsers/runtimes)
19
+
20
+ ## Commands (verified)
21
+
22
+ <!-- Exact commands that work. Mark with date. -->
23
+
24
+ | Task | Command | Notes |
25
+ | ---------------- | ------- | ----- |
26
+ | Install | `` | |
27
+ | Dev server | `` | |
28
+ | Run tests | `` | |
29
+ | Lint / typecheck | `` | |
30
+ | Build | `` | |
31
+ | DB migrate | `` | |
32
+
33
+ ## Architecture Notes
34
+
35
+ <!-- Non-obvious structure: where logic lives, data flow, module boundaries. Link to docs/ADRs. -->
36
+
37
+ -
38
+
39
+ ## Decisions
40
+
41
+ <!-- [date] Decision: what, why, rejected alternatives. Pointer to ADR/issue. -->
42
+
43
+ -
44
+
45
+ ## Conventions Learned
46
+
47
+ <!-- Preferences or patterns not (yet) in AGENTS.md. Promote stable ones to AGENTS.md. -->
48
+
49
+ -
50
+
51
+ ## Gotchas and Pitfalls
52
+
53
+ <!-- [date] What goes wrong, why, and the workaround. Delete when fixed in code. -->
54
+
55
+ -
56
+
57
+ ## Current State / In Progress
58
+
59
+ <!-- Single owner at a time. Update at the end of every session. -->
60
+
61
+ - **Working on:**
62
+ - **Branch / PR:**
63
+ - **Done so far:**
64
+ - **Next step (exact):**
65
+ - **Blockers:**
66
+
67
+ ## Open Questions (for a human)
68
+
69
+ <!-- Question, context, who can answer, date asked. -->
70
+
71
+ -
72
+
73
+ ## Session Log (last ~5, one line each)
74
+
75
+ <!-- [date] What was achieved; link to commit/PR. Remove older entries. -->
76
+
77
+ -
@@ -0,0 +1,21 @@
1
+ # ADR-NNNN: <short decision title>
2
+
3
+ - Status: Proposed <!-- Proposed | Accepted | Deprecated | Superseded by ADR-NNNN -->
4
+ - Date: YYYY-MM-DD
5
+ - Deciders: <names>
6
+
7
+ ## Context
8
+
9
+ What forces and constraints led to this decision?
10
+
11
+ ## Decision
12
+
13
+ What we will do.
14
+
15
+ ## Consequences
16
+
17
+ Positive, negative and follow-up work.
18
+
19
+ ## Alternatives considered
20
+
21
+ Option A: ... rejected because ...
@@ -0,0 +1,61 @@
1
+ This file is the entry point for AI coding agents working in this repository. Load the relevant skill(s) before writing or reviewing code in that area. If rules conflict, security beats everything, then correctness, then simplicity (KISS/YAGNI), then everything else.
2
+
3
+ ## Session Start (always)
4
+
5
+ 1. Read this file, then `MEMORY.md` (learned facts and current state). Verify remembered facts against the code before relying on them.
6
+ 2. Run `git status` and `git log -10 --oneline` to see recent changes.
7
+ 3. Load the skills relevant to the task from the skill index below (and any additional skill sections further down this file).
8
+
9
+ ## Skill Index
10
+
11
+ Skills live at `.claude/skills/<name>/SKILL.md`.
12
+
13
+ | Area | Skill | Load when |
14
+ |---|---|---|
15
+ | Backend architecture | `backend-architecture-principles` | Structuring services, errors, config, logging, jobs, testing |
16
+ | API design | `api-design-rest` | Endpoints, payloads, status codes, pagination, versioning |
17
+ | Security | `backend-security` | Auth, authorization, input handling, uploads, headers, secrets |
18
+ | Database | `database-best-practices` | Schemas, queries, indexes, migrations, transactions |
19
+ | Git & commits | `git-commit-and-workflow` | Committing, branching, PRs, releases, tags |
20
+ | Agent memory | `agent-memory-protocol` | Start/end of every task; whenever you learn something durable |
21
+ | Changelog & versions | `changelog-and-versioning` | Any user-facing change, deprecation, release, version bump |
22
+ | Project management | `project-management-workflow` | Planning, task breakdown, ADRs, status reports, handoffs |
23
+
24
+ ## Project Files and Who Owns Them
25
+
26
+ | File | Purpose | Owner |
27
+ |---|---|---|
28
+ | `AGENTS.md` | Stable rules and conventions | Humans |
29
+ | `MEMORY.md` | Learned facts, decisions, gotchas, current state | Agents (humans may edit) |
30
+ | `CHANGELOG.md` | User-facing release history | release-please if configured, otherwise agents + humans |
31
+ | `docs/adr/` | Architecture Decision Records | Humans + agents |
32
+ | Git history | Exact record of every change and why | Everyone |
33
+
34
+ ## Universal Rules
35
+
36
+ 1. **Understand before changing.** Read the surrounding code and follow existing conventions unless they violate a rule here.
37
+ 2. **Keep changes small and focused.** One concern per change. Don't refactor unrelated code in a feature change.
38
+ 3. **Simplest thing that works** (KISS/YAGNI). No speculative abstractions, flags or optimizations without a concrete need.
39
+ 4. **Validate at boundaries.** Never trust client input. Validate on the server regardless of client-side checks.
40
+ 5. **Security is not optional.** Apply `backend-security` to every feature touching users, data or external input.
41
+ 6. **Write tests** for new behavior and bug fixes (including error paths and permission checks). Don't merge with failing tests, lint or type errors.
42
+ 7. **No secrets in code, logs, memory files or client bundles.**
43
+ 8. **User-facing quality is part of "done":** accessibility, performance and discoverability for anything users see.
44
+ 9. **Document decisions**: update README/OpenAPI/ADRs when behavior or contracts change.
45
+ 10. **When requirements are ambiguous, ask** rather than guess, especially for data model, auth and destructive operations.
46
+ 11. **Commit with Conventional Commits**, atomically, and only when asked or when the workflow says so. Never force-push shared branches, and never skip or work around configured hooks and checks (`--no-verify`, disabling rules to make a check pass). Fix the underlying issue.
47
+ 12. **Write commit/PR titles for the reader of the changelog.** If release-please is configured, don't hand-edit `CHANGELOG.md` or version fields.
48
+ 13. **Keep memory current and small.** Record durable learnings, prune obsolete ones, and leave exact next steps in `MEMORY.md` at the end of each session (see `agent-memory-protocol`).
49
+ 14. **Never claim done without verifying.** Run the tests and the feature. Report honestly what was and wasn't verified.
50
+
51
+ ## Definition of Done
52
+
53
+ - [ ] Meets the requirement, with tests passing (locally and in CI, if there is CI)
54
+ - [ ] Lint, formatting and type checks configured for this repository pass
55
+ - [ ] Relevant skill checklists reviewed
56
+ - [ ] No new vulnerabilities, secrets or unnecessary dependencies
57
+ - [ ] Migrations backward compatible; API changes non-breaking or versioned
58
+ - [ ] Commits follow Conventional Commits; PR small, described, and titled as a release note
59
+ - [ ] Changelog updated per `changelog-and-versioning`
60
+ - [ ] `MEMORY.md` updated (learnings pruned/added, Current State accurate)
61
+ - [ ] Docs/OpenAPI/ADRs updated
@@ -0,0 +1,21 @@
1
+ # description: Always installed. AGENTS.md core block, MEMORY.md, permissions, process and engineering skills, ADR template.
2
+ #
3
+ # Format (one entry per line, fields split on whitespace, paths must not contain spaces):
4
+ # copy <path> [requires=<pack>] [from=<unit-relative source>]
5
+ # copy-once <path> [requires=<pack>] [from=<unit-relative source>]
6
+ # block <id> <dest> <fragment> [style=html|hash] [requires=<pack>]
7
+ # implies <pack> (presets and packs only: selecting the unit also selects that pack)
8
+
9
+ block core AGENTS.md agents-core.md
10
+ copy CLAUDE.md
11
+ copy-once MEMORY.md
12
+ copy .claude/settings.json
13
+ copy .claude/skills/agent-memory-protocol/SKILL.md
14
+ copy .claude/skills/git-commit-and-workflow/SKILL.md
15
+ copy .claude/skills/changelog-and-versioning/SKILL.md
16
+ copy .claude/skills/project-management-workflow/SKILL.md
17
+ copy .claude/skills/backend-security/SKILL.md
18
+ copy .claude/skills/api-design-rest/SKILL.md
19
+ copy .claude/skills/database-best-practices/SKILL.md
20
+ copy .claude/skills/backend-architecture-principles/SKILL.md
21
+ copy-once docs/adr/0000-template.md
@@ -0,0 +1,72 @@
1
+ # Using agent-kit in a monorepo
2
+
3
+ This is a guide only. agent-kit ships no monorepo configs, and the installer installs one preset per target directory. In a monorepo, install core (and packs) at the root, then add per-package pieces by hand or by running the installer per package with care.
4
+
5
+ ## Layout
6
+
7
+ ```
8
+ /
9
+ ├── AGENTS.md # root rules: core block (+ web block), repo-wide tooling
10
+ ├── CLAUDE.md # @AGENTS.md
11
+ ├── MEMORY.md # one memory file, with a section per package
12
+ ├── .claude/
13
+ │ ├── settings.json
14
+ │ └── skills/ # shared skills (core, packs)
15
+ ├── packages/
16
+ │ ├── web/
17
+ │ │ ├── AGENTS.md # package rules: stack, commands, package-only skills
18
+ │ │ ├── CLAUDE.md # @AGENTS.md (needed for Claude Code, see below)
19
+ │ │ └── .claude/skills/ # optional: skills scoped to this package
20
+ │ └── api/
21
+ │ ├── AGENTS.md
22
+ │ └── CLAUDE.md # @AGENTS.md
23
+ ├── release-please-config.json
24
+ └── .release-please-manifest.json
25
+ ```
26
+
27
+ ## Root vs nested AGENTS.md
28
+
29
+ - Install core at the root: `install --target . --pack web --pack github`. The root `AGENTS.md` holds the universal rules and the shared skill index.
30
+ - Give each package its own `AGENTS.md` with what differs there: the stack, exact commands (`npm test -w packages/web`, `pytest packages/api`), and package-only conventions. Say in the nested file that the root rules still apply.
31
+ - **Claude Code: add a `CLAUDE.md` containing `@AGENTS.md` next to every nested `AGENTS.md`.** Because the kit installs a root `CLAUDE.md`, Claude Code by default reads `CLAUDE.md` files only and does not pick up `AGENTS.md` files directly, nested ones included. Subdirectory `CLAUDE.md` files load on demand, when Claude reads a file in that package. (Checked against the Claude Code memory docs, 2026-11-11. The alternative is the **Project instructions** setting `claude-md-and-agents-md`.)
32
+ - Keep nested files short. Rules that apply everywhere belong at the root, and on-demand files over Claude Code's per-file size limit are truncated.
33
+
34
+ ## Presets per package
35
+
36
+ Presets assume they own the repository root (for example `eslint.config.mjs`, `.husky/`, `.pre-commit-config.yaml`), and the installer refuses to combine presets that ship different versions of the same file. Options:
37
+
38
+ - **One stack at the root.** If every package shares a stack (say, all TypeScript), install that preset at the root and use workspace-aware commands.
39
+ - **Mixed stacks.** Install the dominant preset at the root, then port the other stack's configs into its package by hand, using the preset's `files/` folder as the reference (for example `ruff.toml` and `pytest.ini` into `packages/api/`). Git hooks are per repository, so pick one hook runner (husky or pre-commit) and call the other stack's checks from it.
40
+ - Running `install --target packages/api --preset python` writes core files (skills, `MEMORY.md`, `AGENTS.md`) into the package too. That is usually not what you want. If you do it, delete the duplicated core files and keep only the preset's tooling and a nested `AGENTS.md`.
41
+
42
+ ## Skills
43
+
44
+ - Shared skills live in the root `.claude/skills/`.
45
+ - Package-specific skills (for example `react-principles` used only by `packages/web`) can live in `packages/web/.claude/skills/`, if your agent loads skills from nested folders. Otherwise keep them at the root, and list them in the root index with "Load when: working in packages/web".
46
+ - `validate` checks the root `.claude/skills/` against the root `AGENTS.md`. It does not check nested skill folders.
47
+
48
+ ## One MEMORY.md, sections per package
49
+
50
+ Keep a single root `MEMORY.md`, so agents read one file at session start. Add a short section per package (commands, gotchas, current state) and keep the 200-line budget. When a package's notes grow, move them to `docs/memory/<package>.md` and leave a one-line pointer (see the `agent-memory-protocol` skill, "Optional Scaling Pattern").
51
+
52
+ ## Releases per package
53
+
54
+ release-please supports monorepos through `packages` in `release-please-config.json`:
55
+
56
+ ```json
57
+ {
58
+ "$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json",
59
+ "include-component-in-tag": true,
60
+ "packages": {
61
+ "packages/web": { "release-type": "node", "component": "web" },
62
+ "packages/api": { "release-type": "python", "component": "api" }
63
+ }
64
+ }
65
+ ```
66
+
67
+ The `.release-please-manifest.json` then holds one version per path. Set `include-component-in-tag: true` (the presets use `false` for single-package repos), so tags become `web-v1.2.0`. Each package gets its own `CHANGELOG.md`. Use commit scopes or paths so release-please attributes changes to the right package: it decides by the files a commit touches. This is untested in this kit; check the release-please docs for your version.
68
+
69
+ ## Where managed blocks help
70
+
71
+ - Use your own block ids in the root `AGENTS.md`, `.gitignore` or `.prettierignore` (for example `<!-- BEGIN agent-kit:pkg-web -->`), and keep a fragment per package in your repo. The markers keep generated sections apart from hand-written text, and `validate` checks that they stay paired and unique.
72
+ - The installer manages only the block ids its manifests define. Your own ids are left alone, so re-running `install` at the root never touches them.
package/package.json CHANGED
@@ -1,6 +1,52 @@
1
1
  {
2
2
  "name": "agents-md-kit",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "0.1.1",
4
+ "description": "Installs AI-agent configuration (AGENTS.md, skills, memory, presets) into a repository. Dry run by default, never overwrites.",
5
+ "keywords": [
6
+ "agents-md",
7
+ "agents.md",
8
+ "claude-code",
9
+ "ai-agents",
10
+ "coding-agents",
11
+ "skills",
12
+ "scaffold",
13
+ "installer",
14
+ "conventional-commits"
15
+ ],
16
+ "license": "MIT",
17
+ "type": "module",
18
+ "bin": {
19
+ "agents-md-kit": "bin/agent-kit.js"
20
+ },
21
+ "files": [
22
+ "bin/",
23
+ "src/",
24
+ "core/",
25
+ "packs/",
26
+ "presets/",
27
+ "docs/monorepo.md",
28
+ "README.md"
29
+ ],
30
+ "engines": {
31
+ "node": ">=20"
32
+ },
33
+ "scripts": {
34
+ "test": "node --test",
35
+ "validate:template": "node bin/agent-kit.js validate --template",
36
+ "typecheck": "tsc -p .",
37
+ "check": "npm run typecheck && npm test && npm run validate:template"
38
+ },
39
+ "devDependencies": {
40
+ "@types/node": "^26.6.6",
41
+ "typescript": "^7.0.2"
42
+ },
43
+ "repository": {
44
+ "type": "git",
45
+ "url": "git+https://github.com/Rumpz/agents-md-kit.git"
46
+ },
47
+ "homepage": "https://github.com/Rumpz/agents-md-kit#readme",
48
+ "bugs": {
49
+ "url": "https://github.com/Rumpz/agents-md-kit/issues"
50
+ },
51
+ "author": "Rumpz"
52
+ }
@@ -0,0 +1,22 @@
1
+ ---
2
+ name: Bug report
3
+ about: Something is broken or behaves unexpectedly
4
+ title: 'bug: '
5
+ labels: bug
6
+ ---
7
+
8
+ ## What happened
9
+ <!-- Describe the problem -->
10
+
11
+ ## Expected behavior
12
+
13
+ ## Steps to reproduce
14
+ 1.
15
+ 2.
16
+ 3.
17
+
18
+ ## Environment
19
+ <!-- Browser / OS / app version / commit -->
20
+
21
+ ## Logs, screenshots, trace ID
22
+ <!-- Remove any secrets or personal data -->
@@ -0,0 +1,20 @@
1
+ ---
2
+ name: Feature request
3
+ about: Propose a new capability or improvement
4
+ title: 'feat: '
5
+ labels: enhancement
6
+ ---
7
+
8
+ ## Goal
9
+ <!-- One sentence: the outcome for the user -->
10
+
11
+ ## Acceptance criteria
12
+ - [ ]
13
+ - [ ] Error and edge cases handled
14
+ - [ ] Tests added
15
+
16
+ ## Out of scope
17
+ -
18
+
19
+ ## Notes / dependencies
20
+ -
@@ -0,0 +1,24 @@
1
+ <!--
2
+ PR title must be a Conventional Commit, e.g. `feat(checkout): add idempotency key to payments`.
3
+ With squash merges it becomes the commit message (and the release note if release-please is configured),
4
+ so write it for the person reading the changelog.
5
+ -->
6
+
7
+ ## Summary
8
+ <!-- What changed and why -->
9
+
10
+ ## Changes
11
+ -
12
+
13
+ ## Testing
14
+ <!-- How you verified it: tests added, manual steps -->
15
+
16
+ ## Risks / Rollback
17
+ <!-- Migrations, flags, breaking changes, how to revert -->
18
+
19
+ ## Checklist
20
+ - [ ] PR title is a Conventional Commit written for the changelog reader
21
+ - [ ] Tests added/updated and passing
22
+ - [ ] Docs / OpenAPI / ADR / changelog updated (if needed)
23
+ - [ ] Accessibility and SEO checked (user-facing pages, if applicable)
24
+ - [ ] `MEMORY.md` updated (if new lasting knowledge)
@@ -0,0 +1,37 @@
1
+ name: PR title
2
+
3
+ # With squash merges the PR title becomes the commit message (and the release note
4
+ # if release-please is configured), so it must be a valid Conventional Commit.
5
+ on:
6
+ pull_request:
7
+ types: [opened, edited, synchronize, reopened]
8
+
9
+ permissions:
10
+ pull-requests: read
11
+
12
+ jobs:
13
+ pr-title:
14
+ name: pr-title
15
+ runs-on: ubuntu-latest
16
+ steps:
17
+ - uses: amannn/action-semantic-pull-request@v5
18
+ env:
19
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
20
+ with:
21
+ types: |
22
+ feat
23
+ fix
24
+ perf
25
+ refactor
26
+ docs
27
+ test
28
+ build
29
+ ci
30
+ style
31
+ chore
32
+ revert
33
+ requireScope: false
34
+ subjectPattern: ^(?![A-Z]).+$
35
+ subjectPatternError: |
36
+ The subject "{subject}" must start with a lowercase letter
37
+ (for example: "add passkey login", not "Add passkey login").
@@ -0,0 +1,6 @@
1
+ # description: GitHub pack. PR and issue templates and the PR-title check. Also enables presets' GitHub CI (requires=github).
2
+
3
+ copy .github/pull_request_template.md
4
+ copy .github/ISSUE_TEMPLATE/bug_report.md
5
+ copy .github/ISSUE_TEMPLATE/feature_request.md
6
+ copy .github/workflows/pr-title.yml