Skip to main content

[![Version][version-badge]][version-link] ![MIT License][license-badge]

compute similar scores of two strings

TextSimilarScore这是个计算两个短文本相似度的算法

安装方法

安装以来 pip install TextSimilarScore

pip install -r resuirements.txt

使用方法

import TextSimilarScore.tools.TextSim as ts
test = ts.TextSimilarity()
# 计算连续最长公共子串的距离
print(test.lcs('中移在线全链路智能化系统研发项目', '中移在线全国智能路由决策项目'))
# 计算连续最长公共子序列的距离
print(test.lcs_sequence('中移在线全链路智能化系统研发项目', '中移在线全国智能路由决策项目'))
# 计算编辑距离
print(test.minimumEditDistance('中移在线全链路智能化系统研发项目', '中移在线全国智能路由决策项目'))
# 基于tf-idf计算距离
print(test.splitWordSimlaryty('中移在线全链路智能化系统研发项目', '中移在线全国智能路由决策项目'))
# 计算JaccardSim系数
print(test.JaccardSim('中移在线全链路智能化系统研发项目', '中移在线全国智能路由决策项目'))

Metadata

Release files for TextSimilarScore 0.0.6

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

Source distribution (sdist)

Source distribution for TextSimilarScore 0.0.6
File Size Uploaded Provenance Actions
TextSimilarScore-0.0.6.tar.gz 4.6 kB Without provenance Details for TextSimilarScore-0.0.6.tar.gz

Built distribution (wheel)

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

Total release size: 10.9 kB

Release files / TextSimilarScore-0.0.6.tar.gz

Download URL TextSimilarScore-0.0.6.tar.gz
Size 4.6 kB
Tags Source
SHA-256 checksum
How to use checksums
cf050c9651d16596aa94099bf96ddcb7bc6ef6ec4244f09da4c5b95817ac7bef
BLAKE2b-256 checksum
How to use checksums
11336c190677d60b876e7bb1dfdada74643952605bc4794d31c2d34a7b4ae031
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.14.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/39.1.0 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.6.8

Release files / TextSimilarScore-0.0.6-py3-none-any.whl

Download URL TextSimilarScore-0.0.6-py3-none-any.whl
Size 6.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
89987a7d7d5f250cf52e83f5f51fc88b03df623d1343c21cc2f8bbb81181bcbc
BLAKE2b-256 checksum
How to use checksums
47e6d5e7d4217847b681c06a492db57e0bd215f1fc3fd7f48eeeec804c1da3ea
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.14.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/39.1.0 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.6.8

Security for TextSimilarScore 0.0.6

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