symfonic.core.learning.entity_extractor_spacy¶
entity_extractor_spacy ¶
spaCy-backed entity extractor (opt-in via the
symfonic-core[entity-linker-spacy] extra).
Lazy import: spacy is only imported when an instance is constructed.
If the import fails or the model is missing, the constructor raises
RuntimeError with an actionable message. The consolidation phase
catches that and falls back to RegexHeuristicExtractor with a
single warning (design §13.3).
Design reference: §17.1.3.
SpacyEntityExtractor ¶
Decision 4.5 strategy. Uses spaCy en_core_web_sm by default.
Confidence is fixed at 0.7 -- spaCy does not surface a per-entity
probability via the ents interface, so we use a heuristic
constant (design §13.2). Callers wanting tighter control should
switch to the LLM extractor.