1. A non-transitory computer-readable medium having instructions stored thereon, the instructions, when executed by one or more processors, cause the one or more processors to: receive speech input; traverse, based on the speech input, a sequence of states and arcs of a weighted finite state transducer (WFST), wherein: the sequence of states and arcs represents one or more history candidate words and a current candidate word; and a first probability of the candidate word given the one or more history candidate words is determined by traversing the sequence of states and arcs of the WFST; traverse a negating finite state transducer (FST), wherein traversing the negating FST negates the first probability of the candidate word given the one or more history candidate words; compose a virtual FST using a neural network language model and based on the sequence of states and arcs of the WFST, wherein one or more virtual states of the virtual FST represent the current candidate word; traverse the one or more virtual states of the virtual FST, wherein a second probability of the candidate word given the one or more history candidate words is determined by traversing the one or more virtual states of the virtual FST; determine, based on the second probability of the candidate word given the one or more history candidate words, text corresponding to the speech input; based on the determined text, perform one or more tasks to obtain a result; and cause the result to be presented in spoken or visual form.