org.allenai.nlpstack.parse.poly

eval

package eval

Visibility
  1. Public
  2. All

Type Members

  1. case class CposErrorAnalyzer(goldParseBank: ParseBank) extends ParseAnalyzer with Product with Serializable

    The CposErrorAnalyzer tallies coarse part-of-speech tagging errors according to the specific error (i.e.

    The CposErrorAnalyzer tallies coarse part-of-speech tagging errors according to the specific error (i.e. "NOUN-->VERB" means that a NOUN was incorrectly tagged as a verb).

    goldParseBank

    a bank containing the gold parses

  2. case class LabeledAttachmentScore(goldParses: ParseBank) extends PathAccuracyScore with Product with Serializable

    Shorthand for the PathAccuracyScore ignoring punctuation, and using breadcrumbs only for path equivalence.

  3. case class LabeledLostTokens(goldParses: ParseBank) extends ParseScore with Product with Serializable

    Counts the number of tokens "lost" by bad attachments (i.e.

    Counts the number of tokens "lost" by bad attachments (i.e. their path to the root is different in the gold and candidate parse).

  4. case class LabeledPathAccuracy(goldParses: ParseBank) extends PathAccuracyScore with Product with Serializable

    Shorthand for the PathAccuracyScore ignoring punctuation.

  5. case class LostTokensAnalyzer(goldParseBank: ParseBank) extends ParseAnalyzer with Product with Serializable

    The LostTokensAnalyzer tallies lost tokens (i.e.

    The LostTokensAnalyzer tallies lost tokens (i.e. tokens with a different breadcrumb path in the gold parse) according to the breadcrumb arc label of their highest misattached ancestor in the gold parse.

    Example: In the gold parse, suppose the breadcrumb path of token "red" is

    --ROOT--> ate --PREP--> with --POBJ--> chopsticks --AMOD--> red

    but in the candidate parse, the breadcrumb path of token "chopsticks" is

    --ROOT--> ate --DOBJ--> pasta --PREP--> with --POBJ--> meatballs --AMOD--> red

    then the highest misattached ancestor of "red" in the gold parse is "with" (attached to "pasta" instead of "ate"). The arc label of "with" is "PREP" in the gold parse. So the loss of token "red" is attributed to a "PREP" attachment error.

    goldParseBank

    a bank containing the gold parses

  6. case class MisattachmentAnalyzer(goldParseBank: ParseBank, ignoreLabel: Boolean) extends ParseAnalyzer with Product with Serializable

    The MisattachmentAnalyzer tallies misattached tokens (i.e.

    The MisattachmentAnalyzer tallies misattached tokens (i.e. tokens with the wrong breadcrumb assignment) according to the label of its breadcrumb arc in the gold parse.

    goldParseBank

    a bank containing the gold parses

    ignoreLabel

    set to true if we want to regard a node as correctly attached as long as its breadcrumb is correct (regardless of how its breadcrumb arc is labeled)

  7. trait ParseAnalyzer extends (PolytreeParse) ⇒ Map[String, Double]

    A ParseAnalyzer maps a candidate parse to an "analysis", i.e.

    A ParseAnalyzer maps a candidate parse to an "analysis", i.e. a histogram.

    For instance, this histogram may be the count of mistaken arclabels or part-of-speech tags.

  8. case class ParseBank(underlyingMap: Map[String, PolytreeParse]) extends Product with Serializable

    A ParseBank maps string-representations of sentences to a unique parse.

    A ParseBank maps string-representations of sentences to a unique parse.

    underlyingMap

    the map from strings to parses

  9. abstract class ParseScore extends (PolytreeParse) ⇒ Double

    A ParseScore maps a candidate parse to a score.

  10. abstract class PathAccuracyScore extends ParseScore

    The PathAccuracyScore computes the percentage of a candidate parse's tokens that have a completely correct breadcrumb path (i.e.

    The PathAccuracyScore computes the percentage of a candidate parse's tokens that have a completely correct breadcrumb path (i.e. if you follow a token's breadcrumbs to the nexus in both the candidate and the gold parse, you encounter the same set of tokens in the same order).

  11. case class PostagAccuracy(goldParseBank: ParseBank) extends ParseScore with Product with Serializable

    Counts the fraction of correctly labeled coarse part-of-speech tags in a candidate parse.

    Counts the fraction of correctly labeled coarse part-of-speech tags in a candidate parse.

    goldParseBank

    the bank containing the gold parses

  12. case class PostagAccuracyScore(goldSentences: TaggedSentenceSource) extends TaggedSentenceScore with Product with Serializable

    Counts the fraction of correctly labeled coarse part-of-speech tags in a candidate parse.

    Counts the fraction of correctly labeled coarse part-of-speech tags in a candidate parse.

    goldSentences

    the gold TaggedSentences to compare against

  13. abstract class TaggedSentenceScore extends (TaggedSentence) ⇒ Double

    A TaggedSentenceScore maps a tagged sentence to a score.

  14. case class UnlabeledAttachmentScore(goldParses: ParseBank) extends PathAccuracyScore with Product with Serializable

    Shorthand for the PathAccuracyScore ignoring path labels, punctuation, and using breadcrumbs only for path equivalence.

  15. case class UnlabeledLostTokens(goldParses: ParseBank) extends ParseScore with Product with Serializable

    Counts the number of tokens "lost" by bad attachments (i.e.

    Counts the number of tokens "lost" by bad attachments (i.e. their path to the root is different in the gold and candidate parse). This version ignores arc labels for the purpose of path equivalence.

  16. case class UnlabeledPathAccuracy(goldParses: ParseBank) extends PathAccuracyScore with Product with Serializable

    Shorthand for the PathAccuracyScore ignoring path labels and punctuation.

Value Members

  1. object Evaluate

  2. object ParseBank extends Serializable

  3. object ParseEvaluation

  4. object PathAccuracyScore

  5. object TaggingEvaluation

Ungrouped