原始内容
Self-Improving Agent Template
Just paste this into any agent to apply it to a repo
https://github.com/Grail-Computer/Self-Improving-Agent
initegrate this in this repo by updating AGENTS.md and use https://skills.sh/ to install the skill
A starter template for making any project's AI coding agents compound in effectiveness over time.
What's Inside
├── AGENTS.md # Repo memory — always-on context for agents
└── skills/
└── self-improving-agent/
└── SKILL.md # Meta-skill: how to improve AGENTS.md and create new skills
AGENTS.md
Repository-level context that coding agents read at the start of every session. Includes:
- Codebase Map — so agents navigate without wandering
- Local Norms — build, test, style, and dependency rules
- Guardrails — what agents must never do
- Patterns & Gotchas — hard-won knowledge from past sessions
- Self-Correction Protocol — how this file stays alive and accurate
Self-Improving Agent Skill
A meta-skill that teaches agents how to improve themselves. Covers:
- Post-task reflection (diagnose what to improve)
- Updating AGENTS.md (map, norms, guardrails, gotchas)
- Creating new skills from repeated workflows
- Scope decisions (repo-local → global → shared)
- Quality validation for improvements
Usage
For a New Project
- From your project root, run:
npx skills add "https://github.com/Grail-Computer/Self-Improving-Agent" - Update the Codebase Map in
AGENTS.mdto match your project structure. - Replace the italicized placeholder entries with your project's actual norms.
- Start working — the self-correction protocol will keep things current.
Day-to-Day
- Agents read
AGENTS.mdautomatically at the start of each session. - After completing tasks, agents invoke the
self-improving-agentskill to reflect and persist learnings. - Over time,
AGENTS.mdaccumulates the knowledge that makes each session better than the last.
Adding New Skills
When a workflow repeats, create a new skill:
skills/<skill-name>/
├── SKILL.md # The playbook
├── scripts/ # Optional helper scripts
└── examples/ # Optional reference outputs
See the self-improving-agent skill for the full procedure.
The Compounding Loop
Work → Complete → Reflect → Record → Next task starts from a better baseline
Each improvement makes future improvements easier. That's how agents compound.