Skip to content

Commit 88c4276

Browse files
chore: add AGENTS.md (#9)
1 parent c214f3e commit 88c4276

1 file changed

Lines changed: 128 additions & 0 deletions

File tree

AGENTS.md

Lines changed: 128 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,128 @@
1+
# AGENTS.md
2+
3+
## 1. Purpose & Scope
4+
This file is the operating manual for AI coding agents working in this repository.
5+
Use it to make consistent, safe, and testable changes to the skills library.
6+
Primary repo goal: build and evolve reusable AI skills for k6 planning, artifact generation, and validation.
7+
Primary audience: coding agents (Claude, Cursor, Copilot, Grok, and similar).
8+
9+
## 2. Repository Snapshot
10+
Core folders:
11+
- `skills/k6-plan/`: planning skill for deterministic k6 test plans.
12+
- `skills/k6-builder/`: implementation skill for runnable k6 artifacts.
13+
- `skills/k6-validate/`: validation skill for script quality and safety checks.
14+
- `scripts/`: auxiliary repository scripts when needed.
15+
16+
Operating model:
17+
- Skills are instruction-driven via `SKILL.md` files.
18+
- `references/` subfolders provide deeper domain guidance per skill.
19+
- Iterative quality improvements are tracked in evaluation artifacts.
20+
21+
## 3. Operating Principles
22+
### Think Before Coding
23+
- State assumptions explicitly before implementing.
24+
- If multiple interpretations exist, surface them instead of silently choosing one.
25+
- Prefer a simpler approach when it solves the request.
26+
- Stop and ask when ambiguity blocks correctness.
27+
28+
### Simplicity First
29+
- Implement the minimum solution that satisfies the request.
30+
- Do not add speculative flexibility, config, or abstractions.
31+
- Avoid overengineering; simplify aggressively when possible.
32+
33+
### Surgical Changes
34+
- Touch only the files and lines needed for the request.
35+
- Match existing style and conventions.
36+
- Do not refactor unrelated code.
37+
- Remove only the unused code created by your own changes.
38+
39+
### Goal-Driven Execution
40+
- Translate requests into verifiable success criteria.
41+
- For multi-step work, define steps and a validation check per step.
42+
- Iterate until checks pass or blockers are explicit.
43+
44+
## 4. Skill Architecture Standard
45+
Each skill must be self-contained and predictable.
46+
47+
Required structure:
48+
- `skills/<skill-name>/SKILL.md`
49+
- `skills/<skill-name>/references/` with focused support docs
50+
51+
`SKILL.md` baseline:
52+
- YAML frontmatter with `name`, `description`, `license`, and metadata.
53+
- Clear trigger language in `description` using “Use when...”.
54+
- Deterministic workflow instructions and explicit output contract.
55+
- Tool/fallback behavior when required inputs are missing.
56+
57+
## 5. Skill Lifecycle Workflow
58+
Default lifecycle in this repository:
59+
1. Plan with `k6-plan`.
60+
2. Build runnable artifacts with `k6-builder`.
61+
3. Validate quality and safety with `k6-validate`.
62+
63+
Lifecycle rules:
64+
- Preserve semantic continuity across plan, build, and validate outputs.
65+
- Keep thresholds, scenario intent, and protocol expectations aligned.
66+
- Always include a clear next step for downstream execution.
67+
68+
## 6. How to Create a New Skill
69+
Use this checklist:
70+
1. Define a narrow, high-value capability.
71+
2. Create a concise `description` with strong trigger phrases.
72+
3. Add frontmatter metadata and version.
73+
4. Define required inputs, clarification logic, and fallback behavior.
74+
5. Specify deterministic output sections in fixed order.
75+
6. Add a `references/README.md` and focused support docs.
76+
7. Include at least 3 invocation examples and one edge-case example.
77+
8. Define quality invariants and explicit handoff to adjacent skills.
78+
79+
## 7. How to Iterate Existing Skills
80+
Iteration loop:
81+
1. Detect a concrete failure mode from eval outputs.
82+
2. Apply the smallest change that fixes the failure.
83+
3. Re-run evaluation and compare against previous iteration.
84+
4. Keep improvements that raise reliability without regressions.
85+
86+
Iteration rules:
87+
- Change one concern at a time when possible.
88+
- Do not alter output contracts without strong justification.
89+
- Document assumption changes directly in `SKILL.md` where behavior changes.
90+
- Prioritize deterministic behavior over stylistic rewrites.
91+
92+
## 8. Quality & Testing Standards
93+
Minimum quality expectations:
94+
- Strong pass rate against skill-specific assertions.
95+
- Clear advantage versus baseline (without skill) behavior.
96+
- Stable behavior across repeated runs.
97+
- Coverage of edge cases and ambiguity handling.
98+
99+
Evaluation artifacts to maintain:
100+
- `grading.json`, `response.txt`, `timing.json`, `benchmark.json`.
101+
102+
Scoring model used in this repo:
103+
- `Score = (PassRate * 0.40) + (Advantage * 0.30) + (Consistency * 0.20) + (EdgeCoverage * 0.10)`
104+
105+
## 9. Hard Boundaries (Do Not Cross)
106+
- Do not silently invent missing requirements.
107+
- Do not reorder mandatory output contract sections.
108+
- Do not add hidden side effects or undocumented behavior.
109+
- Do not introduce secrets, credentials, or hardcoded sensitive values.
110+
- Do not make broad refactors for narrow tasks.
111+
- Do not commit changes under `docs/` in this repository.
112+
113+
## 10. Commit Scope Rules
114+
Commit policy for agent work:
115+
- Keep commits scoped to the user request.
116+
- Ensure every changed line is traceable to an explicit goal.
117+
- Prefer one logical change set per commit.
118+
- Include verification evidence in PR notes or commit message context.
119+
120+
Recommended branch naming:
121+
- `docs/add-agents-md` for this change.
122+
- `chore/<area>-<intent>` for maintenance.
123+
- `feat/<area>-<capability>` for behavior additions.
124+
125+
Before finalizing:
126+
- Confirm file scope, line scope, and requirement coverage.
127+
- Confirm output language is English.
128+
- Confirm the document remains concise and actionable.

0 commit comments

Comments
 (0)