Class: TencentCloud::Hunyuan::V20230901::Tool

Inherits:
Common::AbstractModel
  • Object
show all
Defined in:
lib/v20230901/models.rb

Overview

用户指定模型使用的工具

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(type = nil, function = nil) ⇒ Tool

Returns a new instance of Tool.



2915
2916
2917
2918
# File 'lib/v20230901/models.rb', line 2915

def initialize(type=nil, function=nil)
  @Type = type
  @Function = function
end

Instance Attribute Details

#FunctionObject

Parameters:

  • Type:

    工具类型,当前只支持function

  • Function:

    具体要调用的function



2913
2914
2915
# File 'lib/v20230901/models.rb', line 2913

def Function
  @Function
end

#TypeObject

Parameters:

  • Type:

    工具类型,当前只支持function

  • Function:

    具体要调用的function



2913
2914
2915
# File 'lib/v20230901/models.rb', line 2913

def Type
  @Type
end

Instance Method Details

#deserialize(params) ⇒ Object



2920
2921
2922
2923
2924
2925
2926
# File 'lib/v20230901/models.rb', line 2920

def deserialize(params)
  @Type = params['Type']
  unless params['Function'].nil?
    @Function = ToolFunction.new
    @Function.deserialize(params['Function'])
  end
end