Class: Agents::ActionArgument

Inherits:
Object
  • Object
show all
Defined in:
lib/actions/action_argument.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name:, type:, description:) ⇒ ActionArgument

Returns a new instance of ActionArgument.



4
5
6
7
8
# File 'lib/actions/action_argument.rb', line 4

def initialize(name:, type:, description:)
  @name = name
  @type = type
  @description = description
end

Instance Attribute Details

#descriptionObject (readonly)

Returns the value of attribute description.



3
4
5
# File 'lib/actions/action_argument.rb', line 3

def description
  @description
end

#nameObject (readonly)

Returns the value of attribute name.



3
4
5
# File 'lib/actions/action_argument.rb', line 3

def name
  @name
end

#typeObject (readonly)

Returns the value of attribute type.



3
4
5
# File 'lib/actions/action_argument.rb', line 3

def type
  @type
end

Instance Method Details

#for_promptObject



10
11
12
# File 'lib/actions/action_argument.rb', line 10

def for_prompt
  "    #{name}: #{description}"
end