This toolkit is designed to be forked and adapted. Every component can be modified, extended, or removed to fit your team's stack and conventions.
Location: .github/agents/<name>.agent.md
---
name: "my-agent"
description: "One-sentence description for discovery"
tools: ["read", "edit", "search", "execute", "github/*"]
---
You are an expert in [domain]. Your role is to [purpose].
## Workflow
1. Read the issue or user request
2. Analyze the codebase to understand context
3. Implement the solution
4. Verify correctness
## Constraints
- Always [rule 1]
- Never [rule 2]
- Prefer [approach A] over [approach B]- Filename: kebab-case matching the
namefield →my-agent.agent.md - Tools: Use the full set unless the agent specifically shouldn't write code (e.g., read-only reviewers use
["read", "search"]) - Structure: Workflow → Constraints. Keep the workflow sequential, constraints as rules.
- Description: Must be discoverable — describe what the agent does in one sentence
---
name: "remix-expert"
description: "Expert in Remix development. Applies loader/action patterns, nested routes, and Remix 3+ best practices."
tools: ["read", "edit", "search", "execute", "github/*"]
---
You are an expert in Remix development targeting Remix 3+ with React Router v7.
## Workflow
1. Understand the requirement
2. Explore existing route structure and conventions
3. Implement using Remix patterns (loaders, actions, nested routes)
4. Ensure proper error boundaries and loading states
5. Write or update tests
## Constraints
- Use `loader` for data fetching, `action` for mutations
- Prefer nested routes over flat routes
- Always add error boundaries to route modules
- Use `defer` for non-critical data
- Follow progressive enhancement — forms must work without JSLocation: .github/prompts/<name>.prompt.md
---
description: "One-sentence description for the / menu"
agent: "agent"
tools: [read, edit, search, execute]
---
## Task
[What the prompt should do]
## Input
The user will provide: [expected input]
## Steps
1. [Step 1]
2. [Step 2]
3. [Step 3]
## Output
Produce: [expected output format]
## Rules
- [Rule 1]
- [Rule 2]- One task per prompt: Don't combine "write tests AND documentation" in one prompt
- Be specific about output: "Generate a TypeScript interface" is better than "Generate types"
- Limit tools: A read-only review prompt should use
tools: [read, search]— notedit - Include model (optional):
model: "claude-sonnet-4"for tasks needing strong reasoning
Location: .github/instructions/<name>.instructions.md
---
applyTo: '**/*.py'
---
## Python Conventions
- Use Python 3.12+ features
- Type hints on all public functions
- Use `pathlib` over `os.path`
- Prefer f-strings over `.format()`
- Use `match` statements for complex branching---
description: "GraphQL API design conventions"
---
## GraphQL Conventions
- Use Relay-style connections for pagination
- Prefix mutations with the resource: `createUser`, `updatePost`
- Always include `errors` in mutation responses
- Use input types for mutation arguments- One concern per file: Don't mix Python style with testing rules
- Keep it short: Instructions share context window space with your code
- Use globs wisely:
**/*.tsxcatches all TSX files;src/components/**/*.tsxlimits scope - Avoid conflicts: Two instructions with overlapping globs and contradictory rules cause unpredictable behavior
Location: .github/skills/<skill-name>/SKILL.md
---
name: "my-skill"
description: "What the skill does — one sentence"
---
## Context
[When and why to use this skill]
## Inputs
The user provides:
- **Required**: [what's needed]
- **Optional**: [what's helpful]
## Procedure
### Step 1: [Name]
[Detailed instructions for this step]
### Step 2: [Name]
[Detailed instructions for this step]
### Step 3: [Name]
[Detailed instructions for this step]
## Output Template
```markdown
# [Title]
## Section 1
[template]
## Section 2
[template]
`` `- Self-contained: Include all context in the SKILL.md — don't reference external files
- Structured procedure: Number every step so the agent can follow them in order
- Output template: Include a literal template so output is consistent across invocations
- Test it: Invoke the skill with different inputs to verify it handles edge cases
Location: .github/hooks/<name>.json + .github/hooks/scripts/<name>.sh
Config (.github/hooks/my-hook.json):
{
"hooks": [
{
"event": "PostToolUse",
"tools": ["insert_edit_into_file", "replace_string_in_file"],
"script": ".github/hooks/scripts/my-hook.sh",
"permissionDecision": "allow"
}
]
}Script (.github/hooks/scripts/my-hook.sh):
#!/bin/bash
set -euo pipefail
# Your logic here
# For PreToolUse: echo "allow", "deny", or "ask"
# For PostToolUse: run formatting, linting, etc.
echo "allow"chmod +x .github/hooks/scripts/my-hook.sh- Keep scripts fast: They run on every matching tool call — under 1 second is ideal
- Fail open: Default to
echo "allow"if your check encounters an error - Scope narrowly: Use the
toolsarray to limit which tool calls trigger the hook - Test locally:
bash .github/hooks/scripts/my-hook.shbefore relying on it
The workspace instructions file (.github/copilot-instructions.md) provides global context for every Copilot interaction. Customize it for your project:
# Project Instructions for GitHub Copilot
## About This Project
This is [project name] — [one-sentence description].
## Tech Stack
- **Language**: [e.g., TypeScript 5.7+]
- **Framework**: [e.g., Next.js 15 with App Router]
- **Database**: [e.g., PostgreSQL 17 with Prisma]
- **Testing**: [e.g., Vitest + Playwright]
## Code Conventions
- [Convention 1]
- [Convention 2]
## Architecture
- [Pattern, e.g., feature-based folder structure]
- [Data flow, e.g., Server Components → Server Actions → Database]
## Common Commands
- `npm run dev` — Start development server
- `npm run test` — Run tests
- `npm run build` — Production buildIf your project only uses TypeScript/React:
# Remove Elixir/Phoenix agents
rm .github/agents/elixir-expert.agent.md
rm .github/agents/phoenix-expert.agent.md
# Remove Elixir instruction
rm .github/instructions/elixir.instructions.md
# Remove migration instruction (if not using SQL migrations)
rm .github/instructions/migrations.instructions.mdIf you don't need issue management workflows:
rm .github/workflows/duplicate-issue-detector.yml # or just the caller
rm .github/workflows/stale-issue-manager.yml
rm .github/workflows/issue-quality-enhancer.ymlFor the absolute minimum useful configuration:
.github/
├── copilot-instructions.md # Project context
├── instructions/
│ └── [your-language].instructions.md
├── prompts/
│ ├── write-tests.prompt.md
│ └── commit-message.prompt.md
└── agents/
└── [your-framework]-expert.agent.md
- Start minimal, grow gradually: Don't install everything at once — add components as you need them
- Version your customizations: Commit all
.github/changes so the team shares the same setup - Review monthly: Check if instructions and prompts are still relevant to your current practices
- Team alignment: Discuss conventions before encoding them in instructions — they affect everyone
- Test with real work: Use each new component on actual tasks before committing to it