opc-architecture
π―Skillfrom parcadei/continuous-claude-v3
opc-architecture skill from parcadei/continuous-claude-v3
Installation
npx skills add https://github.com/parcadei/continuous-claude-v3 --skill opc-architectureSkill Details
OPC Architecture Understanding
Overview
# OPC Architecture Understanding
OPC (Orchestrated Parallel Claude) extends Claude Code - it does NOT replace it.
Core Concept
Claude Code CLI is the execution engine. OPC adds orchestration via:
- Hooks - Intercept Claude Code events (PreToolUse, PostToolUse, SessionStart, etc.)
- Skills - Load prompts into Claude Code
- Scripts - Called by hooks/skills for coordination
- Database - Store state between Claude Code instances
How Agents Work
When you spawn an agent:
- Main Claude Code instance (your terminal) runs hook on Task tool
- Hook calls
subprocess.Popen(["claude", "-p", "prompt"]) - A NEW Claude Code instance spawns as child process
- Child runs independently, reads/writes to coordination DB
- Parent tracks child via PID in DB
```
$ claude β Main Claude Code (your terminal)
β Task tool triggers hook
β subprocess.Popen(["claude", "-p", "..."])
βββ claude -p "research..." β Child agent 1
βββ claude -p "implement..." β Child agent 2
βββ claude -p "test..." β Child agent 3
```
What OPC Is NOT
- OPC is NOT a separate application
- OPC does NOT run without Claude Code
- OPC does NOT intercept Claude API calls directly
- OPC does NOT modify Claude Code's internal behavior
What OPC IS
- OPC IS hooks that Claude Code loads from
.claude/hooks/ - OPC IS skills that Claude Code loads from
.claude/skills/ - OPC IS scripts that hooks/skills call for coordination
- OPC IS a database backend for state across Claude Code instances
Key Files
```
.claude/
βββ hooks/ β TypeScript hooks that Claude Code runs
βββ skills/ β SKILL.md prompts that Claude Code loads
βββ settings.json β Hook registration, Claude Code reads this
βββ cache/ β State files, agent outputs
opc/
βββ scripts/ β Python scripts called by hooks
βββ docker-compose.yml β PostgreSQL, Redis, PgBouncer
βββ init-db.sql β Database schema
```
Coordination Flow
- User runs
claudein terminal - Claude Code loads hooks from
.claude/settings.json - User says "spawn a research agent"
- Claude uses Task tool
- PreToolUse hook fires, checks resources
- Hook spawns
claude -p "research..."as subprocess - Hook stores PID in PostgreSQL
- Child agent runs, writes output to
.claude/cache/agents// - Child completes, broadcasts "done" to PostgreSQL
- Parent checks DB, reads child's output file
Remember
- Every "agent" is just another
claude -pprocess - Hooks intercept events, they don't create new functionality
- All coordination happens via files and PostgreSQL
- Claude Code is always the execution engine
More from this repository10
Enables seamless integration between Agentica agents and Claude Code CLI by managing proxy configurations, tool permissions, and response formatting.
Manages git commits by removing Claude attribution, generating reasoning documentation, and ensuring clean commit workflows.
Systematically diagnose and resolve hook registration, execution, and output issues in Claude Code projects by checking cache, settings, files, and manual testing.
Systematically researches, analyzes, plans, implements, and reviews migrations across frameworks, languages, and infrastructure with minimal risk.
Enables background agent execution with system-triggered progress notifications, avoiding manual polling and context flooding.
Provides comprehensive reference and infrastructure for building sophisticated multi-agent coordination patterns and workflows with precise API specifications and tracking mechanisms.
Generates a comprehensive summary of the current system's configuration, components, and key metrics across skills, agents, hooks, and other core systems.
Provides comprehensive CLI commands and flags for interacting with Claude Code, enabling headless mode, automation, and session management.
Traces and correlates Claude Code session events across parent and sub-agent interactions using comprehensive Braintrust instrumentation.
Rapidly edits files using AI-powered Morph Apply API with high accuracy and speed, without requiring full file context.