actorizer: Additional fix for missing punctuation (see previous commit)

master
Erik de Vries 6 years ago
parent 09732a1b5a
commit cd05733648

@ -33,7 +33,9 @@ actorizer <- function(out, localhost = F, ids, type, prefix, postfix, identifier
### The exception below is only valid for the UK, where the original UDPipe output misses a dot at the end of the article, but the actor output does not
### (UK output is older than actor output, should be updated)
if (!(ud_org$lemma[length(ud_org$lemma)] %in% c('!','?','.'))) {
ud <- ud[-length(ud$sentence_id),]
}
if (length(ud_org$sentence_id) == length(ud$sentence_id)) {
ud <- bind_cols(ud_org, sentence = ud$sentence, token = ud$token, doc_id = ud$doc_id)
} else {

Loading…
Cancel
Save