private void HandleGetCustomCorpora(Corpora corpora, string customData) { if (!string.IsNullOrEmpty(customData)) { Log.Debug("ExampleSpeechToText", "CustomData: {0}", customData); } if (corpora != null) { if (corpora.corpora.Length > 0) { foreach (Corpus corpus in corpora.corpora) { Log.Debug("ExampleSpeechToText", "Corpus - name: {0} | total_words: {1} | out_of_vocabulary_words: {2} | staus: {3}", corpus.name, corpus.total_words, corpus.out_of_vocabulary_words, corpus.status); } //TestUpgradeCustomization(m_CreatedCustomizationID); TestTrainCustomization(m_CreatedCustomizationID); } else { Log.Debug("ExampleSpeechToText", "There are no custom corpora!"); } Log.Debug("ExampleSpeechToText", "GetCustomCorpora() succeeded!"); TestDeleteCustomization(m_CreatedCustomizationID); } else { Log.Debug("ExampleSpeechToText", "Failed to get custom corpora!"); } }
private void HandleGetCustomCorpora(Corpora corpora, string customData) { if (!string.IsNullOrEmpty(customData)) { Log.Debug("TestSpeechToText", "CustomData: {0}", customData); } if (corpora != null) { if (corpora.corpora.Length > 0) { foreach (Corpus corpus in corpora.corpora) { Log.Debug("TestSpeechToText", "Corpus - name: {0} | total_words: {1} | out_of_vocabulary_words: {2} | staus: {3}", corpus.name, corpus.total_words, corpus.out_of_vocabulary_words, corpus.status); } } else { Log.Debug("TestSpeechToText", "There are no custom corpora!"); } Log.Debug("TestSpeechToText", "GetCustomCorpora() succeeded!"); } else { Log.Debug("TestSpeechToText", "Failed to get custom corpora!"); } Test(corpora != null); m_GetCustomCorporaTested = true; }
public Corpora ListCorpora(string customizationId) { Corpora result = null; if (string.IsNullOrEmpty(customizationId)) { throw new ArgumentNullException($"{nameof(customizationId)}"); } try { result = this.Client.WithAuthentication(this.UserName, this.Password) .GetAsync($"{this.Endpoint}{PATH_CUSTOM_MODEL}/{customizationId}/corpora") .As <Corpora>() .Result; } catch (AggregateException ae) { throw ae.InnerException as ServiceResponseException; } return(result); }
private void HandleGetCustomCorpora(Corpora corpora, Dictionary <string, object> customData) { Log.Debug("ExampleSpeechToText.HandleGetCustomCorpora()", "{0}", customData["json"].ToString()); _getCustomCorporaTested = true; }
private void HandleGetCustomCorpora(Corpora corpora, string customData) { Log.Debug("ExampleSpeechToText", "Speech to Text - Get custom corpora response: {0}", customData); Test(corpora != null); _getCustomCorporaTested = true; }