mcbopomofoweb
    Preparing search index...

    A node in the reading grid.

    Index

    Constructors

    Properties

    reading: string
    spanningLength: number
    unigrams: Unigram[]
    kOverridingScore: number = 42

    A sufficiently high score to cause the walk to go through an overriding node. Although this can be 0, setting it to a positive value has the desirable side effect that it reduces the competition of "free-floating" multiple-character phrases. For example, if the user override for reading "a b c" is "A B c", using the uppercase as the overriding node, now the standalone c may have to compete with a phrase with reading "bc", which in some pathological cases may actually cause the shortest path to be A->bc, especially when A and B use the zero overriding score, as they leave "c" alone to compete with "bc", and whether the path A-B is favored now solely depends on that competition. A positive value favors the route A->B, which gives "c" a better chance.

    Accessors

    Methods

    • Selects a unigram to override the node.

      Parameters

      • value: string

        The value of the unigram to select.

      • type: OverrideType

        The type of override.

      Returns boolean

      True if the unigram was found and selected, false otherwise.