Class: Swarm::Result

Inherits:
Object
  • Object
show all
Defined in:
lib/swarm/result.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(value:, agent: nil, context_variables: {}) ⇒ Result

Returns a new instance of Result.



7
8
9
10
11
# File 'lib/swarm/result.rb', line 7

def initialize(value:, agent: nil, context_variables: {})
  @value = value
  @agent = agent
  @context_variables = context_variables
end

Instance Attribute Details

#agentObject

Returns the value of attribute agent.



5
6
7
# File 'lib/swarm/result.rb', line 5

def agent
  @agent
end

#context_variablesObject

Returns the value of attribute context_variables.



5
6
7
# File 'lib/swarm/result.rb', line 5

def context_variables
  @context_variables
end

#valueObject

Returns the value of attribute value.



5
6
7
# File 'lib/swarm/result.rb', line 5

def value
  @value
end