Skip to main content

Jieba in economy

Project description

zuele

零配置、开箱即用的中文经济文本分词库。
内置 1125 份年报提炼词典,支持带词性输出。 目前正在优化词典

测试

```python
import os

import fitz

from zuele import Tokenizer

tok = Tokenizer()



# 定义提取PDF文本的函数
def extract_text_from_pdf(pdf_path):
doc = fitz.open(pdf_path)
text = ""
for page_num in range(len(doc)):
    page = doc.load_page(page_num)
    text += page.get_text()
return text


# 主程序
if __name__ == "__main__":
    pdf_dir = "pdf"  # 存储PDF文件的目录
    for filename in os.listdir(pdf_dir):
        pdf_path = os.path.join(pdf_dir, filename)
        text = extract_text_from_pdf(pdf_path)
        print(list(tok.cut(text)))

项目根目录执行: pip install --upgrade pip

python -m build

twine check dist/* twine upload dist/*

1. 改完 README 后,顺手改 setup.py / pyproject.toml 里的 version

2. 清理旧构建产物

rm -rf build/ dist/ *.egg-info

3. 重新打包

python -m build

4. 上传

twine upload dist/*

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

zuele-0.1.0.tar.gz (1.4 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

zuele-0.1.0-py3-none-any.whl (1.4 MB view details)

Uploaded Python 3

File details

Details for the file zuele-0.1.0.tar.gz.

File metadata

  • Download URL: zuele-0.1.0.tar.gz
  • Upload date:
  • Size: 1.4 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.23

File hashes

Hashes for zuele-0.1.0.tar.gz
Algorithm Hash digest
SHA256 22b0e0f59e0539674bc026d99e38c5d605208f3b52f6a0cf18ad18f319b5ace6
MD5 57357e4b6904382ae55ba0de3e63cfbf
BLAKE2b-256 e2dc55a06bced117e765be79f1ae17fac04d3b62351236cdb8f806ad6ae0c10c

See more details on using hashes here.

File details

Details for the file zuele-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: zuele-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 1.4 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.23

File hashes

Hashes for zuele-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7b634db99746c7993d8ecf36bbbab2cbaed3ef568fb20f48d07e6431d4258f59
MD5 9e01faa00f0fae48d564c1ace6cbb170
BLAKE2b-256 4f8eed6fef274b68462b21bbe0d41c1ba6cf435e2707c52f7b0e664b59638f3d

See more details on using hashes here.

Supported by

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