BotSharp/BotSharp.NLP
2018-09-21 15:11:57 -05:00
..
Classify Improve intent accuracy greater than 0.7 2018-09-13 15:01:40 -05:00
Corpus Added Fasttext labeled data reader. 2018-09-08 22:59:01 -05:00
Featuring Improve intent accuracy greater than 0.7 2018-09-13 15:01:40 -05:00
Models Fix NER offset issue. 2018-09-14 11:31:35 -05:00
NER Merge NLP and Algorithm sub project into one solution. 2018-09-03 21:05:57 -05:00
Stem Merge NLP and Algorithm sub project into one solution. 2018-09-03 21:05:57 -05:00
Tag Official support Simple Chinese tokenize and POS tagger. 2018-09-20 11:45:25 -05:00
Tokenize Official support Simple Chinese tokenize and POS tagger. 2018-09-20 11:45:25 -05:00
Txt2Vec Improve intent accuracy greater than 0.7 2018-09-13 15:01:40 -05:00
BotSharp.NLP.csproj Dialogflow compatibility improvement 1 2018-09-21 15:11:57 -05:00
NlpEntity.cs Merge NLP and Algorithm sub project into one solution. 2018-09-03 21:05:57 -05:00
README.rst Merge NLP and Algorithm sub project into one solution. 2018-09-03 21:05:57 -05:00
Sentence.cs One Hot Encoding 2018-09-10 22:35:33 -05:00
SupportedLanguage.cs Merge NLP and Algorithm sub project into one solution. 2018-09-03 21:05:57 -05:00

BotSharp.NLP
############
Botsharp.NLP is a set of tools for building C# programs to work with human language data. It is the NLP low-level processing library of the BotSharp robot construction platform. It provides a separate installation package for downloading. It can be used as a common POS, NER and text classification service in the NLP field, providing a variety of machine learning algorithms to switch freely.


How to install
==============
1. Install through NuGet
::

  PM> Install-Package BotSharp.NL

2. Download source code
::

  git clone https://github.com/Oceania2018/BotSharp.NLP

Start to use
============
::

  public void TokenizeInWhiteSpace()
  {
	// use RegexTokenizer
    var tokenizer = new TokenizerFactory<RegexTokenizer>();
    
    // tokenize and return tokens
    var tokens = tokenizer.Tokenize("Chop into pieces, isn't it?",
                new TokenizationOptions
                {
                	// use built-in regex pattern
                    Pattern = RegexTokenizer.WHITE_SPACE
                });
    
    // test result
    Assert.IsTrue(tokens[0].Offset == 0);
    Assert.IsTrue(tokens[0].Text == "Chop");
    
    Assert.IsTrue(tokens[1].Offset == 5);
    Assert.IsTrue(tokens[1].Text == "into");
  }