No project description provided
Project description
rccnlp
RCC 自然言語処理班で使うツールキットです。
実行環境
- Python 3
インストール
$ pip install rccnlp
使い方
センチメント分析
from rccnlp.sentiment import Analyzer
analyzer = Analyzer()
analyzer.analyze('天国で待ってる。')
# => [1.0]
analyzer.analyze('遅刻したけど楽しかったし嬉しかった。すごく充実した!')
# => [0.3333333333333333, 1.0]
analyzer.count_polarity('遅刻したけど楽しかったし嬉しかった。すごく充実した!')
# => [{'positive': 2, 'negative': 1}, {'positive': 1, 'negative': 0}])
analyzer.count_polarity('そこにはいつもと変わらない日常があった。')
# => [{'positive': 0, 'negative': 0}]
analyzer.analyze_detail('お金も希望もない!')
# => [{'positive': [], 'negative': ['お金-NEGATION', '希望-NEGATION'], 'score': -1.0}])
analyzer.analyze_detail('お金がないわけではない')
# => [{'positive': ['お金'], 'negative': [], 'score': 1.0}]
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
rccnlp-0.1.0.tar.gz
(72.7 kB
view details)
Built Distribution
rccnlp-0.1.0-py3-none-any.whl
(72.5 kB
view details)
File details
Details for the file rccnlp-0.1.0.tar.gz
.
File metadata
- Download URL: rccnlp-0.1.0.tar.gz
- Upload date:
- Size: 72.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.55.1 CPython/3.8.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 677f508fc18d36df7d322f20ccb88eb6c89a4b4c310b1d4a3611b2476e3961c4 |
|
MD5 | 48ab65bc6809ade659783d8e8033aea7 |
|
BLAKE2b-256 | 3e17c72d2b4d1b4a39d808d95a82e923d10b14c988ed192a6b0883508132eae7 |
File details
Details for the file rccnlp-0.1.0-py3-none-any.whl
.
File metadata
- Download URL: rccnlp-0.1.0-py3-none-any.whl
- Upload date:
- Size: 72.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.55.1 CPython/3.8.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 15bfc6ddcddd2455cacf96649d78246ab114bde67e10f60c1ebea29bbe8467e1 |
|
MD5 | 6198114b4705da115fe54ff7b8a8eecc |
|
BLAKE2b-256 | 840979661246375e799d239c5c6c42d4248a5f944c86949d04fe5e0fde1ac505 |