Пример #1
0
        /// <summary>
        /// Initializes a new instance of the class with default settings.
        /// </summary>
        /// <remarks>
        /// Some of these defualt settings, like lambda, beta and unk percentage, are the result
        /// of multiple tests and optimizations.
        /// </remarks>
        public LanguageModel()
        {
            Settings = new LanguageModelSettings
            {
                NGramOrder = 3,
                LogBase = 2,
                StartToken = "{{*}}",
                EndToken = "{{END}}",
                UnkToken = "{{UNK}}",
                UnkPercentage = 100,
                Separator = " ",
                PossibleEnd = ".",
                StringComparison = StringComparison.Ordinal,
                StringComparer = StringComparer.Ordinal
            };

            Init();
        }
Пример #2
0
 public BackOffModel(LanguageModelSettings settings)
     : base(settings)
 {
     Init();
 }
Пример #3
0
 public LanguageModel(LanguageModelSettings settings)
 {
     Settings = settings;
     Init();
 }
 public ExampleBackOffModelWithDiscounting(LanguageModelSettings settings)
     : base(settings)
 {
 }