Please help on refering an N-gram XML file

Hi, 

I'm trying to use the SLM specification (http://www.w3.org/TR/2001/WD-ngram-spec-20010103/) into a wider grammar ..

the main grammar's content is :

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE grammar PUBLIC "-//W3C//DTD GRAMMAR 1.0//EN" "http://www.w3.org/TR/speech-grammar/grammar.dtd">
<grammar 
version="1.0" 
xml:lang="fr-ca"
 mode="voice" 
root="main" 
xmlns="http://www.w3.org/2001/06/grammar"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xsi:schemaLocation="http://www.w3.org/2001/06/grammar http://www.w3.org/TR/speech-grammar/grammar.xsd">
<rule id="main" scope="public">
<ruleref uri="file:///C:/Users/administrateur/Desktop/grammar.xml" type="application/srgs+xml"/>
</rule>
</grammar>

and the Ngram file's content is : 

<?xml version="1.0" encoding="utf-8"?>
<N-Gram xml:lang="fr-FR">
<lexicon>
</lexicon>
<tree>
</tree>
</N-Gram>

My C# application returns an exception : 
System.FormatException was unhandled 
Message="A rule reference to an imported grammar cannot be resolved." 
Source="System.Speech" 
StackTrace: 
at 
System.Speech.Recognition.RecognizerBase.LoadSapiGrammarFromCfg(SapiGrammar 
sapiGrammar, Grammar grammar, Uri baseUri, Boolean enabled, Single 
weight, Int32 priority) 
   at System.Speech.Recognition.RecognizerBase.LoadSapiGrammar(Grammar 
grammar, SapiGrammar sapiGrammar, Boolean enabled, Single weight, 
Int32 priority) 
   at System.Speech.Recognition.RecognizerBase.LoadGrammar(Grammar 
grammar) 
   at 
System.Speech.Recognition.SpeechRecognitionEngine.LoadGrammar(Grammar 
grammar) 


So my questions are :  is the W3C Ngram grammar specification 
suported by SAPI 5.3 ? I it is, can someone help me out  please ? 

Received on Wednesday, 14 February 2007 18:36:12 UTC