1. A method for generating a finite state grammar, the method comprising: (a) receiving user input of at least two sample phrases; (b) analyzing the sample phrases to determine common words that occur in each of the sample phrases and optional words that occur in only some of the sample phrases; (c) creating a mathematical expression representing the sample phrases, the expression including each word found in the sample phrases and an indication of whether a word is a common word or an optional word; (d) displaying the mathematical expression to a user; (e) allowing the user to alter the mathematical expression; (f) generating a finite state grammar corresponding to the altered mathematical expression; and (g) displaying the finite state grammar to the user.