Class: Octoryn::ToolCall
- Inherits:
-
Data
- Object
- Data
- Octoryn::ToolCall
- Defined in:
- lib/octoryn/types.rb
Instance Attribute Summary collapse
-
#arguments ⇒ Object
readonly
Returns the value of attribute arguments.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Instance Method Summary collapse
Instance Attribute Details
#arguments ⇒ Object (readonly)
Returns the value of attribute arguments
15 16 17 |
# File 'lib/octoryn/types.rb', line 15 def arguments @arguments end |
#id ⇒ Object (readonly)
Returns the value of attribute id
15 16 17 |
# File 'lib/octoryn/types.rb', line 15 def id @id end |
#name ⇒ Object (readonly)
Returns the value of attribute name
15 16 17 |
# File 'lib/octoryn/types.rb', line 15 def name @name end |
#type ⇒ Object (readonly)
Returns the value of attribute type
15 16 17 |
# File 'lib/octoryn/types.rb', line 15 def type @type end |
Instance Method Details
#decode_input ⇒ Object
16 17 18 19 20 21 |
# File 'lib/octoryn/types.rb', line 16 def decode_input value = JSON.parse(arguments) raise JSON::ParserError, 'tool arguments must be an object' unless value.is_a?(Hash) value end |