Skip to main content

SynCha-CaboCha-MeCab wrapper for spaCy

Project description

Current PyPI packages

spaCy-SynCha

SynCha-CaboCha-MeCab wrapper for spaCy

Basic Usage

>>> import spacy_syncha
>>> nlp=spacy_syncha.load()
>>> doc=nlp("太郎は花子が読んでいる本を次郎に渡した")
>>> for t in doc:
...   print(t.i,t.orth_,t.lemma_,t.pos_,t.tag_,t.head.i,t.dep_,t.norm_,t.ent_iob_,t.ent_type_)
...
0 太郎 太郎 PROPN 名詞-固有名詞-人名- 12 nsubj タロウ B PERSON
1   ADP 助詞-係助詞 0 case  O
2 花子 花子 PROPN 名詞-固有名詞-人名- 4 nsubj ハナコ B PERSON
3   ADP 助詞-格助詞-一般 2 case  O
4 読ん 読む VERB 動詞-自立 7 acl ヨン O
5   CCONJ 助詞-接続助詞 4 mark  O
6 いる いる AUX 動詞-非自立 4 aux イル O
7   NOUN 名詞-一般 12 obj ホン O
8   ADP 助詞-格助詞-一般 7 case  O
9   NOUN 名詞-一般 10 compound ツギ O
10   NOUN 名詞-一般 12 iobj ロウ O
11   ADP 助詞-格助詞-一般 10 case  O
12 渡し 渡す VERB 動詞-自立 12 ROOT ワタシ O
13   AUX 助動詞 12 aux  O

Installation for Linux

Make sure to pre-install SynCha, CaboCha, and MeCab:

pip install spacy_syncha

Installation for Cygwin

Make sure to get python37-devel python37-pip python37-cython python37-numpy git gcc-g++ perl:

pip3.7 install git+https://github.com/KoichiYasuoka/syncha-cygwin
pip3.7 install spacy_syncha --no-build-isolation

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

spacy_syncha-0.1.3.tar.gz (4.9 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page