Class: TencentCloud::Hunyuan::V20230901::ToolCall

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

Overview

模型生成的工具调用

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id = nil, type = nil, function = nil, index = nil) ⇒ ToolCall

Returns a new instance of ToolCall.



2942
2943
2944
2945
2946
2947
# File 'lib/v20230901/models.rb', line 2942

def initialize(id=nil, type=nil, function=nil, index=nil)
  @Id = id
  @Type = type
  @Function = function
  @Index = index
end

Instance Attribute Details

#FunctionObject

Parameters:

  • Id:

    工具调用id

  • Type:

    工具调用类型,当前只支持function

  • Function:

    具体的function调用

  • Index:

    索引值



2940
2941
2942
# File 'lib/v20230901/models.rb', line 2940

def Function
  @Function
end

#IdObject

Parameters:

  • Id:

    工具调用id

  • Type:

    工具调用类型,当前只支持function

  • Function:

    具体的function调用

  • Index:

    索引值



2940
2941
2942
# File 'lib/v20230901/models.rb', line 2940

def Id
  @Id
end

#IndexObject

Parameters:

  • Id:

    工具调用id

  • Type:

    工具调用类型,当前只支持function

  • Function:

    具体的function调用

  • Index:

    索引值



2940
2941
2942
# File 'lib/v20230901/models.rb', line 2940

def Index
  @Index
end

#TypeObject

Parameters:

  • Id:

    工具调用id

  • Type:

    工具调用类型,当前只支持function

  • Function:

    具体的function调用

  • Index:

    索引值



2940
2941
2942
# File 'lib/v20230901/models.rb', line 2940

def Type
  @Type
end

Instance Method Details

#deserialize(params) ⇒ Object



2949
2950
2951
2952
2953
2954
2955
2956
2957
# File 'lib/v20230901/models.rb', line 2949

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