19. The device of claim 15 , wherein, to determine the groupings, the program instructions in the data storage, upon execution by the at least one processor, cause the device to generate a factor graph that includes automaton states and automaton arcs, each of the automaton arcs corresponding to a word from the sequence of words of the search query.
19. The device of claim 15 , wherein, to determine the groupings, the program instructions in the data storage, upon execution by the at least one processor, cause the device to generate a factor graph that includes automaton states and automaton arcs, each of the automaton arcs corresponding to a word from the sequence of words of the search query. 20. The device of claim 19 , wherein, to determine a given grouping of the groupings, the program instructions in the data storage, upon execution by the at least one processor, cause the device to: select a first word represented by a first automaton arc connected to a first automaton state; continue to a second automaton state adjacent to the first automaton state; and select a second word represented by a second arc connected to the second automaton state, wherein the second word is adjacent to the first word in the sequence of words of the search query, and wherein the given grouping is allowed to begin at any given automaton state in the factor graph.