Be more paranoid about identifying mentions
This commit is contained in:
parent
d676eaa77f
commit
5d55d90f85
1 changed files with 2 additions and 2 deletions
|
|
@ -59,13 +59,13 @@ module Ebooks
|
||||||
|
|
||||||
statements.each do |s|
|
statements.each do |s|
|
||||||
@sentences << NLP.tokenize(s).reject do |t|
|
@sentences << NLP.tokenize(s).reject do |t|
|
||||||
t.start_with?('@') || t.start_with?('http')
|
t.include?('@') || t.include?('http')
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
mentions.each do |s|
|
mentions.each do |s|
|
||||||
@mentions << NLP.tokenize(s).reject do |t|
|
@mentions << NLP.tokenize(s).reject do |t|
|
||||||
t.start_with?('@') || t.start_with?('http')
|
t.include?('@') || t.include?('http')
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue