Python wrapper for CaboCha: Japanese Dependency Structure Analyzer
Project description
cabocha-python
This is a python wrapper for CaboCha Japanese Dependency Structure Analyzer.
NOTE: It does not sopport Windows Python 64bit version.
Japanese document is available.
USAGE
>>> import CaboCha
>>> c = CaboCha.Parser()
>>> sentence = "太郎はこの本を二郎を見た女性に渡した。"
>>> print(c.parseToString(sentence))
太郎は-----------D
この-D |
本を---D |
二郎を-D |
見た-D |
女性に-D
渡した。
EOS
>>> tree = c.parse(sentence)
>>> print(tree.toString(CaboCha.FORMAT_TREE))
太郎は-----------D
この-D |
本を---D |
二郎を-D |
見た-D |
女性に-D
渡した。
EOS
>>> print(tree.toString(CaboCha.FORMAT_LATTICE))
* 0 6D 0/1 -2.457381
太郎 名詞,固有名詞,人名,名,*,*,太郎,タロウ,タロー
は 助詞,係助詞,*,*,*,*,は,ハ,ワ
* 1 2D 0/0 1.488413
この 連体詞,*,*,*,*,*,この,コノ,コノ
* 2 4D 0/1 0.091699
本 名詞,一般,*,*,*,*,本,ホン,ホン
を 助詞,格助詞,一般,*,*,*,を,ヲ,ヲ
* 3 4D 0/1 2.266072
二郎 名詞,固有名詞,人名,名,*,*,二郎,ジロウ,ジロー
を 助詞,格助詞,一般,*,*,*,を,ヲ,ヲ
* 4 5D 0/1 1.416783
見 動詞,自立,*,*,一段,連用形,見る,ミ,ミ
た 助動詞,*,*,*,特殊・タ,基本形,た,タ,タ
* 5 6D 0/1 -2.457381
女性 名詞,一般,*,*,*,*,女性,ジョセイ,ジョセイ
に 助詞,格助詞,一般,*,*,*,に,ニ,ニ
* 6 -1D 0/1 0.000000
渡し 動詞,自立,*,*,五段・サ行,連用形,渡す,ワタシ,ワタシ
た 助動詞,*,*,*,特殊・タ,基本形,た,タ,タ
。 記号,句点,*,*,*,*,。,。,。
EOS
License
CaboCha is copyrighted free software by Taku Kudo <taku@chasen.org> is released under any of the the LGPL (see the file LGPL) or the BSD License (see the file BSD).
CHANGES
0.69.1 (2019-09-21)
Avoid the compilation error: ‘Python.h’ file not found
Update codes by swig 4.0.1
0.69 (2019-03-04)
First release to PyPI
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
cabocha-python-0.69.1.tar.gz
(49.6 kB
view hashes)
Built Distributions
Close
Hashes for cabocha_python-0.69.1-cp38-cp38-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 019fc7ecd9860dc7c6580924b973ab0f91a8fff318ddef8582be2ad1cea20de4 |
|
MD5 | 977b5753d6b0bfd773a043516e96122a |
|
BLAKE2b-256 | 42484ec1e36b0d6c82c471dd6cd9a0eee2323d2faa2fc81351ebb2d4a9d8965d |
Close
Hashes for cabocha_python-0.69.1-cp37-cp37m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 23f74c605f75ee8ea93371670079ca88280639ba8ca6ad576f40a5be4dfeecf9 |
|
MD5 | bdda69bd525d4c985dc50e77110e648c |
|
BLAKE2b-256 | f5d5cec8e298af5dcf90088d7938c56605ef7ab0aacff3b0556de3396dc1fd34 |
Close
Hashes for cabocha_python-0.69.1-cp36-cp36m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4dea15f8bc1d007ce09044bbbdc7f8ada68090d70b004b96b4bc4504bd52b2de |
|
MD5 | cf39f8699d08dca0d18f92867f06827d |
|
BLAKE2b-256 | 5b607598911db6c296578d8eb276d13835180d760d59d6004941cdb7ac9c70a3 |
Close
Hashes for cabocha_python-0.69.1-cp27-cp27m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | eb517ba9ccb5787179b98880984e66273ea6c6a383ee641f0f06ddaf834aacb5 |
|
MD5 | 4c127024cf49a5f59f0e3ad5e8ff1a5e |
|
BLAKE2b-256 | d0c3e942ab9211d2afd3c131fe32684e9e8102b2bde226743179e69be05e4ada |