Skip to content

Commit

Permalink
Python binding (#41)
Browse files Browse the repository at this point in the history
* Init with empty module

* Add a naive wrapper

* Add PyMorpheme

* Add SplitMode class

* Split files

* Add annotations

* Add Readme for python binding

* Add license
  • Loading branch information
mh-northlander authored Sep 30, 2021
1 parent 98e9846 commit 3450c0a
Show file tree
Hide file tree
Showing 13 changed files with 763 additions and 26 deletions.
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,8 @@ README*.html
.idea/
.vscode/

# python binding
python/dist
.env
*.egg-info
*.so
223 changes: 197 additions & 26 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ members = [
"plugin/input_text/*",
"plugin/oov/*",
"plugin/path_rewrite/*",
"python"
]

default-members = [
Expand Down
21 changes: 21 additions & 0 deletions python/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
[package]
name = "sudachi-python"
version = "0.1.0"
edition = "2018"
description = "Python bindings of sudachi.rs, the Japanese Morphological Analyzer"
homepage = "https://github.com/WorksApplications/sudachi.rs"
repository = "https://github.com/WorksApplications/sudachi.rs"
license = "Apache-2.0"


[lib]
name = "sudachi_python"
crate-type = ["cdylib"]

[dependencies]
pyo3 = { version = "0.14.3", features = ["extension-module"] }

[dependencies.sudachi]
version = "*"
path = "../sudachi"

Loading

0 comments on commit 3450c0a

Please sign in to comment.