





Synopsis 




Semiring


Semirings (rings without additive inverses, http://en.wikipedia.org/wiki/Semiring) are
a commonly used structure for performing computations over finite state machines,
parsers, and other dynamic programmysystems. This library extends the basic structures
defined for Monoids to Semirings and includes implementations of the major semirings
for parsing.
This work is based largely on Semiring Parsing by Joshua Goodman. (http://www.ldc.upenn.edu/acl/J/J99/J994004.pdf)
which describes many of the interesting parsing semirings.


Multiplicative (one, times) 

Monoid (mempty, mappend, mconcat) 


A Semiring is made up of an additive Monoid and a Multiplicative.
It must also satisfy several other algebraic properties checked by quickcheck.
  Instances  



A WeightedSemiring also includes a sensical ordering over choices.
i.e. out of two choices which is better. This is used for Viterbi selection.
  Instances  


newtype Weighted semi1 semi2  Source 

The Weighted type is the main type of WeightedSemiring.
It combines scoring semiring with a history semiring.
The best example of this is the ViterbiDerivation semiring.
 Constructors   Instances  


getWeight 

getInfo 

Produced by Haddock version 2.4.2 