Class: ActiveAgent::ActionPrompt::Action
- Inherits:
-
Object
- Object
- ActiveAgent::ActionPrompt::Action
- Defined in:
- lib/active_agent/action_prompt/action.rb
Instance Attribute Summary collapse
-
#agent_name ⇒ Object
Returns the value of attribute agent_name.
-
#id ⇒ Object
Returns the value of attribute id.
-
#name ⇒ Object
Returns the value of attribute name.
-
#params ⇒ Object
Returns the value of attribute params.
Instance Method Summary collapse
-
#initialize(attributes = {}) ⇒ Action
constructor
A new instance of Action.
Constructor Details
#initialize(attributes = {}) ⇒ Action
Returns a new instance of Action.
6 7 8 9 10 |
# File 'lib/active_agent/action_prompt/action.rb', line 6 def initialize(attributes = {}) @id = attributes.fetch(:id, nil) @name = attributes.fetch(:name, "") @params = attributes.fetch(:params, {}) end |
Instance Attribute Details
#agent_name ⇒ Object
Returns the value of attribute agent_name.
4 5 6 |
# File 'lib/active_agent/action_prompt/action.rb', line 4 def agent_name @agent_name end |
#id ⇒ Object
Returns the value of attribute id.
4 5 6 |
# File 'lib/active_agent/action_prompt/action.rb', line 4 def id @id end |
#name ⇒ Object
Returns the value of attribute name.
4 5 6 |
# File 'lib/active_agent/action_prompt/action.rb', line 4 def name @name end |
#params ⇒ Object
Returns the value of attribute params.
4 5 6 |
# File 'lib/active_agent/action_prompt/action.rb', line 4 def params @params end |