sublayerapp / sublayer

A model-agnostic Ruby Generative AI DSL and framework. Provides base classes for building Generators, Actions, Tasks, and Agents that can be used to build AI powered applications in Ruby.
https://docs.sublayer.com
MIT License
109 stars 2 forks source link

agent raises when no triggers are defined #83

Open swerner opened 2 months ago

swerner commented 2 months ago

if a user plans to trigger their agent manually, an error is raised:

gems/sublayer-0.2.3/lib/sublayer/agents/base.rb:45:in `setup_triggers': undefined method `each' for nil (NoMethodError)

        self.class.triggers.each do |trigger|

Two things planned here, one with no triggers defined it shouldn't error out, but we should also have a built in trigger subclass for manually triggering an agent