Useful variants arise via well-known methods for weighted derivation forests (Berstel and Reutenauer, 1988;Goodman, 1999;Li and Eisner, 2009;Eisner, 2016).
to modify Algorithm 1 to maximize over T 0 values ( § § 6.2-6.3) instead of summing over them, we switch to the derivation semiring (Goodman, 1999), as follows.