Skip to content

matsurih/jdeppy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

jdeppy

Python wrapper for J.DepP, fast Japanese Dependency Parser.

Requisites

You need to install J.DepP.

See "Download & Setup" section in http://www.tkl.iis.u-tokyo.ac.jp/~ynaga/jdepp/

Install

pip install jdeppy

Usage

from jdeppy.JDepP import JDepP

jdepp = JDepP()
result = jdepp.parse('今日はいい天気ですね')

# result => list of Sentences
# Sentence => s_id: int and blist: list of Bunsetsus
# Bunsetsu => b_id: int and dep_id: int and mlist: list of Morphs
#   - b_id means 'Bunsetsu ID'
#   - dep_id means 'Bunsetsu ID this Bunsetsu depends on'
# Morph => surface: str and feature: list of strs
#   - feature's format is the same as mecab-python3

Unidic Support

Jdeppy expects to use IPADIC, but you can also use UniDic. Pass dic_type="unidic" argument to the JDepP class constructor (default dic_type is ipadic).

from jdeppy.JDepP import JDepP

jdepp = JDepP(dic_type='unidic')

License

This software is released under the MIT License, see LICENSE.txt.

About

Python wrapper for J.DepP

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages