✘ Can't find component 'spancat' in pipeline. Make sure that the
pipeline you're using includes a trained span categorizer that you can correct.
If your component has a different name, you can use the --component option to
[('tok2vec', <spacy.pipeline.tok2vec.Tok2Vec at 0x7fea5e251fa0>),
('tagger', <spacy.pipeline.tagger.Tagger at 0x7fea5e251ee0>),
('parser', <spacy.pipeline.dep_parser.DependencyParser at 0x7fea9610f2e0>),
<spacy.pipeline.attributeruler.AttributeRuler at 0x7fea5e1e7140>),
<spacy.lang.en.lemmatizer.EnglishLemmatizer at 0x7fea5e1de140>),
('ner', <spacy.pipeline.ner.EntityRecognizer at 0x7fea9610f350>)]
Similarily you should also be able to load your own model and see the pipeline components via:
Then it seems like you've gotten a pretrained model that can detect named entities (NER) while your recipe is trying to predict spans, via prodigy spans.correct. That also explains the warning that you see because a spancat component is needed to predict spans.
To learn more about the difference between spancat and NER, you might appreciate this blogpost:
One of the main differences is that spancat can predict overlapping spans, which NER doesn't allow in spaCy. That means that you probably to train a model that can handle spans, which you can do via the train command in Prodigy. It will probably look something like:
python -m prodigy train --spancat <datasets>
Alternatively, if you can solve your task with NER instead of spancat, you may also consider using the ner.correct recipe instead.