Skip to main content

ZiCutter

ZiCutter: cut character smaller

use

pip install ZiCutter

from ZiCutter import ZiCutter

line = "'〇㎡[คุณจะจัดพิธีแต่งงานเมื่อไรคะัีิ์ื็ํึ]Ⅷpays-g[ran]d-blanc-élevé » (白高大夏國)😀熇'"

# build
cutter = ZiCutter(dir="")
cutter.build()

# use
cutter = ZiCutter(dir="")
for c in line:
    print(cutter.cutChar(c))

background

Unicode 14.0 adds 838 characters, for a total of 144,697 characters. (https://www.unicode.org/versions/Unicode14.0.0/) About 2/3 of them are HanZi. To shrink vocab size, we cut character to smaller.

vocab

minium az 26 number 10 Gram 36 YuanZi 2366 total 2402

cut name rare character

name = name of 'x'
tokens=[name[:2],"#"+name[-1]]
base: Grams, [az][az],[09][09],#[az],#[09]

'😀' : name is 'GRINNING FACE'
'😀' -> ["##gr","ce"]

cut ids for HanZi

base: YuanZi (minium)

熇	⿰火高    
'熇' -> ['⿰','火','高']    

Metadata

Release files for ZiCutter 0.0.10

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ZiCutter 0.0.10
File Size Uploaded Provenance Actions
ZiCutter-0.0.10.tar.gz 1.4 MB Without provenance Details for ZiCutter-0.0.10.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for ZiCutter 0.0.10
File Interpreter ABI Platform Actions
ZiCutter-0.0.10-py3-none-any.whl Python 3 none any Details for ZiCutter-0.0.10-py3-none-any.whl

Total release size: 2.8 MB

Release files / ZiCutter-0.0.10.tar.gz

Download URL ZiCutter-0.0.10.tar.gz
Size 1.4 MB
Tags Source
SHA-256 checksum
How to use checksums
d4d03609d8083a7fd8a57858660089e8786f1764ca4ec024c2ec236349596c9b
BLAKE2b-256 checksum
How to use checksums
ca5716025be5e484da835c1f77cce7cb88f47b6d2e6c79645d6a7d0cf359cf9e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.8

Release files / ZiCutter-0.0.10-py3-none-any.whl

Download URL ZiCutter-0.0.10-py3-none-any.whl
Size 1.4 MB
Tags Python 3
SHA-256 checksum
How to use checksums
8ee06158216385ca5eed2601c8edb38e76b60c4b0b3a5fbeca95d785500339fc
BLAKE2b-256 checksum
How to use checksums
cfdadecdafaa11e25e349dfc2a53caa45f67192a2ed09149bc786c6338a63e80
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.8

Security for ZiCutter 0.0.10

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page