<p><div><div><div><div data-show-faces="false" data-height="21" data-width="100" data-layout="button_count" data-send="true" data-href="https://www.r-bloggers.com/crfsuite-for-natural-language-processing/"></div></div><div></div></div><div></div></div>
<div>
(This article was first published on <strong><a href="http://www.bnosac.be/index.php/blog/83-crfsuite-for-natural-language-processing"> bnosac :: open analytical helpers - bnosac :: open analytical helpers</a></strong>, and kindly contributed to <a rel="nofollow" href="https://www.r-bloggers.com/">R-bloggers)</a> </div>
<p>A new R package called <a rel="nofollow" href="https://github.com/bnosac/crfsuite" target="_blank"><strong>crfsuite</strong> </a>supported by BNOSAC landed safely on CRAN last week. The crfsuite package (<a rel="nofollow" href="https://github.com/bnosac/crfsuite" target="_blank">https://github.com/bnosac/crfsuite</a>) is an R package specific to Natural Language Processing and allows you to easily build and apply models for</p>
<ul>
<li><strong>named entity recognition </strong></li>
<li><strong>text chunking </strong></li>
<li><strong>part of speech tagging </strong></li>
<li><strong>intent recognition or </strong></li>
<li><strong>classification of any category you have in mind</strong></li>
</ul>
<p>The focus of the implementation is on allowing the R user to build such models <strong>on his/her own data, with your own categories</strong>. The R package is a Rcpp interface to the popular crfsuite C++ package which is used a lot in all kinds of chatbots.</p>
<p>In order to facilitate creating training data on your own data, a shiny app is made available in this R package which allows you to easily tag your own chunks of text, with your own categories, which can next be used to build a crfsuite model. The package also plays nicely together with the udpipe R package (<a rel="nofollow" href="https://cran.r-project.org/package=udpipe" target="_blank">https://CRAN.R-project.org/package=udpipe</a>), which you need in order to extract predictive features (e.g. parts of speech tags) for your words to be used in the crfsuite model.</p>
<p>On a side-note. If you are in the area of NLP, you might also be interested in the upcoming <a rel="nofollow" href="https://github.com/bnosac/ruimtehol" target="_blank">ruimtehol R package</a> which is a wrapper around the excellent StarSpace C++ code providing word/sentence/document embeddings, text-based classification, content-based recommendation and similarities as well as entity relationship completion.</p>
<p><img alt="app screenshot" src="https://i2.wp.com/www.bnosac.be/images/bnosac/blog/app-screenshot.png?w=456" data-recalc-dims="1"></p>
<p>You can get going with the crfsuite package as follows. Have a look at the package vignette, it shows you how to construct and apply your own crfsuite model.</p>
<pre>## Install the packages<br>install.packages(&quot;crfsuite&quot;)<br>install.packages(&quot;udpipe&quot;)<br><br>## Look at the vignette<br>library(crfsuite)<br>library(udpipe)<br>vignette(&quot;crfsuite-nlp&quot;, package = &quot;crfsuite&quot;)</pre>
<p>More details at the development repository <a rel="nofollow" href="https://github.com/bnosac/crfsuite" target="_blank">https://github.com/bnosac/crfsuite</a> where you can also provide feedback.</p>
<h3><strong>Training on Text Mining <br></strong></h3>
<p>Are you interested in how text mining techniques work, then you might be interested in the following data science courses that are held in the coming months.<img alt="rtraining" src="https://i1.wp.com/www.bnosac.be/images/bnosac/blog/rtraining.png?w=456" data-recalc-dims="1"></p>
<ul>
<li><strong>20-21/11/2018: Text mining with R. Leuven (Belgium). Subscribe <a rel="nofollow" href="https://lstat.kuleuven.be/training/coursedescriptions/text-mining-with-r" target="_blank">here</a></strong></li>
<li>19-20/12/2018: Applied spatial modelling with R. Leuven (Belgium). Subscribe <a rel="nofollow" href="https://lstat.kuleuven.be/training/applied-spatial-modelling-with-r" target="_blank">here</a></li>
<li>21-22/02/2018: Advanced R programming. Leuven (Belgium). Subscribe <a rel="nofollow" href="https://lstat.kuleuven.be/training/coursedescriptions/AdvancedprogramminginR.html" target="_blank">here</a></li>
<li>13-14/03/2018: Computer Vision with R and Python. Leuven (Belgium). Subscribe <a rel="nofollow" href="https://lstat.kuleuven.be/training/coursedescriptions/ComputervisionwithRandPython" target="_blank">here</a></li>
<li>     15/03/2019: Image Recognition with R and Python: Subscribe <a rel="nofollow" href="https://lstat.kuleuven.be/training/coursedescriptions/Imagerecognition" target="_blank">here</a></li>
<li><strong>01-02/04/2019: Text Mining with R. Leuven (Belgium). Subscribe <a rel="nofollow" href="https://lstat.kuleuven.be/training/coursedescriptions/text-mining-with-r" target="_blank">here</a></strong></li>
</ul>
	<p>
<div>
<div>To <strong>leave a comment</strong> for the author, please follow the link and comment on their blog: <strong><a href="http://www.bnosac.be/index.php/blog/83-crfsuite-for-natural-language-processing"> bnosac :: open analytical helpers - bnosac :: open analytical helpers</a></strong>.</div>
<hr>
<a rel="nofollow" href="https://www.r-bloggers.com/">R-bloggers.com</a> offers <strong><a rel="nofollow" href="https://feedburner.google.com/fb/a/mailverify?uri=RBloggers">daily e-mail updates</a></strong> about <a rel="nofollow" href="https://www.r-project.org/" title="The R Project for Statistical Computing">R</a> news and <a rel="nofollow" href="https://www.r-bloggers.com/search/tutorial" title="R tutorials">tutorials</a> on topics such as: <a rel="nofollow" href="https://www.r-bloggers.com/search/data%20science" title="Data science">Data science</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/Big%20Data" title="Big Data">Big Data, <a rel="nofollow" href="https://www.r-users.com/" title="R jobs">R jobs</a>, visualization (<a rel="nofollow" href="https://www.r-bloggers.com/search/ggplot2" title="ggplot and ggplot2 tutorials">ggplot2</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/boxplot" title="Boxplots using lattice and ggplot2 tutorials">Boxplots</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/map" title="Maps and gis">maps</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/animation" title="Animation in R">animation</a>), programming (<a rel="nofollow" href="https://www.r-bloggers.com/search/RStudio" title="RStudio IDE for R">RStudio</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/sweave" title="Sweave and literate programming">Sweave</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/LaTeX" title="LaTeX in R">LaTeX</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/SQL" title="SQL and databases">SQL</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/eclipse" title="Eclipse IDE for R">Eclipse</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/git" title="git and github, Version Control System">git</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/hadoop" title="Large data in R using Hadoop">hadoop</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/Web+Scraping" title="Web Scraping of google, facebook, yahoo, twitter and more using R">Web Scraping</a>) statistics (<a rel="nofollow" href="https://www.r-bloggers.com/search/regression" title="Regressions and ANOVA analysis tutorials">regression</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/PCA" title="principal component analysis tutorial">PCA</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/time+series" title="Time series">time series</a>, <a rel="nofollow" href="https://www.r-bloggers.com/search/trading" title="finance trading">trading</a>) and more...
<img width="1" alt="" src="http://feeds.feedburner.com/~r/RBloggers/~4/43abDp7B-QY" height="1"></a></div>