Package Exports
- opencode-live-skills
Readme
opencode-live-skills
OpenCode plugin that detects when skill files change on disk and propagates fresh content to all active sessions — no restart required.
What it does
When you edit a SKILL.md file while OpenCode is running:
- Detects the change via the file watcher
- Finds every session that loaded that skill
- Patches the skill content in-place with the fresh version
It also checks for staleness after every tool call within a session, so changes are caught even if the file watcher misses something.
Install
Local (symlink)
npm
npm install opencode-live-skillsThen add to your opencode.json:
{
"plugin": ["opencode-live-skills"]
}How it works
The plugin registers two hooks:
event — listens for:
message.part.updated— registers completed skill tool parts in an in-memory registry (skill name, file path, content hash, full part)file.watcher.updated— when a skill file changes, patches all sessions that loaded itsession.deleted/session.compacted— cleans up the registry
tool.execute.after — on every tool completion, re-reads registered skill files from disk and patches any that have changed since they were loaded.
If a skill file is deleted, the plugin leaves the existing content in place.
Development
npm install
npm test
npm run test:watch
npm run build