Agent Integration
How pair connects with AI coding assistants through the bridge pattern, supporting multiple agents with a single source of truth.
pair works with any AI coding assistant that can read project files. It uses a bridge pattern to connect different AI tools to a single source of truth — the Knowledge Base in .pair/.
The Bridge Pattern
Each AI tool has its own configuration format for project-level instructions. pair installs bridge files for each supported tool:
All bridge files point to .pair/. There is one source of truth: the Knowledge Base and adoption files. The bridge files simply tell each AI tool where to find it.
AGENTS.md
The universal bridge file. It sits at the repository root and contains:
- Quick start instructions (which how-to file to read for the current task)
- Essential commands (build, test, lint)
- Key references (adoption files, guidelines, templates)
- Quick rules (testing requirements, adoption checks, commit conventions)
Claude Code and other agents that support AGENTS.md read this file automatically when they enter a repository.
Tool-Specific Bridges
Each AI tool has its own discovery mechanism:
- GitHub Copilot reads
.github/copilot/for custom instructions - Cursor reads
.cursor/rules/for project-specific rules - Claude Code reads
AGENTS.mdand.claude/for skills and instructions
The bridge files are maintained by pair's agents asset registry and update when you run pair-cli update.
Multi-Agent Support
A team can have developers using different AI tools. The bridge pattern ensures they all follow the same standards:
- Developer A uses Claude Code → reads
AGENTS.md→ follows.pair/guidelines - Developer B uses Cursor → reads
.cursor/rules/→ follows.pair/guidelines - Developer C uses Copilot → reads
.github/copilot/→ follows.pair/guidelines
Same Knowledge Base, same adoption files, same standards. The AI tool is an implementation detail.
Skills Distribution
Skills are distributed to multiple AI tool directories simultaneously:
The canonical copy lives in .claude/skills/. Secondary targets (.github/skills/, .cursor/skills/) receive symlinks, ensuring all tools share the exact same skill definitions without duplication.
On Windows, where symlinks require elevated permissions, pair falls back to full copies.
How Agents Discover Context
When an AI assistant starts a session in a pair-enabled project:
- Bridge file — the AI reads its tool-specific bridge file (or
AGENTS.md) - Task matching — the bridge directs it to the relevant how-to guide for the current task
- Adoption loading — the AI reads adoption files to understand project constraints
- Guideline loading — the AI reads relevant guidelines for the task at hand
- Execution — the AI follows the how-to guide, constrained by adoption files and guidelines
This discovery happens automatically at session start. The developer does not need to manually point the AI to documentation.
Adding New Agent Support
The bridge pattern is extensible. To support a new AI tool:
- Create a bridge file in the tool's expected location
- Point it to
.pair/for the Knowledge Base - Add it to the
agentsasset registry for automatic updates
The Knowledge Base and adoption files remain unchanged — only a new bridge file is needed.