Three layer extension sync

From ychampion/cskill-agents · View interactive version

Three layer extension sync is an AI agent skill from the GitHub repository ychampion/cskill-agents. Model extension lifecycle as intent, materialization, and active runtime layers, then sync each layer with dedicated transitions.

How to use this skill

Skill file

SKILL: Three-Layer Extension Sync

Domain: plugin-installation

Trigger: Apply when extensions exist simultaneously as declared settings, on-disk installs, and live runtime components, and those layers must stay coherent.

Source Pattern: Distilled from reviewed plugin, extension, and MCP synchronization implementations.

Core Method

Split extension management into three layers: intent in configuration, materialization on disk, and active runtime state. Use the diff/reconcile phase to move layer 1 toward layer 2 without touching UI state, then use a separate refresh phase to rebuild layer 3 from the materialized result. This keeps each transition explicit, makes fallback rules clear, and prevents partial reload logic from smearing together configuration, installation, and activation responsibilities.

Key Rules

Example Application

In a desktop agent with third-party extensions, treat settings as the declared catalog, a local extensions directory as the materialized layer, and the in-memory command registry as the active layer. Reconcile settings to disk first, then run a distinct reload step that repopulates the active registry from the updated install set.

Anti-Patterns (What NOT to do)

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.