I've noticed that there are some cases where the DOI is correctly extracted from the article header, however, they are incorrectly mangled in the output.
There are several articles (e.g. Plos) where the DOI in the header is split by a breakline, in such cases the DOI is wrongly substituted.
I'm not sure, maybe we could substitute it only when the found DOI is the same or larger than the one already extracted by the header parser.
Another thing is that we could extract the DOI exploiting the clickable URL to correct the suffix.
I've noticed that there are some cases where the DOI is correctly extracted from the article header, however, they are incorrectly mangled in the output.
Example: origin9833693929434438741.pdf
In this article the DOI is correctly extracted up to here: https://github.com/kermitt2/grobid/blob/694f0ed055e8c9a5d5efdc314ebef78e5e2640cf/grobid-core/src/main/java/org/grobid/core/engines/HeaderParser.java#L269
There are several articles (e.g. Plos) where the DOI in the header is split by a breakline, in such cases the DOI is wrongly substituted. I'm not sure, maybe we could substitute it only when the found DOI is the same or larger than the one already extracted by the header parser.
Another thing is that we could extract the DOI exploiting the clickable URL to correct the suffix.