shon-otmazgin / fastcoref

MIT License
142 stars 25 forks source link

doc._.resolved_text does not work #20

Closed reuvenlivn closed 1 year ago

reuvenlivn commented 1 year ago

use in python 3.9.1 spacy 3.4.1 fastcoref 2.1.1

from fastcoref import spacy_component import spacy nlp = spacy.load("en_core_web_sm",exclude=["parser", "lemmatizer", "ner", "textcat"])

nlp.add_pipe("fastcoref", config={'model_architecture': 'LingMessCoref', 'model_path': 'biu-nlp/lingmess-coref', 'device': 'cpu'}) doc = nlp.pipe(text, component_cfg={"fastcoref": {'resolvetext': True}}) print(doc..resolvedtext) *** AttributeError: 'generator' object has no attribute ''****

shon-otmazgin commented 1 year ago

Hello @reuvenlivn

please see https://github.com/shon-otmazgin/fastcoref/issues/18

reuvenlivn commented 1 year ago

thanks