edsnlp.scorers.span_attributes
span_attribute_scorer
Scores the attributes predictions between a list of gold and predicted spans.
Parameters
PARAMETER | DESCRIPTION |
---|---|
args | The examples to score, either a tuple of (golds, preds) or a list of spacy.training.Example objects TYPE: |
span_getter | The span getter to use to extract the spans from the document TYPE: |
attributes | The attributes to use to score the spans TYPE: |
default_values | Values to dismiss when computing the micro-average per label. This is useful to compute precision and recall for certain attributes that have imbalanced value repartitions, such as "negation", "family related" or "certainty" attributes. TYPE: |
include_falsy | Whether to count predicted or gold occurrences of falsy values when computing the metrics. If TYPE: |
micro_key | The key to use to store the micro-averaged results for spans of all types TYPE: |
filter_expr | The filter expression to use to filter the documents TYPE: |
RETURNS | DESCRIPTION |
---|---|
Dict[str, float] | |