Skip to content

Commit 370830c

Browse files
[skills] Add packaged AGENTS.md skill (#128) (#129)
* [skills] Add create-agentsmd packaged skill (#128) * Update wiki submodule pointer for PR #129 * [agents] Add agents-maintainer role (#128) * [agents] Add canonical reference guidance (#128) * [docs] Refresh AGENTS.md navigation guidance (#128) --------- Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
1 parent a04e511 commit 370830c

8 files changed

Lines changed: 218 additions & 6 deletions

File tree

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
---
2+
name: agents-maintainer
3+
description: Keep repository AGENTS.md guidance aligned with the current Fast Forward DevTools workflows and packaged agent surfaces.
4+
primary-skill: create-agentsmd
5+
supporting-skills: []
6+
---
7+
8+
# agents-maintainer
9+
10+
## Purpose
11+
12+
Maintain repository-root `AGENTS.md` guidance so coding agents can rely on
13+
accurate setup, workflow, testing, and contribution instructions.
14+
15+
## Responsibilities
16+
17+
- Refresh `AGENTS.md` when repository commands, workflows, or packaged skills
18+
change.
19+
- Keep agent-facing guidance concise, specific, and aligned with the current
20+
checkout.
21+
- Preserve the repository's existing instruction structure and terminology.
22+
- Cross-check referenced commands, paths, and generated artifacts before
23+
finalizing updates.
24+
- Add or refresh notable repository references such as `README.md`, `docs/`,
25+
workflow files, and other canonical local entrypoints when they help agents
26+
navigate the project.
27+
28+
## Use When
29+
30+
- A PR changes setup, development, testing, sync, or contribution workflows
31+
documented in `AGENTS.md`.
32+
- The repository adds, removes, or renames packaged skills or project agents.
33+
- `AGENTS.md` drifted from the current repository behavior.
34+
35+
## Boundaries
36+
37+
- Do not duplicate or replace `README.md` when a human-facing doc update is the
38+
actual need.
39+
- Do not invent workflows or commands that are not present in the checkout.
40+
- Do not rewrite unrelated docs trees when only `AGENTS.md` needs maintenance.
41+
42+
## Primary Skill
43+
44+
- `create-agentsmd`
45+
46+
## Supporting Skills
47+
48+
- None by default.
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
---
2+
name: create-agentsmd
3+
description: Generate or refresh repository-level AGENTS.md files with actionable setup, workflow, testing, style, and contribution guidance for coding agents. Use when a repository is missing AGENTS.md, when an existing AGENTS.md is stale, or when agent-facing project instructions need to be aligned with the current checkout.
4+
---
5+
6+
# Fast Forward AGENTS.md
7+
8+
Use this skill to create or refresh a repository-root `AGENTS.md` that helps
9+
coding agents work effectively in the current project. Keep the file specific to
10+
the checked-out repository, verify commands and paths before writing them, and
11+
prefer concise instructions over generic explanations.
12+
13+
## Workflow
14+
15+
1. Inspect the repository first: language, package manager, build and test
16+
entrypoints, CI workflows, docs, and any existing `AGENTS.md`.
17+
2. Decide whether to create or update:
18+
- create `AGENTS.md` at the repository root when the file is missing;
19+
- update the existing file in place when it already contains repository-specific
20+
guidance worth preserving.
21+
3. Capture only repository-relevant instructions that an agent would not safely
22+
infer from code alone.
23+
4. Verify every command, path, workflow name, and generated artifact reference
24+
against the current checkout before finalizing the file.
25+
5. Keep the result aligned with the public `agents.md` guidance without copying
26+
generic filler into the repository.
27+
28+
## Required Coverage
29+
30+
- Project overview and architecture cues that affect implementation work
31+
- Setup, installation, and local development commands
32+
- Testing commands, focused test patterns, and quality gates
33+
- Code style, file-organization, and naming expectations that matter in review
34+
- Build, release, or deployment behavior when the repository exposes one
35+
- Pull request or contribution rules when they are discoverable from local files
36+
- Notable repository references such as `README.md`, `docs/`, workflow files, or
37+
generated-output locations when those links help an agent navigate the project
38+
39+
## Writing Rules
40+
41+
- Use direct, actionable language aimed at another coding agent.
42+
- Prefer exact commands in backticks instead of vague descriptions.
43+
- Mention real paths, scripts, workflow files, and generated outputs.
44+
- Keep `AGENTS.md` as a companion to `README.md`, not a duplicate of it.
45+
- Add links or path references to canonical repository surfaces when they are
46+
useful entrypoints for agents, especially `README.md`, `docs/`, `.github/workflows/`,
47+
and other notable local documentation or output directories.
48+
- Call out monorepo or nested-`AGENTS.md` precedence only when it actually applies.
49+
- Preserve valid repository-specific guidance when updating an existing file.
50+
- Do not invent commands, services, environment variables, or workflows that are
51+
not present in the checkout.
52+
53+
## Reference Guide
54+
55+
| Need | Reference |
56+
|------|-----------|
57+
| Section planning and optional coverage | [references/content-outline.md](references/content-outline.md) |
58+
| Final quality checks before finishing the file | [references/content-outline.md](references/content-outline.md) |
59+
60+
## Anti-patterns
61+
62+
- Do not paste a generic AGENTS template without inspecting the repository.
63+
- Do not describe tools or frameworks that are not present in the checkout.
64+
- Do not duplicate large sections of `README.md` when a short cross-reference is
65+
enough.
66+
- Do not leave placeholder text, TODO markers, or fake commands in the file.
67+
- Do not rewrite a good existing `AGENTS.md` from scratch when a focused refresh
68+
is enough.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
interface:
2+
display_name: "Fast Forward AGENTS.md"
3+
short_description: "Create AGENTS.md files for repositories"
4+
default_prompt: "Use $create-agentsmd to analyze this repository and write or refresh a focused AGENTS.md file at the project root."
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# AGENTS.md Content Outline
2+
3+
Use this reference when planning or reviewing a repository-level `AGENTS.md`.
4+
5+
## Core Sections
6+
7+
Include the sections that materially fit the repository:
8+
9+
- `Project Overview`
10+
- `Setup Commands`
11+
- `Development Workflow`
12+
- `Testing Instructions`
13+
- `Code Style`
14+
- `Build and Deployment`
15+
16+
## Optional Sections
17+
18+
Add these only when the repository clearly supports them:
19+
20+
- `Security Considerations`
21+
- `Monorepo Instructions`
22+
- `Pull Request Guidelines`
23+
- `Debugging and Troubleshooting`
24+
- `Additional Notes`
25+
26+
## What to Gather Before Writing
27+
28+
- Package manager and install command
29+
- Main build, dev, and test entrypoints
30+
- Focused test commands or patterns
31+
- Lint, format, static-analysis, or code-style commands
32+
- CI workflow locations in `.github/workflows/`
33+
- Deployment, publishing, or release commands if present
34+
- Canonical human-facing entrypoints such as `README.md`, `docs/`, wiki content,
35+
support files, or notable generated-output directories that agents may need to
36+
consult
37+
- Existing repository conventions from `README.md`, `composer.json`, `package.json`,
38+
`Makefile`, `pyproject.toml`, or similar project files
39+
40+
## Quality Checklist
41+
42+
- Every command exists in the checked-out repository.
43+
- Every referenced path is real and spelled correctly.
44+
- The file explains what agents need to know, not broad product marketing.
45+
- The guidance complements `README.md` instead of repeating it wholesale.
46+
- The instructions mention generated artifacts, sync workflows, or docs outputs
47+
when agents can affect them.
48+
- Helpful canonical references such as `README.md`, `docs/`, workflow files, or
49+
other notable repository paths are called out when they improve navigation.
50+
- The file uses concrete repository vocabulary rather than generic advice.
51+
- The final result is specific enough that another agent could start work without
52+
guessing the workflow.

.github/wiki

Submodule wiki updated from 831e581 to f5cf885

AGENTS.md

Lines changed: 39 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,19 @@ composer dev-tools reports # Generate docs frontpage and reports
4545
composer dev-tools:sync # Sync scripts, GitHub Actions, .editorconfig, wiki
4646
```
4747

48+
**Notable Specialized Commands:**
49+
50+
- `composer skills`: Synchronize packaged skills into consumer `.agents/skills`
51+
- `composer funding`: Sync funding metadata between `composer.json` and `.github/FUNDING.yml`
52+
- `composer codeowners`: Generate `.github/CODEOWNERS` from repository metadata
53+
- `composer gitattributes`: Manage export-ignore rules in `.gitattributes`
54+
- `composer gitignore`: Synchronize managed `.gitignore` content
55+
- `composer license`: Generate or refresh repository `LICENSE` files
56+
- `composer dependencies`: Run dependency analysis workflows
57+
- `composer metrics`: Generate PhpMetrics reports and related artifacts
58+
- `composer update-composer-json`: Normalize managed `composer.json` settings
59+
- `composer changelog:entry|check|next-version|promote|show`: Manage changelog-driven release workflows
60+
4861
## Testing Instructions
4962

5063
```bash
@@ -91,7 +104,7 @@ composer dev-tools tests -- --coverage=public/coverage
91104

92105
- Source code: `src/` (PSR-4: `FastForward\DevTools\`)
93106
- Tests: `tests/` (PSR-4: `FastForward\DevTools\Tests\`)
94-
- Commands: `src/Command/`
107+
- Commands: `src/Console/Command/`
95108
- PHPUnit events: `src/PhpUnit/Event/`
96109
- Rector rules: `src/Rector/`
97110
- Composer plugin: `src/Composer/`
@@ -112,7 +125,15 @@ composer dev-tools tests -- --coverage=public/coverage
112125

113126
## Build and Deployment
114127

115-
This is a Composer plugin - no build step required. The package is published to Packagist.
128+
This repository ships a Composer plugin plus the local `bin/dev-tools` binary,
129+
so there is no separate frontend or asset build step. The package is published
130+
to Packagist, while consumer repositories adopt workflows, packaged skills, and
131+
other managed assets through `composer dev-tools:sync`.
132+
133+
Release and publishing behavior is driven primarily through
134+
`.github/workflows/changelog.yml`, `reports.yml`, and `wiki.yml`, with packaged
135+
skills living under `.agents/skills/` and mirrored project-agent prompts under
136+
`.agents/agents/`.
116137

117138
**Package Details:**
118139

@@ -122,8 +143,6 @@ This is a Composer plugin - no build step required. The package is published to
122143

123144
## Pull Request Guidelines
124145

125-
**Title Format:** `[<area>] Brief description (#<issue-number>)`
126-
127146
**Required Checks:**
128147

129148
```bash
@@ -138,6 +157,20 @@ composer dev-tools
138157
- PHPDoc must be valid
139158
- Coverage must meet threshold
140159
- Rector should handle refactoring automatically
160+
- Follow `.github/pull_request_template.md` and include issue linkage,
161+
verification notes, documentation/generated-output review, and changelog
162+
status
163+
164+
## Canonical References
165+
166+
- `README.md`: high-level command surface, architecture overview, and consumer-facing context
167+
- `docs/commands/`: command-specific behavior and option details
168+
- `docs/usage/` and `docs/internals/`: workflow, reporting, release, and implementation notes
169+
- `.github/workflows/`: CI and release automation truth, especially `tests.yml`, `reports.yml`, `wiki.yml`, and `changelog.yml`
170+
- `.github/pull_request_template.md`: expected PR structure and reviewer checklist
171+
- `.agents/skills/`: packaged procedural skills shipped to consumer repositories
172+
- `.agents/agents/`: repository-specific role prompts mirrored through `.github/agents`
173+
- `.github/wiki`: generated or synchronized wiki content published by repo workflows
141174

142175
## Additional Notes
143176

@@ -150,6 +183,7 @@ composer dev-tools
150183
## Skills Usage
151184

152185
- **Creating/Updating Tests**: Use skill `phpunit-tests` in `.agents/skills/phpunit-tests/` for PHPUnit tests with Prophecy
186+
- **Creating/Refreshing AGENTS.md**: Use skill `create-agentsmd` in `.agents/skills/create-agentsmd/` to generate or update repository-root AGENTS instructions for coding agents
153187
- **Generating Documentation**: Use skill `sphinx-docs` in `.agents/skills/sphinx-docs/` for Sphinx documentation in `docs/`
154188
- **Updating README**: Use skill `package-readme` in `.agents/skills/package-readme/` for generating README.md files
155189
- **Updating PHPDoc / PHP Style**: Use skill `phpdoc-code-style` in `.agents/skills/phpdoc-code-style/` for PHPDoc cleanup and repository-specific PHP formatting
@@ -165,6 +199,7 @@ procedural source of truth.
165199

166200
- Use `issue-editor` for issue drafting, refinement, comments, updates, and closure workflows.
167201
- Use `issue-implementer` for issue-to-branch-to-PR execution.
202+
- Delegate to `agents-maintainer` when repository `AGENTS.md` guidance needs to be created, refreshed, or realigned with current workflows.
168203
- Delegate to `test-guardian` whenever behavior changes, regressions, or missing coverage are involved.
169204
- Delegate to `php-style-curator` for PHPDoc cleanup, file-header normalization, and repository style conformance.
170205
- Delegate to `readme-maintainer` when public commands, installation, usage, links, or badges change.

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1010
### Added
1111

1212
- Add CODEOWNERS generation and sync support for consumer repositories (#67)
13+
- Package a create-agentsmd skill for repository-level AGENTS.md authoring (#128)
14+
- Add an agents-maintainer project agent for ongoing AGENTS.md upkeep (#128)
1315

1416
## [1.13.0] - 2026-04-19
1517

README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,10 @@ DevTools integrates with consumer repositories in two ways. The Composer plugin
224224
exposes the command set automatically after installation, and the local binary
225225
keeps the same command vocabulary when you prefer running tools directly from
226226
`vendor/bin/dev-tools`. The consumer sync flow also refreshes `.agents/skills`
227-
so agents can discover the packaged skills shipped with this repository.
227+
so agents can discover the packaged skills shipped with this repository,
228+
including workflows for GitHub issue/PR handling, changelog maintenance, PHP
229+
quality tasks, Sphinx docs, README generation, and repository `AGENTS.md`
230+
authoring.
228231

229232
## 🏗️ Architecture
230233

0 commit comments

Comments
 (0)