# espalier init

> Discover codebase patterns and generate structured rules, skills, and quality gates for AI coding agents.

espalier init is a free AI agent skill on Agensi by Junhan Liu, in Agents & Orchestration. It loads into your AI agent through the Agensi MCP server, always in its latest approved version.

- Price: Free
- Creator: [Junhan Liu](https://www.agensi.io/creators/junhan-liu)
- Category: [Agents & Orchestration](https://www.agensi.io/skills/agents-orchestration)
- Uses: 2
- Version: 1.0
- Last updated: 2026-10-04
- Security: scan passed (2026-10-04); every new listing is also reviewed by a person
- Listing: https://www.agensi.io/skills/espalier-init
- Tags: ai-agents, prompt-engineering, llm-ops, automation, code-review

## About this skill

Setting up AI agents to work on an existing codebase often leads to "hallucinated" patterns that don't match your project's actual conventions. This skill solves that by automating the discovery of your architecture, naming conventions, and unwritten rules, then encoding them into machine-enforceable constraints.

### What it does
- **Codebase discovery** scans your repository to extract real-world architecture, naming patterns, and error-handling strategies.
- **Constraint generation** produces structured rules, skill definitions, and wiki pages that guide AI behavior.
- **Quality gate installation** sets up pre-push and post-tool hooks to block code that violates your project standards.
- **Multi-platform wiring** configures Claude Code, Codex, and GitHub Copilot with project-specific instructions and symlinks.
- **Sub-agent orchestration** defines specialized coder, reviewer, and security personas with restricted tool access.

### How it works
1. **Decision phase** prompts for merge strategies, tool access scopes, and target platforms.
2. **Scout phase** runs parallel analysis tools to map architecture, coding patterns, and security surfaces.
3. **Synthesis phase** generates the `espalier/` directory containing rules, skills, and project wiki.
4. **Bootstrap phase** executes a shell-based wiring process to link the generated system into your IDE and CLI tools.

### Frameworks & tools
This skill is framework-agnostic but includes specialized scouts for TypeScript, Python, and Go. It integrates directly with Claude Code, GitHub Copilot, and Codex, utilizing shell scripts for quality gate enforcement.

### Why this beats prompting it yourself
Generic system prompts can't account for the unique, unwritten rules of your specific codebase. This skill discovers those rules from your actual source code, ensuring AI-generated changes follow your exact patterns without manual prompt engineering.

### Use cases
- Onboarding AI agents to a legacy codebase with complex, undocumented patterns.
- Standardizing AI output across a large team to ensure consistent architecture.
- Automating architectural linting and security boundary checks at the agent level.
- Scaffolding a new project with "Decide-Then-Bind" path to enforce architectural decisions from day one.

### Known limitations
Requires a functional Bash environment for the bootstrap phase. Language-specific boundary checks are currently optimized for TypeScript, Python, and Go.

## Requires

- jest
- Node.js
- vitest
- mocha

## How to use this skill

1. Connect your AI agent to Agensi once: add the MCP server https://mcp.agensi.io/mcp/auth and sign in with your Agensi account (OAuth, no API key). Steps for Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and other agents: https://www.agensi.io/docs/mcp-setup
2. Ask your agent: "Use the espalier init skill from Agensi" and describe your task.
3. Your agent loads the skill from Agensi when it needs it. Nothing is downloaded.

## Frequently asked questions

### How does 'espalier init' differ from simply giving an AI agent a standard system prompt?

Unlike static system prompts, this skill acts as a 'scout' that analyzes your existing repo to identify project-specific patterns, ensuring AI agents follow your unique naming conventions and architecture instead of generic defaults.

### Which AI agents and coding tools is this skill compatible with?

The skill generates a structured 'espalier/' directory containing rules and skills that are compatible with Claude Code, GitHub Copilot, and Codex, and it uses shell-based wiring to integrate these into your IDE and CLI.

### What exactly is included in the 'espalier init' package?

You receive the complete orchestration suite, including the discovery scouts for TypeScript, Python, and Go, the synthesis engine for generating rules, and the bootstrap scripts for setting up quality gates and IDE wiring.

### Are there any specific system requirements or environment dependencies for installation?

It requires a Bash-compatible environment (Linux, macOS, or WSL) to execute the bootstrap phase and set up the local symlinks and pre-push quality hooks.

### Can I update the generated rules if my project's architecture changes over time?

Yes, the skill is designed for the 'Bootstrap' phase, allowing you to re-run the Scout and Synthesis phases as your codebase evolves to capture new patterns and update your agent's constraints.

### Is this skill limited to specific programming languages?

While it works with any language, it features specialized 'scouts' optimized to recognize the specific idioms, error-handling, and structures common in TypeScript, Python, and Go environments.

---

Source: [Agensi](https://www.agensi.io), the marketplace of skills for AI agents. Any MCP-compatible agent (Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and more) connects at https://mcp.agensi.io/mcp/auth and signs in with an Agensi account; setup for every agent: https://www.agensi.io/docs/mcp-setup. Append .md to any skill, guide or docs address on agensi.io for its markdown version.
