class Riffer::Skills::ActivateTool
Tool the LLM calls to activate a skill and receive its instructions; registered automatically when an agent has skills configured.
Public Instance Methods
Source
# File lib/riffer/skills/activate_tool.rb, line 19 def call(context:, name:) skills_context = context&.skills return error("Skills not configured") unless skills_context return error("Unknown skill: '#{name}'") unless skills_context.model_invocable?(name) text(skills_context.activate(name)) rescue Riffer::ArgumentError => e error(e.message) end
Activates a skill by name and returns its body.