Pi Roles — Development skill for Claude Code
Unified composable roles and dynamic skill scoping for Pi coding agent and subagents.
How to install Pi Roles
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open junjiezhou1122/pi-roles and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What Pi Roles does
Unified composable roles and dynamic skill scoping for Pi coding agent and subagents.
Alternatives in Development
- Coding Agent Session Search — Unified TUI and CLI to index and search your local coding agent session history across 11+ providers (Codex, C 708 ★
- React Native Restate — Build a full-stack Real Estate app from scratch with Google Authentication, dynamic routing, and more 678 ★
- Opc — OPC — One Person Company 193 ★
README
pi-roles
Unified composable roles and dynamic skill scoping for Pi coding agent and subagents.
The Problem
- Context Bloat: Loading 40+ skills into Pi injects thousands of tokens of XML descriptions into the system prompt on every turn. This wastes budget and degrades instruction following.
- Harness Schizophrenia: Subagents get isolated roles and skill scoping, but the interactive main agent is stuck as an unspecialized generalist carrying every skill at once.
- Monolithic Prompts: Teams write giant 600-line system prompts that try to do everything, instead of composing small, focused capabilities.
The Solution
**Define once. Run as the main agent, or dispatch as a subagent.**
~/.pi/agent/agents/.md
│
┌────────────────┴────────────────┐
▼ ▼
Main Agent (/role) Subagent (subagent tool)
Embody the role interactively Dispatch to run in background
Scoped skills & system prompt Isolated child session
Features
- Composition over Inheritance: Roles can compose other roles via
roles: [role-a, role-b]. Skills, tools, and instructions are recursively resolved and deduplicated. - Dynamic Skill Scoping: When a role is active, only its declared skills appear in
. Shrinks prompt overhead by up to 80%. - On-Demand Skill Loading: Model can call
load_skillto pull in an unlisted skill temporarily when an unexpected subtask arises. - Startup Ergonomics:
- CLI flag:
pi --role architect - Project default:
"defaultRole": "architect"in.pi/settings.json - Interactive TUI: type
/roleto open a keyboard-navigable role selector
- CLI flag:
- Full Subagent Compatibility: Standard Agent Markdown format compatible with
pi-subagents.
Role Definition Format
Save roles to `~/.pi/agent/agents/.md` (global) or `.pi/agents/.md` (project):
--
Related Skills
My Pi
Composable Pi coding agent with MCP, LSP, agent chains, prompt presets, and local eval telemetry
Agent Isle
A Dynamic Island for your coding agents — a native macOS notch monitor for Claude Code, Grok, Copilot and more
Autoharness
macOS coding-agent control center: one objective, routed to direct execution, a bounded loop, a swarm, or a dy
Oh My Multica
Production-grade software delivery for coding-agent teams on Multica — dynamic planning, deterministic executi
Orkestra
Local-first orchestration runtime for multiple autonomous coding agents (Claude Code, Codex CLI, Antigravity C
Winsle
A dynamic island for Windows — coding cockpit for Claude Code & Antigravity, local-first media, calendar, phon
Related Agents
Family Timeline Composer
Dynamic family timeline composer. Integrates chronological milestones from the Hoffnung manuscripts, Lebensbau
Ansible Expert
Use this agent for all Ansible-related tasks: writing or reviewing playbooks, roles, and inventory; debugging
Pbi Security
Row-level security (RLS) specialist for the Power BI Desktop project currently open. Designs and creates roles