P
US7617093B2ExpiredUtilityPatentIndex 84

Authoring speech grammars

Assignee: MICROSOFT CORPPriority: Jun 2, 2005Filed: Jun 2, 2005Granted: Nov 10, 2009
Est. expiryJun 2, 2025(expired)· nominal 20-yr term from priority
Inventors:RAMSEY WILLIAM D
G06F 40/279G10L 15/19G06Q 30/04
84
PatentIndex Score
14
Cited by
19
References
19
Claims

Abstract

A method and apparatus are provided for automatically forming a grammar. Example text strings are received and N-grams are formed based on the text strings. A rule in the grammar is then generated automatically based in part on the n-grams.

Claims

exact text as granted — not AI-modified
1. A method of automatically constructing a grammar, the method comprising:
 receiving sentences; 
 forming n-grams based on the sentences; and 
 a processor automatically generating a rule having a name attribute that identifies the rule in the grammar based in part on the n-grams, wherein generating a rule comprises generating a rule for a specific n-gram by including an entry in the rule to allow the specific n-gram to appear in a position where it did not appear in the sentences. 
 
   
   
     2. The method of  claim 1  wherein forming n-grams comprises:
 receiving at least one class definition comprising a semantic class and at least one text string associated with the semantic class; 
 replacing a text string in a sentence with a tag for a semantic class associated with the text string to form a modified sentence; and 
 forming n-grams from the modified sentence. 
 
   
   
     3. The method of  claim 1  wherein forming n-grams comprises forming different orders of n-grams. 
   
   
     4. The method of  claim 2  wherein generating a rule further comprises generating a separate rule for each specific n-gram found in the modified sentence. 
   
   
     5. The method of  claim 1  wherein generating a rule for a specific n-gram further comprises placing an entry in the rule that includes a reference to a rule for the tag or word in the last position of the n-gram followed by a reference to a rule for at least one n+1-gram. 
   
   
     6. The method of  claim 5  wherein the reference to a rule for the tag comprises a reference to a rule that lists all words associated with the semantic class of the tag. 
   
   
     7. The method of  claim 2  wherein replacing a text string with a tag comprises replacing as many words as possible in the sentence. 
   
   
     8. The method of  claim 2  wherein receiving a class definition comprises receiving a reference to a class defined in an existing grammar. 
   
   
     9. A computer-readable storage medium having computer-executable instructions encoded thereon for performing steps comprising:
 receiving a list of text strings associated with a semantic class; 
 receiving at least one sentence in which a text string in the list of text strings appears with additional text; and 
 generating a grammar in a particular grammar format based on the at least one sentence and the semantic class by:
 selecting the text string from the sentence; 
 comparing the text string to text strings that are listed for the semantic class; 
 determining that the text string exactly matches a text string listed for the semantic class; 
 replacing the text string in the at least one sentence with a tag for the semantic class associated with the text string to form a modified sentence comprising the tag and the additional text where the tag for the semantic class represents the multiple text strings associated with the semantic class; 
 
 forming n-grams using the modified sentence; and 
 generating rules for the grammar based on the n-grams. 
 
   
   
     10. The computer-readable storage medium of  claim 9  wherein receiving a text string comprises:
 receiving a text string parameter that identifies the text string; 
 receiving a semantic class parameter that identifies the semantic class; and 
 receiving a weight parameter that indicates the relative weight to be assigned to the text string in the semantic class. 
 
   
   
     11. The computer-readable storage medium of  claim 9  wherein receiving at least one sentence comprises:
 receiving a sentence parameter that identifies the sentence; and 
 receiving a weight parameter that indicates a weight for the sentence in the grammar. 
 
   
   
     12. The computer-readable storage medium of  claim 9  wherein generating a grammar comprises:
 receiving a grammar output file parameter that designates the name to be given to the file containing the grammar; and 
 receiving a grammar format parameter that designates the format for the grammar. 
 
   
   
     13. The computer-readable storage medium of  claim 9  further comprising defining a semantic class. 
   
   
     14. The computer-readable storage medium of  claim 13  wherein defining the semantic class comprises:
 receiving a main semantic class parameter that provides a main semantic class for the semantic class; 
 receiving an indicator semantic class parameter that defines an indicator semantic class for the semantic class; 
 receiving an active node parameter that indicates whether the combination of the indicator semantic class and the main semantic class should be used as the default for the main semantic class; and 
 defining the semantic class based on the main semantic class parameter, the indicator semantic class parameter and the active node parameter. 
 
   
   
     15. The computer-readable medium of  claim 14  wherein the main semantic class parameter comprises a reference to a semantic class in an external grammar. 
   
   
     16. A method of forming a grammar, the method comprising:
 displaying a user interface that provides a text area for a user to enter sentences representing possible user responses and an area for associating text strings with a semantic class, at least one semantic class being associated with multiple text strings; 
 a processor forming modified sentences from the sentences entered through the user interface by performing steps for each sentence entered through the user interface, the steps comprising:
 identifying a group of words in the sentence; 
 comparing the group of words to a list of the text strings associated with the semantic class; 
 determining that the group of words matches a text string in the list of text strings associated with the semantic class; 
 replacing the group of words in the sentences with a tag for a semantic class associated with the text string that matches the group of words while leaving other words in the sentence unchanged to form a modified sentence, the tag representing multiple text strings associated with the semantic class; and 
 
 using the modified sentences to form the grammar. 
 
   
   
     17. The method of  claim 16  further comprising identifying n-grams of a plurality of orders in the modified sentences. 
   
   
     18. The method of  claim 17  further comprising forming a separate rule in the grammar for each identified n-gram. 
   
   
     19. The method of  claim 16  wherein using the modified sentences to form the grammar comprises providing rules in the grammar for word sequences that were not present in the sentences.

Cited by (0)

No later patents cite this yet.

References (0)

No backward citations on record.