OpenCode Plugins

Multi-platform coordination for provider-agnostic AI development

⚠️

Educational Use Only

PAI plugins are private educational infrastructure. Not for production deployment. Demonstrates cross-engine coordination patterns for provider-agnostic AI development research.

3
Plugins
13
MCP Tools
33
Tests Passing
~39 KB
Total Bundle

Three Core Plugins

Cross-engine coordination, Algorithm execution, and research integration

@pai/opencode-cross-engine

15.83 KB

Cross-engine coordination via MCP. Enables PNK (OpenCode) to delegate work to other PAI engines (PNC, PNG, PNX, PNO) and track provenance across the 5-engine architecture.

4 MCP Tools:
  • pai_handoff - Create cross-engine handoffs
  • pai_route - Route tasks to optimal engine
  • pai_status - Check engine health/availability
  • pai_provenance - Query handoff history

@pai/opencode-algorithm

10.39 KB

PAI Algorithm execution in OpenCode. Runs the OBSERVE → PLAN → EXECUTE cycle with ISA (Ideal State Artifact) generation and ISC (Ideal State Criteria) verification.

4 MCP Tools:
  • algorithm_run - Execute full Algorithm cycle
  • algorithm_observe - Run OBSERVE phase only
  • algorithm_isa - Generate/update ISA
  • algorithm_status - Check Algorithm state

@pai/opencode-research

12.70 KB

Unified research integration. Connects OpenCode to YouTube, ArXiv, Fabric patterns, and NotebookLM for comprehensive multi-source research workflows.

5 MCP Tools:
  • research_youtube - Search/analyze YouTube
  • research_arxiv - Query arXiv papers
  • research_fabric - Apply Fabric patterns
  • research_notebooklm - NotebookLM integration
  • research_pipeline - Multi-source workflows

Usage Examples

Real-world plugin integration patterns

Cross-Engine Handoff
// PNK hands off research to PNG (Gemini)
const handoff = await pai_handoff({
  from: "PNK",
  to: "PNG",
  task: "Research latest OAuth 2.0 vulnerabilities",
  context: {
    project: "auth-system",
    priority: "high"
  }
});

// Check status later
const status = await pai_provenance({
  handoff_id: handoff.id
});
Algorithm Execution
// Run full Algorithm cycle
const result = await algorithm_run({
  task: "Build user authentication system",
  effort: "DETERMINED",
  context: {
    tech_stack: ["TypeScript", "Bun", "SQLite"],
    requirements: ["JWT", "refresh tokens", "role-based access"]
  }
});

// OBSERVE → generates ISA with ISC
// PLAN → creates execution plan
// EXECUTE → implements with verification
Multi-Source Research
// Research pipeline: YouTube + ArXiv + NotebookLM
const research = await research_pipeline({
  topic: "LLM security vulnerabilities",
  sources: ["youtube", "arxiv", "notebooklm"],
  depth: "extensive",
  deliverables: ["summary", "audio_overview", "citations"]
});

// Returns:
// - YouTube video transcripts
// - ArXiv paper summaries
// - NotebookLM audio overview
// - Consolidated findings

Installation

Local development setup

Install & Link Plugins
# Clone the plugins repository
git clone ~/Projects/PAI-Development/pai-opencode-plugins
cd pai-opencode-plugins

# Install dependencies
bun install

# Link all plugins to OpenCode
bun run link:all

# Verify installation
bun test

# Check OpenCode recognizes plugins
opencode --list-plugins