Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Match regular expression with code comment #9

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Match regular expression with code comment #9

wants to merge 1 commit into from

Conversation

lpla
Copy link
Contributor

@lpla lpla commented Nov 6, 2019

This is supposed to expect a '<p>' to separate documents, but the regex looks for any tag, creating issues in non-escaped texts.

This is supposed to expect a '<p>'  to separate documents, but the regex looks for any tag, creating issues in non-escaped texts.
@kpu
Copy link
Owner

kpu commented Nov 7, 2019

Ping @phikoehn @hieuhoang this is just a copy from Moses.

@hieuhoang
Copy link
Contributor

it seems to be a bug but it's been in there since 2010 so I'm wary that there isn't something else going on.
https://github.com/moses-smt/mosesdecoder/commits/master/scripts/ems/support/split-sentences.perl
I've never worked on this script, @bhaddow seems to know at least something about it

@bhaddow
Copy link

bhaddow commented Nov 7, 2019

What @lpla suggests seems reasonable, although the sentence splitter was not designed for texts with html markup in them. I don't fully understand the use of

tags (paragraph marking?) I just remove them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants