2.0.0 • Published 11 months ago

@jser/classifier-item-category v2.0.0

Weekly downloads
20
License
MIT
Repository
github
Last release
11 months ago

@jser/classifier-item-category

Classifier category from JSer item or text.

テキストからJSer.infoにおけるカテゴライズをベイズ推論して、カテゴリ名を返します。

カテゴリは次の通りです。

var Category = {
    Headline: "ヘッドライン",
    Article: "アーティクル",
    SlideVideo: "スライド、動画関係",
    WebsiteDocument: "サイト、サービス、ドキュメント",
    SoftwareLibrary: "ソフトウェア、ツール、ライブラリ関係",
    Book: "書籍関係"
};

Install

Install with npm:

npm install @jser/classifier-item-category

Usage

import { fetchPostDetails } from "@jser/data-fetcher";
import { JSerClassifier, CategoryKey } from "@jser/classifier-item-category";
(async () => {
   const postDetails = await fetchPostDetails();
   const classifier = new JSerClassifier({
       postDetails
   });
   classifier.classifyText("これはGitHubで公開されている言語処理のライブラリです。");
   // === CategoryKey.SoftwareLibrary
})()

Changelog

See Releases page.

Running tests

Install devDependencies and Run npm test:

npm i -d && npm test

Contributing

Pull requests and stars are always welcome.

For bugs and feature requests, please create an issue.

  1. Fork it!
  2. Create your feature branch: git checkout -b my-new-feature
  3. Commit your changes: git commit -am 'Add some feature'
  4. Push to the branch: git push origin my-new-feature
  5. Submit a pull request :D

Author

License

MIT © azu

2.0.0

11 months ago

1.2.1

3 years ago

1.2.0

3 years ago

1.1.6

3 years ago

1.1.5

5 years ago

1.1.2

6 years ago

1.1.0

6 years ago

1.0.1

6 years ago