Skip to content

Feature Request: Plugin-bundled Skills Discovery #10148

Closed

Description

@nghyane

Feature Request: Plugin-bundled Skills Discovery

Summary

Allow plugins to bundle skills that are automatically discovered when the plugin is loaded.

Problem

Currently, OpenCode's skill discovery scans:

  • .opencode/skills/ (project)
  • ~/.config/opencode/skills/ (global)

But plugins at ~/.config/opencode/plugins/<name>/ cannot bundle skills that are auto-discovered. This forces plugin authors to either:

  1. Ask users to manually copy skills to ~/.config/opencode/skills/
  2. Implement a custom skill tool within the plugin (duplicating native functionality)
  3. Deploy skills during plugin "install" (no standard mechanism)

Proposed Solution

Option A: Scan plugin directories for skills

Extend Skill.all() to also scan:

~/.config/opencode/plugins/*/skills/**/SKILL.md
~/.config/opencode/plugins/*/.opencode/skills/**/SKILL.md

Option B: Plugin hook for skill registration

Add a skills property to the Hooks interface:

interface Hooks {
  // ... existing
  skills?: Record<string, SkillDefinition>;
}

// Plugin usage
export default async function plugin() {
  return {
    tool: { ... },
    skills: {
      "my-skill": {
        name: "my-skill",
        description: "...",
        content: "# Instructions..."
      }
    }
  };
}

Option C: PluginInput includes skill registration

export default async function plugin({ registerSkill }: PluginInput) {
  registerSkill({
    name: "my-skill",
    description: "...",
    content: "..."
  });
  
  return { tool: {...} };
}

Use Case: NotebookLM Plugin

I'm building a NotebookLM plugin with 8 tools. Each tool has corresponding skill instructions. Currently I must:

  • Deploy skills to ~/.config/opencode/skills/nlm-*/SKILL.md separately
  • Skills are visible even when plugin is disabled
  • No way to scope skills to plugin lifecycle

With this feature:

  • Skills bundled with plugin
  • Skills only available when plugin is active
  • Single install = plugin + skills together

Benefits

  1. Self-contained plugins - One package includes everything
  2. Proper scoping - Skills tied to plugin lifecycle
  3. Better UX - No manual skill deployment
  4. Ecosystem growth - Easier to distribute complete plugin packages

Additional Context

  • OpenCode version: Latest
  • Plugin location: ~/.config/opencode/plugins/notebooklm/
  • Reference: I've analyzed the skill discovery code in packages/opencode/src/skill/skill.ts

Activity

  1. github-actions commented on Jan 23, 2026

    @github-actions
    Contributor

    This issue might be a duplicate of existing issues. Please check:

    Feel free to ignore if none of these address your specific case.

  2. github-actions commented on Mar 26, 2026

    @github-actions
    Contributor

    To stay organized issues are automatically closed after 90 days of no activity. If the issue is still relevant please open a new one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions