class Riffer::Skills::ActivateTool
Tool for the LLM to activate a skill and receive its full instructions.
Registered automatically when an agent has skills configured. The LLM calls this when a task matches an available skill’s description.
Public Instance Methods
Source
# File lib/riffer/skills/activate_tool.rb, line 27 def call(context:, name:) skills_context = context&.dig(:skills) return error("Skills not configured") unless skills_context text(skills_context.activate(name)) rescue Riffer::ArgumentError => e error(e.message) end
Activates a skill by name and returns its body.
- context
-
tool context containing
:skills(aRiffer::Skills::Context). - name
-
the skill name to activate.