12. The computer storage medium of claim 11 , wherein: the optimal conditional rule for a node or leaf is the rule that is optimal for the condition that a parent node of the node or leaf is associated with a particular canonical suffix-rewriting rule; and selecting an optimal canonical suffix-rewriting rule for each node according to the optimal conditional rules for the node comprises: determining an optimal canonical suffix-rewriting rule for a root of the suffix tree; and determining an optimal canonical suffix-rewriting rule for each remaining node in the tree, wherein the optimal canonical suffix-rewriting rule for a node in the tree is the optimal conditional rule for the canonical suffix-rewriting rule associated with a parent of the node.
12. The computer storage medium of claim 11 , wherein: the optimal conditional rule for a node or leaf is the rule that is optimal for the condition that a parent node of the node or leaf is associated with a particular canonical suffix-rewriting rule; and selecting an optimal canonical suffix-rewriting rule for each node according to the optimal conditional rules for the node comprises: determining an optimal canonical suffix-rewriting rule for a root of the suffix tree; and determining an optimal canonical suffix-rewriting rule for each remaining node in the tree, wherein the optimal canonical suffix-rewriting rule for a node in the tree is the optimal conditional rule for the canonical suffix-rewriting rule associated with a parent of the node. 13. The computer storage medium of claim 12 , further operable to cause data processing apparatus to perform operations comprising generating a normalized form of a word using one of the plurality of final suffix-rewriting rules.