Class: TencentCloud::Nlp::V20190408::EvaluateSentenceSimilarityRequest

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

Overview

EvaluateSentenceSimilarity请求参数结构体

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(sentencepairlist = nil) ⇒ EvaluateSentenceSimilarityRequest

Returns a new instance of EvaluateSentenceSimilarityRequest.



355
356
357
# File 'lib/v20190408/models.rb', line 355

def initialize(sentencepairlist=nil)
  @SentencePairList = sentencepairlist
end

Instance Attribute Details

#SentencePairListObject

Parameters:

  • SentencePairList:

    待分析的句子对数组。句子对应不超过1对,仅支持中文文本,原句子与目标句子均应不超过500字符。



353
354
355
# File 'lib/v20190408/models.rb', line 353

def SentencePairList
  @SentencePairList
end

Instance Method Details

#deserialize(params) ⇒ Object



359
360
361
362
363
364
365
366
367
368
# File 'lib/v20190408/models.rb', line 359

def deserialize(params)
  unless params['SentencePairList'].nil?
    @SentencePairList = []
    params['SentencePairList'].each do |i|
      sentencepair_tmp = SentencePair.new
      sentencepair_tmp.deserialize(i)
      @SentencePairList << sentencepair_tmp
    end
  end
end