dmnapolitano / stanford-thrift

A Stanford CoreNLP server, with example clients, using Apache Thrift.
47 stars 8 forks source link

Missing closing tags on coref output when there's a coref without a reference within one that has a reference #15

Open dmnapolitano opened 10 years ago

dmnapolitano commented 10 years ago

For the parse tree

(ROOT (S (NP (DT This)) (VP (MD will) (VP (VB help) (S (NP (DT the) (NN firm)) (VP (VBP determine) (NP (NP (NP (NP (DT the) (NN size)) (PP (IN of) (NP (DT the) (NN job)))) (VP (VBN based) (PP (IN on) (NP (NP (JJ numerical) (NNS data)) (PP (IN for) (NP (NN example))))))) (, ,) (NP (NP (DT the) (NN size)) (PP (IN of) (NP (NP (DT the) (NN revenue) (NN number)) (, ,) (NP (NP (DT the) (JJ net) (NN loss)) (CC or) (NP (NP (JJ net) (NN income) (NN trend)) (PP (IN from) (NP (JJ previous) (NNS years))) (, ,) (NP (FW etc)))))))))))) (. .)))

The following is returned:

This will help <COREF ID="68" REF="40">the firm</COREF> determine <COREF ID="69">the size of <COREF ID="73">the job</COREF></COREF> based on numerical data for example , <COREF ID="77" REF="69">the size of <COREF ID="79">the revenue number , <COREF ID="82" REF="79">the net loss</COREF> or net income trend from <COREF ID="66">previous years</COREF> , etc .
dmnapolitano commented 10 years ago

Requested the entire text, beyond this one sentence. coref doesn't actually work this way, lol.