Class: Cadenya::Types::AssistantToolCall
- Inherits:
-
Object
- Object
- Cadenya::Types::AssistantToolCall
- Defined in:
- lib/cadenya/types.rb
Instance Attribute Summary collapse
-
#arguments ⇒ Object
readonly
Returns the value of attribute arguments.
-
#function_name ⇒ Object
readonly
Returns the value of attribute function_name.
-
#tool ⇒ Object
readonly
Returns the value of attribute tool.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(tool: nil, arguments: nil, function_name: nil) ⇒ AssistantToolCall
constructor
A new instance of AssistantToolCall.
- #to_h ⇒ Object
Constructor Details
#initialize(tool: nil, arguments: nil, function_name: nil) ⇒ AssistantToolCall
Returns a new instance of AssistantToolCall.
985 986 987 988 989 |
# File 'lib/cadenya/types.rb', line 985 def initialize(tool: nil, arguments: nil, function_name: nil) @tool = tool @arguments = arguments @function_name = function_name end |
Instance Attribute Details
#arguments ⇒ Object (readonly)
Returns the value of attribute arguments.
983 984 985 |
# File 'lib/cadenya/types.rb', line 983 def arguments @arguments end |
#function_name ⇒ Object (readonly)
Returns the value of attribute function_name.
983 984 985 |
# File 'lib/cadenya/types.rb', line 983 def function_name @function_name end |
#tool ⇒ Object (readonly)
Returns the value of attribute tool.
983 984 985 |
# File 'lib/cadenya/types.rb', line 983 def tool @tool end |
Class Method Details
.from_json(data) ⇒ Object
991 992 993 994 995 996 997 |
# File 'lib/cadenya/types.rb', line 991 def self.from_json(data) new( tool: data["tool"].nil? ? nil : Types.decode_CallableTool(data["tool"]), arguments: data["arguments"], function_name: data["functionName"], ) end |