-
Notifications
You must be signed in to change notification settings - Fork 43
2377 - 3 #299
base: master
Are you sure you want to change the base?
2377 - 3 #299
Conversation
2377/3/sinatra/azure_api.rb
Outdated
end | ||
|
||
def documents(comment) | ||
{ 'documents': [{ 'id' => '1', 'language' => 'ru', 'text' => comment.comment.to_s }] } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lint/Syntax: unexpected token tCOLON
Lint/Syntax: unexpected token tRCURLY
2377/3/sinatra/azure_api.rb
Outdated
comment.update score: convert((JSON response.body)['documents'][0]['score']) | ||
end | ||
|
||
def convert(value) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
UtilityFunction: TextAnalytics#convert doesn't depend on instance state (maybe move it to another class?). More info.
@uri = URI('https://westeurope.api.cognitive.microsoft.com/text/analytics/v2.0/sentiment') | ||
end | ||
|
||
def analyse(comment) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Metrics/AbcSize: Assignment Branch Condition size for analyse is too high. [15.03/15]
2377/3/sinatra/app.rb
Outdated
|
||
get '/clear' do | ||
Ohm.redis.call('FLUSHALL') | ||
#erb :active_page |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Layout/LeadingCommentSpace: Missing space after #.
Номер
2377
Номер задания
3
Ссылка на видео с демо
https://youtu.be/VnCZ9ONpfvg
Комментарии
Хотел сделать то-то, но не успел и не понимаю.