Class: Swarm::Agent
- Inherits:
-
Object
- Object
- Swarm::Agent
- Defined in:
- lib/swarm/agent.rb
Instance Attribute Summary collapse
-
#functions ⇒ Object
Returns the value of attribute functions.
-
#instructions ⇒ Object
Returns the value of attribute instructions.
-
#model ⇒ Object
Returns the value of attribute model.
-
#name ⇒ Object
Returns the value of attribute name.
-
#tool_choice ⇒ Object
Returns the value of attribute tool_choice.
Instance Method Summary collapse
-
#initialize(name:, model:, instructions:, functions: [], tool_choice: 'auto') ⇒ Agent
constructor
A new instance of Agent.
Constructor Details
#initialize(name:, model:, instructions:, functions: [], tool_choice: 'auto') ⇒ Agent
Returns a new instance of Agent.
7 8 9 10 11 12 13 |
# File 'lib/swarm/agent.rb', line 7 def initialize(name:, model:, instructions:, functions: [], tool_choice: 'auto') @name = name @model = model @instructions = instructions @functions = functions @tool_choice = tool_choice end |
Instance Attribute Details
#functions ⇒ Object
Returns the value of attribute functions.
5 6 7 |
# File 'lib/swarm/agent.rb', line 5 def functions @functions end |
#instructions ⇒ Object
Returns the value of attribute instructions.
5 6 7 |
# File 'lib/swarm/agent.rb', line 5 def instructions @instructions end |
#model ⇒ Object
Returns the value of attribute model.
5 6 7 |
# File 'lib/swarm/agent.rb', line 5 def model @model end |
#name ⇒ Object
Returns the value of attribute name.
5 6 7 |
# File 'lib/swarm/agent.rb', line 5 def name @name end |
#tool_choice ⇒ Object
Returns the value of attribute tool_choice.
5 6 7 |
# File 'lib/swarm/agent.rb', line 5 def tool_choice @tool_choice end |