opencode-swarm-plugin 0.12.24 → 0.12.25

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -666,6 +666,115 @@ const swarm_evaluation_prompt = tool({
666
666
  execute: (args, ctx) => execTool("swarm_evaluation_prompt", args, ctx),
667
667
  });
668
668
 
669
+ // =============================================================================
670
+ // Skills Tools
671
+ // =============================================================================
672
+
673
+ const skills_list = tool({
674
+ description:
675
+ "List all available skills from global, project, and bundled sources",
676
+ args: {
677
+ source: tool.schema
678
+ .enum(["all", "global", "project", "bundled"])
679
+ .optional()
680
+ .describe("Filter by source (default: all)"),
681
+ },
682
+ execute: (args, ctx) => execTool("skills_list", args, ctx),
683
+ });
684
+
685
+ const skills_read = tool({
686
+ description: "Read a skill's full content including SKILL.md and references",
687
+ args: {
688
+ name: tool.schema.string().describe("Skill name"),
689
+ },
690
+ execute: (args, ctx) => execTool("skills_read", args, ctx),
691
+ });
692
+
693
+ const skills_use = tool({
694
+ description:
695
+ "Get skill content formatted for injection into agent context. Use this when you need to apply a skill's knowledge to the current task.",
696
+ args: {
697
+ name: tool.schema.string().describe("Skill name"),
698
+ context: tool.schema
699
+ .string()
700
+ .optional()
701
+ .describe("Optional context about how the skill will be used"),
702
+ },
703
+ execute: (args, ctx) => execTool("skills_use", args, ctx),
704
+ });
705
+
706
+ const skills_create = tool({
707
+ description: "Create a new skill with SKILL.md template",
708
+ args: {
709
+ name: tool.schema.string().describe("Skill name (kebab-case)"),
710
+ description: tool.schema.string().describe("Brief skill description"),
711
+ scope: tool.schema
712
+ .enum(["global", "project"])
713
+ .optional()
714
+ .describe("Where to create (default: project)"),
715
+ tags: tool.schema
716
+ .array(tool.schema.string())
717
+ .optional()
718
+ .describe("Skill tags for discovery"),
719
+ },
720
+ execute: (args, ctx) => execTool("skills_create", args, ctx),
721
+ });
722
+
723
+ const skills_update = tool({
724
+ description: "Update an existing skill's SKILL.md content",
725
+ args: {
726
+ name: tool.schema.string().describe("Skill name"),
727
+ content: tool.schema.string().describe("New SKILL.md content"),
728
+ },
729
+ execute: (args, ctx) => execTool("skills_update", args, ctx),
730
+ });
731
+
732
+ const skills_delete = tool({
733
+ description: "Delete a skill (project skills only)",
734
+ args: {
735
+ name: tool.schema.string().describe("Skill name"),
736
+ },
737
+ execute: (args, ctx) => execTool("skills_delete", args, ctx),
738
+ });
739
+
740
+ const skills_init = tool({
741
+ description: "Initialize skills directory in current project",
742
+ args: {
743
+ path: tool.schema
744
+ .string()
745
+ .optional()
746
+ .describe("Custom path (default: .opencode/skills)"),
747
+ },
748
+ execute: (args, ctx) => execTool("skills_init", args, ctx),
749
+ });
750
+
751
+ const skills_add_script = tool({
752
+ description: "Add an executable script to a skill",
753
+ args: {
754
+ skill_name: tool.schema.string().describe("Skill name"),
755
+ script_name: tool.schema.string().describe("Script filename"),
756
+ content: tool.schema.string().describe("Script content"),
757
+ executable: tool.schema
758
+ .boolean()
759
+ .optional()
760
+ .describe("Make executable (default: true)"),
761
+ },
762
+ execute: (args, ctx) => execTool("skills_add_script", args, ctx),
763
+ });
764
+
765
+ const skills_execute = tool({
766
+ description: "Execute a skill's script",
767
+ args: {
768
+ skill_name: tool.schema.string().describe("Skill name"),
769
+ script_name: tool.schema.string().describe("Script to execute"),
770
+ args: tool.schema
771
+ .array(tool.schema.string())
772
+ .optional()
773
+ .describe("Script arguments"),
774
+ },
775
+ execute: (args, ctx) => execTool("skills_execute", args, ctx),
776
+ });
777
+
669
778
  // =============================================================================
670
779
  // Plugin Export
671
780
  // =============================================================================
@@ -716,6 +825,16 @@ export const SwarmPlugin: Plugin = async (
716
825
  swarm_spawn_subtask,
717
826
  swarm_complete_subtask,
718
827
  swarm_evaluation_prompt,
828
+ // Skills
829
+ skills_list,
830
+ skills_read,
831
+ skills_use,
832
+ skills_create,
833
+ skills_update,
834
+ skills_delete,
835
+ skills_init,
836
+ skills_add_script,
837
+ skills_execute,
719
838
  },
720
839
  };
721
840
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "opencode-swarm-plugin",
3
- "version": "0.12.24",
3
+ "version": "0.12.25",
4
4
  "description": "Multi-agent swarm coordination for OpenCode with learning capabilities, beads integration, and Agent Mail",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",