예제 #1
0
 public virtual ConditionalProbabilityResponse CalculateConditionalProbability(WebLMModelOptions model, ConditionalProbabilityRequest request, int order = 5)
 {
     return(PolicyService.ExecuteRetryAndCapture400Errors(
                "WebLanguageModelService.CalculateConditionalProbability",
                ApiKeys.WebLMRetryInSeconds,
                () =>
     {
         var result = WebLanguageModelRepository.CalculateConditionalProbability(model, request, order);
         return result;
     },
                null));
 }
예제 #2
0
        public virtual ConditionalProbabilityResponse CalculateConditionalProbability(WebLMModelOptions model, ConditionalProbabilityRequest request, int order = 5)
        {
            try
            {
                var result = WebLanguageModelRepository.CalculateConditionalProbability(model, request, order);

                return(result);
            }
            catch (Exception ex)
            {
                Logger.Error("WebLanguageModelService.CalculateConditionalProbability failed", this, ex);
            }

            return(null);
        }