README.md (4526B)
1 <!-- 2 3 @license Apache-2.0 4 5 Copyright (c) 2018 The Stdlib Authors. 6 7 Licensed under the Apache License, Version 2.0 (the "License"); 8 you may not use this file except in compliance with the License. 9 You may obtain a copy of the License at 10 11 http://www.apache.org/licenses/LICENSE-2.0 12 13 Unless required by applicable law or agreed to in writing, software 14 distributed under the License is distributed on an "AS IS" BASIS, 15 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 16 See the License for the specific language governing permissions and 17 limitations under the License. 18 19 --> 20 21 # Natural Language Processing 22 23 [![NPM version][npm-image]][npm-url] [![Build Status][test-image]][test-url] [![Coverage Status][coverage-image]][coverage-url] [![dependencies][dependencies-image]][dependencies-url] 24 25 > Standard library natural language processing (NLP). 26 27 <section class="installation"> 28 29 ## Installation 30 31 ```bash 32 npm install @stdlib/nlp 33 ``` 34 35 </section> 36 37 <section class="usage"> 38 39 ## Usage 40 41 ```javascript 42 var nlp = require( '@stdlib/nlp' ); 43 ``` 44 45 #### nlp 46 47 Standard library natural language processing (NLP). 48 49 ```javascript 50 var fcns = nlp; 51 // returns {...} 52 ``` 53 54 <!-- <toc pattern="*"> --> 55 56 <div class="namespace-toc"> 57 58 - <span class="signature">[`expandContractions( str )`][@stdlib/nlp/expand-contractions]</span><span class="delimiter">: </span><span class="description">expand all contractions to their formal equivalents.</span> 59 - <span class="signature">[`lda( docs, K[, options] )`][@stdlib/nlp/lda]</span><span class="delimiter">: </span><span class="description">latent Dirichlet Allocation via collapsed Gibbs sampling.</span> 60 - <span class="signature">[`porterStemmer( word )`][@stdlib/nlp/porter-stemmer]</span><span class="delimiter">: </span><span class="description">extract the stem of a given word.</span> 61 - <span class="signature">[`tokenize( str[, keepWhitespace] )`][@stdlib/nlp/tokenize]</span><span class="delimiter">: </span><span class="description">tokenize a string.</span> 62 63 </div> 64 65 <!-- </toc> --> 66 67 </section> 68 69 <!-- /.usage --> 70 71 <section class="examples"> 72 73 ## Examples 74 75 <!-- TODO: better examples --> 76 77 <!-- eslint no-undef: "error" --> 78 79 ```javascript 80 var objectKeys = require( '@stdlib/utils/keys' ); 81 var nlp = require( '@stdlib/nlp' ); 82 83 console.log( objectKeys( nlp ) ); 84 ``` 85 86 </section> 87 88 <!-- /.examples --> 89 90 91 <section class="main-repo" > 92 93 * * * 94 95 ## Notice 96 97 This package is part of [stdlib][stdlib], a standard library for JavaScript and Node.js, with an emphasis on numerical and scientific computing. The library provides a collection of robust, high performance libraries for mathematics, statistics, streams, utilities, and more. 98 99 For more information on the project, filing bug reports and feature requests, and guidance on how to develop [stdlib][stdlib], see the main project [repository][stdlib]. 100 101 #### Community 102 103 [![Chat][chat-image]][chat-url] 104 105 --- 106 107 ## License 108 109 See [LICENSE][stdlib-license]. 110 111 112 ## Copyright 113 114 Copyright © 2016-2021. The Stdlib [Authors][stdlib-authors]. 115 116 </section> 117 118 <!-- /.stdlib --> 119 120 <!-- Section for all links. Make sure to keep an empty line after the `section` element and another before the `/section` close. --> 121 122 <section class="links"> 123 124 [npm-image]: http://img.shields.io/npm/v/@stdlib/nlp.svg 125 [npm-url]: https://npmjs.org/package/@stdlib/nlp 126 127 [test-image]: https://github.com/stdlib-js/nlp/actions/workflows/test.yml/badge.svg 128 [test-url]: https://github.com/stdlib-js/nlp/actions/workflows/test.yml 129 130 [coverage-image]: https://img.shields.io/codecov/c/github/stdlib-js/nlp/main.svg 131 [coverage-url]: https://codecov.io/github/stdlib-js/nlp?branch=main 132 133 [dependencies-image]: https://img.shields.io/david/stdlib-js/nlp.svg 134 [dependencies-url]: https://david-dm.org/stdlib-js/nlp/main 135 136 [chat-image]: https://img.shields.io/gitter/room/stdlib-js/stdlib.svg 137 [chat-url]: https://gitter.im/stdlib-js/stdlib/ 138 139 [stdlib]: https://github.com/stdlib-js/stdlib 140 141 [stdlib-authors]: https://github.com/stdlib-js/stdlib/graphs/contributors 142 143 [stdlib-license]: https://raw.githubusercontent.com/stdlib-js/nlp/main/LICENSE 144 145 <!-- <toc-links> --> 146 147 [@stdlib/nlp/expand-contractions]: https://www.npmjs.com/package/@stdlib/nlp/tree/main/expand-contractions 148 149 [@stdlib/nlp/lda]: https://www.npmjs.com/package/@stdlib/nlp/tree/main/lda 150 151 [@stdlib/nlp/porter-stemmer]: https://www.npmjs.com/package/@stdlib/nlp/tree/main/porter-stemmer 152 153 [@stdlib/nlp/tokenize]: https://www.npmjs.com/package/@stdlib/nlp/tree/main/tokenize 154 155 <!-- </toc-links> --> 156 157 </section> 158 159 <!-- /.links -->