Skip to main content

jieba-rs Python binding

Project description

rjieba-py

CI PyPI

jieba-rs Python binding.

Installation

pip install rjieba

Usage

import rjieba


print(rjieba.cut('我们中出了一个叛徒'))
print(rjieba.tag('我们中出了一个叛徒'))

Performance

In [1]: import jieba

In [2]: import cjieba

In [3]: import rjieba

In [4]: jieba.initialize()
Building prefix dict from the default dictionary ...
Loading model from cache /var/folders/8d/h3lyjgz14296j_lw7chgf5hc0000gp/T/jieba.cache
Loading model cost 0.655 seconds.
Prefix dict has been built successfully.

In [5]: cjieba.initialize()

In [6]: with open('../jieba-rs/examples/weicheng/src/weicheng.txt') as f:
   ...:     txt = f.read()
   ...:

In [7]: %timeit list(jieba.cut(txt))
1.12 s ± 9.1 ms per loop (mean ± std. dev. of 7 runs, 1 loop each)

In [8]: %timeit cjieba.cut(txt)
242 ms ± 8.1 ms per loop (mean ± std. dev. of 7 runs, 1 loop each)

In [9]: %timeit rjieba.cut(txt)
110 ms ± 1.35 ms per loop (mean ± std. dev. of 7 runs, 10 loops each)

License

This work is released under the MIT license. A copy of the license is provided in the LICENSE file.

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

rjieba-0.1.1.tar.gz (4.7 kB view details)

Uploaded Source

Built Distributions

rjieba-0.1.1-cp39-none-win_amd64.whl (2.7 MB view details)

Uploaded CPython 3.9 Windows x86-64

rjieba-0.1.1-cp39-cp39-manylinux1_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.9

rjieba-0.1.1-cp39-cp39-macosx_10_7_x86_64.whl (2.8 MB view details)

Uploaded CPython 3.9 macOS 10.7+ x86-64

rjieba-0.1.1-cp38-none-win_amd64.whl (2.7 MB view details)

Uploaded CPython 3.8 Windows x86-64

rjieba-0.1.1-cp38-cp38-manylinux1_x86_64.whl (3.6 MB view details)

Uploaded CPython 3.8

rjieba-0.1.1-cp38-cp38-macosx_10_7_x86_64.whl (2.8 MB view details)

Uploaded CPython 3.8 macOS 10.7+ x86-64

rjieba-0.1.1-cp37-none-win_amd64.whl (2.7 MB view details)

Uploaded CPython 3.7 Windows x86-64

rjieba-0.1.1-cp37-cp37m-manylinux1_x86_64.whl (3.6 MB view details)

Uploaded CPython 3.7m

rjieba-0.1.1-cp37-cp37m-macosx_10_7_x86_64.whl (2.8 MB view details)

Uploaded CPython 3.7m macOS 10.7+ x86-64

rjieba-0.1.1-cp36-none-win_amd64.whl (2.7 MB view details)

Uploaded CPython 3.6 Windows x86-64

rjieba-0.1.1-cp36-cp36m-manylinux1_x86_64.whl (3.6 MB view details)

Uploaded CPython 3.6m

rjieba-0.1.1-cp36-cp36m-macosx_10_7_x86_64.whl (2.8 MB view details)

Uploaded CPython 3.6m macOS 10.7+ x86-64

rjieba-0.1.1-cp35-none-win_amd64.whl (2.7 MB view details)

Uploaded CPython 3.5 Windows x86-64

rjieba-0.1.1-cp35-cp35m-manylinux1_x86_64.whl (3.6 MB view details)

Uploaded CPython 3.5m

rjieba-0.1.1-cp35-cp35m-macosx_10_7_x86_64.whl (2.8 MB view details)

Uploaded CPython 3.5m macOS 10.7+ x86-64

File details

Details for the file rjieba-0.1.1.tar.gz.

File metadata

  • Download URL: rjieba-0.1.1.tar.gz
  • Upload date:
  • Size: 4.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.8.5

File hashes

Hashes for rjieba-0.1.1.tar.gz
Algorithm Hash digest
SHA256 f84f42761dda0361f51221bb01fa09f652d5f44adef25491ccd2811ce24be162
MD5 6a08584e1082859c01bad1a9d97f83f8
BLAKE2b-256 7108c3a3bc70b0ab7a97d750bd0a2b8960e4901bb2706dc080515e88f8021a63

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp39-none-win_amd64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp39-none-win_amd64.whl
  • Upload date:
  • Size: 2.7 MB
  • Tags: CPython 3.9, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.9.0

File hashes

Hashes for rjieba-0.1.1-cp39-none-win_amd64.whl
Algorithm Hash digest
SHA256 77a28babe0c4ce621f4bd16adc781bc484338467e688b295be08fd37919311bd
MD5 0a076d03f9e4bdd01364a7fbe2e06cab
BLAKE2b-256 48349b11fc8cd0147bd0187a0777b62c3ee883d551b6a95a7ec14bca5af339db

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp39-cp39-manylinux1_x86_64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp39-cp39-manylinux1_x86_64.whl
  • Upload date:
  • Size: 3.7 MB
  • Tags: CPython 3.9
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.8.6

File hashes

Hashes for rjieba-0.1.1-cp39-cp39-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 459b13e22a970a621ad51e96ff626311a125b71f92d1951eef79de778ab5503e
MD5 5d6e76583fc8e3c4ba80b582325bbc27
BLAKE2b-256 b0550590befafb291cc7694845665f4b2bf9797d2fc0d5016ae6092ca5cdc107

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp39-cp39-macosx_10_7_x86_64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp39-cp39-macosx_10_7_x86_64.whl
  • Upload date:
  • Size: 2.8 MB
  • Tags: CPython 3.9, macOS 10.7+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.9.0

File hashes

Hashes for rjieba-0.1.1-cp39-cp39-macosx_10_7_x86_64.whl
Algorithm Hash digest
SHA256 b76a4b9ccdae5538f21053bd92c13255142869815b109f54bdf13a7fec2b2ccb
MD5 c19041a28a3a8ab6a95a2565b692dfa6
BLAKE2b-256 7717d42b8d121b58b5b9c8e51a42ccd4c673b7230150e5fc8f1d4a2164f02b22

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp38-none-win_amd64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp38-none-win_amd64.whl
  • Upload date:
  • Size: 2.7 MB
  • Tags: CPython 3.8, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/28.8.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.5.4

File hashes

Hashes for rjieba-0.1.1-cp38-none-win_amd64.whl
Algorithm Hash digest
SHA256 00fbfdbc8433e9f6084cb2241e449e198fe0b9331715a1139ff689d0661233f7
MD5 db05697414848174a530db857addb4d9
BLAKE2b-256 336acf3ab5305efbb9963d01375178d3ab0ef76a5b52aea44ac2cd219e950946

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp38-cp38-manylinux1_x86_64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp38-cp38-manylinux1_x86_64.whl
  • Upload date:
  • Size: 3.6 MB
  • Tags: CPython 3.8
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.8.5

File hashes

Hashes for rjieba-0.1.1-cp38-cp38-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 9f767d8008469080850ad2b591b2f6c33483ea7abbaa00855690e15fd9d9d88b
MD5 95c0123f3c0c6b58c6c179d2c305cc12
BLAKE2b-256 693b4dd3747520d1e031169e64983a42ede1f9c69d0358c5b4d02a38074e5fc1

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp38-cp38-macosx_10_7_x86_64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp38-cp38-macosx_10_7_x86_64.whl
  • Upload date:
  • Size: 2.8 MB
  • Tags: CPython 3.8, macOS 10.7+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/28.8.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.5.9

File hashes

Hashes for rjieba-0.1.1-cp38-cp38-macosx_10_7_x86_64.whl
Algorithm Hash digest
SHA256 84a27a42cbfe892c1cf334a2976dcb8bf61eb53f5d2f5d9f9c636a196ee65f1d
MD5 264674f77718c44af25fd99eb4480c94
BLAKE2b-256 984896b2adb0b9c52cb6cc8e1eea29275b42e39b800b257fc5e24fc5a8f1d067

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp37-none-win_amd64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp37-none-win_amd64.whl
  • Upload date:
  • Size: 2.7 MB
  • Tags: CPython 3.7, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/28.8.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.5.4

File hashes

Hashes for rjieba-0.1.1-cp37-none-win_amd64.whl
Algorithm Hash digest
SHA256 2c3afda9ada4a82080efe9153635a073c60ee722d8c512baa73fc30d11ea1e8e
MD5 0bf35bf9a76936b0bdc106453fdb2159
BLAKE2b-256 940290cb30c55daca3bbd56188dd499253e954667b861fb31bc51bb3ce9c8162

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp37-cp37m-manylinux1_x86_64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp37-cp37m-manylinux1_x86_64.whl
  • Upload date:
  • Size: 3.6 MB
  • Tags: CPython 3.7m
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.8.5

File hashes

Hashes for rjieba-0.1.1-cp37-cp37m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 d33647abbc318d42db486cdc053dd3660b13b86fbaf241cf44d5345e8ee91808
MD5 f91bb03f36bd6b7961c906ecef65c7c4
BLAKE2b-256 bd87303457ccfe3cd7c3ac58f9c39f593e9098966317062f9c19a140e9ad05db

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp37-cp37m-macosx_10_7_x86_64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp37-cp37m-macosx_10_7_x86_64.whl
  • Upload date:
  • Size: 2.8 MB
  • Tags: CPython 3.7m, macOS 10.7+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.7.9

File hashes

Hashes for rjieba-0.1.1-cp37-cp37m-macosx_10_7_x86_64.whl
Algorithm Hash digest
SHA256 65c747518c0ccf790365539fc14fd4ada9b6fba1d5c2bd35894436931658fb9b
MD5 356a9db847d1ee980427817b82974955
BLAKE2b-256 f546c3b9d3e750954d3fa73046ea8e5bbe69453f12ebbe8cd10527f44764740f

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp36-none-win_amd64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp36-none-win_amd64.whl
  • Upload date:
  • Size: 2.7 MB
  • Tags: CPython 3.6, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/28.8.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.5.4

File hashes

Hashes for rjieba-0.1.1-cp36-none-win_amd64.whl
Algorithm Hash digest
SHA256 dbb05c20a5803c031e28670d1170f946cf3173819bde6eb7784f655a88fdb2ab
MD5 417b1b1c027850f2e96b65b862b0022c
BLAKE2b-256 851b29d18da9445f43e95e055ab4d98e31452eef8bc01b2a2a6efded7b4fdafc

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp36-cp36m-manylinux1_x86_64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp36-cp36m-manylinux1_x86_64.whl
  • Upload date:
  • Size: 3.6 MB
  • Tags: CPython 3.6m
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.8.5

File hashes

Hashes for rjieba-0.1.1-cp36-cp36m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 ac31458ef5fbde3ffd735124aec66228d8726d0a7400f14eca86161d2f5223da
MD5 af5679aa7bcf41624220a87d7c1d6362
BLAKE2b-256 27de30693a0428483eb958133af1cbed015cb4441251f8b50a02d9dac86c27cc

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp36-cp36m-macosx_10_7_x86_64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp36-cp36m-macosx_10_7_x86_64.whl
  • Upload date:
  • Size: 2.8 MB
  • Tags: CPython 3.6m, macOS 10.7+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/40.6.2 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.6.12

File hashes

Hashes for rjieba-0.1.1-cp36-cp36m-macosx_10_7_x86_64.whl
Algorithm Hash digest
SHA256 dfa68e62867dd7d86377ade744828a9df196d531a4700a4983d45ab71c78fab8
MD5 de9618f46bd52102a4a9afd0ff23a239
BLAKE2b-256 c78e26e0db1cffa355807c507a0ba9b2d58117d5a43d170b0c654124438bd75d

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp35-none-win_amd64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp35-none-win_amd64.whl
  • Upload date:
  • Size: 2.7 MB
  • Tags: CPython 3.5, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/28.8.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.5.4

File hashes

Hashes for rjieba-0.1.1-cp35-none-win_amd64.whl
Algorithm Hash digest
SHA256 3c683aa7ef68f7d4189987444ac6504f998b5b52393e0d00f6cd0a61c6b2e3ef
MD5 7315b4004cd3c8076235c48f5b8e56fa
BLAKE2b-256 72f769e132d51d535e86265a7661b3502cec2bf386b44d438fa5d1a8046df698

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp35-cp35m-manylinux1_x86_64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp35-cp35m-manylinux1_x86_64.whl
  • Upload date:
  • Size: 3.6 MB
  • Tags: CPython 3.5m
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.8.5

File hashes

Hashes for rjieba-0.1.1-cp35-cp35m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 59cc685b8db3a8b23c476e18e22592ee1b07cb329415bc633e34334e5479d973
MD5 af79d3c500d97e680b26fcefc04de930
BLAKE2b-256 aabf68854715e9c270059048968787d873b322daaa7a4a961309c402107b0618

See more details on using hashes here.

File details

Details for the file rjieba-0.1.1-cp35-cp35m-macosx_10_7_x86_64.whl.

File metadata

  • Download URL: rjieba-0.1.1-cp35-cp35m-macosx_10_7_x86_64.whl
  • Upload date:
  • Size: 2.8 MB
  • Tags: CPython 3.5m, macOS 10.7+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/28.8.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.5.9

File hashes

Hashes for rjieba-0.1.1-cp35-cp35m-macosx_10_7_x86_64.whl
Algorithm Hash digest
SHA256 edaccfa36f040a07b8c4ea4161ca01b303c0dba1156ba5781b1ddd1a567a468a
MD5 f68322734e5731d6230ca726fff1e47e
BLAKE2b-256 6835d8545a242dc983b94bd82637849802c0de274285c1dffb2bd1b37daf003d

See more details on using hashes here.

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