7. A system, comprising: a data processing apparatus and a computer storage apparatus in data communication with the data processing apparatus and storing instructions executable by the data processing apparatus and that upon such execution cause the data processing apparatus to perform operations comprising: for each action of a set of actions, generating a training set of command sentences from a corresponding set of command sentences for the action, the generating the training set of command sentences including retaining first n-grams determined to be semantically relevant for the action and removing second n-grams that are determined to be semantically irrelevant for the action from each sentence in the corresponding set of command sentences for the action; and for each action, generating a command model from the training set of command sentences and persisting the command model in a computer memory device, the command model facilitating the generation of an action score for the action for an input sentence based on: the first n-grams determined to be semantically relevant for the action; and second n-grams for the action that are also second n-grams for all other actions.
7. A system, comprising: a data processing apparatus and a computer storage apparatus in data communication with the data processing apparatus and storing instructions executable by the data processing apparatus and that upon such execution cause the data processing apparatus to perform operations comprising: for each action of a set of actions, generating a training set of command sentences from a corresponding set of command sentences for the action, the generating the training set of command sentences including retaining first n-grams determined to be semantically relevant for the action and removing second n-grams that are determined to be semantically irrelevant for the action from each sentence in the corresponding set of command sentences for the action; and for each action, generating a command model from the training set of command sentences and persisting the command model in a computer memory device, the command model facilitating the generation of an action score for the action for an input sentence based on: the first n-grams determined to be semantically relevant for the action; and second n-grams for the action that are also second n-grams for all other actions. 10. The system of claim 7 , wherein for each action, generating or updating a command model comprises generating a grammar rule model based on the first n-grams for the action.