Skip to content
Discussion options

You must be logged in to vote

SpanRuler can do everything that EntityRuler does. If you look at the factory for future_entity_ruler you can see how we have implemented the original EntityRuler functionality using SpanRuler:

@Language.factory(
"future_entity_ruler",
assigns=["doc.ents"],
default_config={
"phrase_matcher_attr": None,
"validate": False,
"overwrite_ents": False,
"scorer": {"@scorers": "spacy.entity_ruler_scorer.v1"},
"ent_id_sep": "__unused__",
},
default_score_weights={
"ents_f": 1.0,
"ents_p": 0.0,
"ents_r": 0.0,
"ents_per_type": None,
},
)

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@kinghuang
Comment options

Answer selected by kinghuang
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat / spanruler Feature: Entity and span ruler
2 participants