Added the rewrite of the LFG class.