This document describes how AI coding agents (GitHub Copilot, Claude Code, etc.) are integrated into this project and how the supporting artifacts are structured.
The workflow is built on three open standards:
| Standard | Purpose | URL |
|---|---|---|
| agents.md | Central entry point — gives agents project context at startup | https://agents.md/ |
| Specifica | Spec-driven development — machine- and human-readable feature specs | https://specifica.org |
| Agent Skills | On-demand procedural knowledge — loaded by agents when relevant | https://agentskills.io/ |
GitHub Copilot in VS Code natively supports the artifacts described in this
document. Use Chat: Open Customizations (Command Palette Ctrl+Shift+P)
to explore and edit all active customization files in one place.
| Artifact | VS Code mechanism |
|---|---|
AGENTS.md |
Loaded automatically as an instructions file by GitHub Copilot. Shown in Chat: Open Customizations under "Instructions". |
.agents/skills/*/SKILL.md |
Skill files are listed in Chat: Open Customizations under "Skills". The agent sees the frontmatter description at startup and loads the full file on demand. |
.github/agents/*.agent.md |
Custom agents are listed in the agent picker dropdown. Select an agent to activate its persona, tool set, and instructions. |
spec/**/*.md |
Not loaded automatically — agents follow links from AGENTS.md and read spec files with file-read tools as needed. |
To verify which files are active, open the Copilot Chat panel, click the settings icon, and select Open Customizations. All discovered instructions and skill files are listed there.
Custom agents (see Custom agents in VS Code) combine a fixed persona, a curated tool set, and pre-loaded instructions into a single, selectable configuration. Unlike skills — which are loaded on demand by any agent — a custom agent is the active agent for the whole conversation.
.github/agents/spec-to-code.agent.md
This agent's job is to translate Specifica spec changes into matching source
code. Switch to it whenever a spec.md or design.md was updated and the code
needs to catch up.
How to use it:
- Open Copilot Chat and select spec-to-code from the agent dropdown
(or type
@spec-to-code). - Tell it what changed:
The
arc-building/spec.mdnow requires that empty annotation tables are skipped silently instead of raising a warning. Please implement this. - The agent reads the spec, finds the affected code in
builder.pyand its tests, applies the change, runsruff formatandpytest, and reports which requirements were implemented.
Tool set: file read/write, codebase search, terminal (for formatter and tests), Problems tab — no browser, no git push.
When to use it vs plain Agent mode:
| Situation | Use |
|---|---|
| Spec changed, code needs to follow | spec-to-code |
| Exploratory coding, no spec context needed | default Agent mode |
| Writing a new spec from scratch | default Agent mode + create-specifica-feature skill |
AGENTS.md at the repository root is the single entry point for
all AI agents. It is automatically loaded by compatible agents (GitHub Copilot,
Claude Code, and others) at the start of every session.
It contains only what every agent needs for every task:
- Tech stack and key versions
- Project structure (with links to
spec/and component specs) - Essential commands (
uv,ruff,pytest) - Architecture & Design section — two-level spec index
- Code quality standards and file modification workflow
Principle: AGENTS.md links to specs instead of duplicating their content.
It stays short and current.
Specs follow the Specifica convention: each feature
lives in its own folder with a spec.md (what it does) and optionally a
design.md (key decisions and rationale).
spec/ ← Project-level (cross-cutting concerns)
├── principles.md # Foundation contract, project values
├── configuration/ # ConfigWrapper pattern, env overrides, secrets
└── demo-environment/ # Local deployment setup
middleware/
└── sql_to_arc/
└── spec/ ← Component-level (sql_to_arc internals)
├── sql-to-arc-conversion/
├── arc-building/
├── database-access/
└── api-upload/
Project-level specs cover concerns that cut across components or that don't belong to any single component (deployment, shared patterns, principles).
Component-level specs live next to the code they describe
(middleware/<component>/spec/). Each future component gets its own spec/
folder. This makes specs portable and keeps context close to the code.
spec.md— requirements: what the feature must do, acceptance criteria, interface contracts. Written before implementation.design.md— decisions: why it was built this way, key trade-offs, alternatives rejected. Written alongside or after implementation.
Skills follow the Agent Skills open standard. Each
skill is a folder containing a SKILL.md file with YAML frontmatter and
Markdown instructions.
.agents/
└── skills/
├── arctrl/
│ └── SKILL.md # How to use the arctrl Python library
├── config-wrapper/
│ └── SKILL.md # How to use ConfigWrapper / ConfigBase
└── create-specifica-feature/
└── SKILL.md # How to create a new Specifica feature folder
Skills are project-neutral — they document a library or pattern in general terms. Project-specific usage (concrete prefixes, mock paths, accepted trade-offs) lives in the corresponding feature spec, not in the skill.
- Discovery: At startup, agents see only the
nameanddescriptionfrom each skill's frontmatter — just enough to know when a skill might apply. - Activation: When a task matches a skill's description, the agent loads
the full
SKILL.mdinto context. - Execution: The agent follows the instructions, optionally loading referenced files or scripts.
Skills are activated on demand, keeping the agent's context window lean.
When an agent starts a task it:
- Loads
AGENTS.md→ gets project context, commands, and spec links. - If the task touches a feature → reads the relevant
spec.md/design.md. - If the task requires library knowledge → loads the matching skill.
- After editing → runs
uv run ruff format .anduv run pytest, checks the VS Code Problems tab for Pylance / Mypy / Ruff diagnostics.
AGENTS.mdlinks tospec/configuration/.- Agent reads
spec/configuration/spec.md→ learns the constraints (noos.environ, add toConfig, useSecretStrfor secrets). - Agent loads the
config-wrapperskill → learns the exact Pydantic pattern and how to write the test. - Agent edits
config.py, formats, and runs the tests.
AGENTS.mdlinks tomiddleware/sql_to_arc/spec/arc-building/.- Agent reads
arc-building/design.md→ understands key decisions (noOntologySourceReference, 7-tuple column key, explicit GC). - Agent loads the
arctrlskill → gets the correct API surface. - Agent edits
builder.pyormapper.py, formats, runs tests.
VS Code has built-in support for creating and managing skills (see Use Agent Skills in VS Code).
Type /create-skill in the Copilot Chat input and describe what you need:
/create-skilla skill for thehttpxlibrary covering async requests, timeout handling, and authentication headers
Copilot asks clarifying questions and writes the complete
.agents/skills/httpx/SKILL.md with valid frontmatter and instructions.
Type /skills in the Chat input to open the Configure Skills menu directly.
Select New Skill (Workspace), choose a location, and enter a name.
VS Code creates the folder and an empty SKILL.md scaffold to fill in.
Alternatively, open Chat: Open Customizations from the Command Palette
(Ctrl+Shift+P), select the Skills tab, and choose New Skill from
the dropdown.
Verify the new skill appears under the Skills tab in Chat: Open Customizations after saving the file.
Rules that apply regardless of creation method:
namemust match the folder name; lowercase letters and hyphens only.descriptionmust say both what the skill does and when to use it.- Keep the skill project-neutral — no FAIRagro-specific paths or prefixes. Project-specific constraints belong in the corresponding feature spec.
- Reference the skill from the relevant feature spec so agents know to load it.
The create-specifica-feature skill guides Copilot through the full process.
Example prompt (Copilot Chat, Agent mode):
Use the
create-specifica-featureskill to create a new component-level spec for a "result-export" feature inmiddleware/sql_to_arc. The feature writes ARC RO-Crate files to a local output directory as a fallback when the API is unreachable.
Copilot will:
- Load the
create-specifica-featureskill. - Choose the right location:
middleware/sql_to_arc/spec/result-export/(component-level, not project-level — affects only this component). - Create
spec.mdwith a one-sentence purpose,## Requirementsas- [ ]checkboxes, and## Edge Casesas scenario → outcome pairs. - Create
design.mdwith a## Key Decisionssection, each decision preceded by a—reasoning clause. - Add a link to
AGENTS.mdunder Architecture & Design.
The finished folder will look like:
middleware/sql_to_arc/spec/result-export/
├── spec.md ← what it must do
└── design.md ← how it works and why
For detailed formatting rules, see
.agents/skills/create-specifica-feature/SKILL.md.