Class: TencentCloud::Nlp::V20190408::ComposeCoupletRequest

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

Overview

ComposeCouplet请求参数结构体

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(text = nil, targettype = nil) ⇒ ComposeCoupletRequest

Returns a new instance of ComposeCoupletRequest.



198
199
200
201
# File 'lib/v20190408/models.rb', line 198

def initialize(text=nil, targettype=nil)
  @Text = text
  @TargetType = targettype
end

Instance Attribute Details

#TargetTypeObject

Parameters:

  • Text:

    生成对联的关键词。长度需>=2,当长度>2时,自动截取前两个字作为关键字。内容需为常用汉字(不含有数字、英文、韩语、日语、符号等等其他)。

  • TargetType:

    返回的文本结果为繁体还是简体。0:简体;1:繁体。默认为0。



196
197
198
# File 'lib/v20190408/models.rb', line 196

def TargetType
  @TargetType
end

#TextObject

Parameters:

  • Text:

    生成对联的关键词。长度需>=2,当长度>2时,自动截取前两个字作为关键字。内容需为常用汉字(不含有数字、英文、韩语、日语、符号等等其他)。

  • TargetType:

    返回的文本结果为繁体还是简体。0:简体;1:繁体。默认为0。



196
197
198
# File 'lib/v20190408/models.rb', line 196

def Text
  @Text
end

Instance Method Details

#deserialize(params) ⇒ Object



203
204
205
206
# File 'lib/v20190408/models.rb', line 203

def deserialize(params)
  @Text = params['Text']
  @TargetType = params['TargetType']
end