# marhta
[![License](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)
Fast string similarity algorithms
*This library is still in development and may not be stable.*
## Installation
```bash
pip install marhta
```
## Usage
```python
from marhta import levenshtein_similarity, jaro_winkler_similarity
# Calculate string similarities
print(levenshtein_similarity("hello", "helo")) # 0.8
print(jaro_winkler_similarity("martha", "marhta")) # 0.961
# Find best matches
from marhta import levenshtein_match
strings = ["apple", "banana", "orange", "pear"]
matches = levenshtein_match("aple", strings)
print(matches) # [("apple", 0.8), ("pear", 0.5)]
```
## Features
- Levenshtein distance and similarity measures
- Jaro-Winkler distance and similarity measures
- Fuzzy string matching with customizable thresholds
## Performance
Written in Rust for improved performance, while maintaining a Pythonic API.
Raw data
{
"_id": null,
"home_page": null,
"name": "marhta",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": null,
"keywords": "string, similarity, levenshtein, jaro-winkler, fuzzy",
"author": null,
"author_email": null,
"download_url": null,
"platform": null,
"description": "# marhta\n[![License](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)\n\nFast string similarity algorithms\n\n*This library is still in development and may not be stable.*\n\n## Installation\n\n```bash\npip install marhta\n```\n\n## Usage\n\n```python\nfrom marhta import levenshtein_similarity, jaro_winkler_similarity\n\n# Calculate string similarities\nprint(levenshtein_similarity(\"hello\", \"helo\")) # 0.8\nprint(jaro_winkler_similarity(\"martha\", \"marhta\")) # 0.961\n\n# Find best matches\nfrom marhta import levenshtein_match\nstrings = [\"apple\", \"banana\", \"orange\", \"pear\"]\nmatches = levenshtein_match(\"aple\", strings)\nprint(matches) # [(\"apple\", 0.8), (\"pear\", 0.5)]\n```\n\n## Features\n\n- Levenshtein distance and similarity measures\n- Jaro-Winkler distance and similarity measures\n- Fuzzy string matching with customizable thresholds\n\n## Performance\n\nWritten in Rust for improved performance, while maintaining a Pythonic API.\n\n",
"bugtrack_url": null,
"license": null,
"summary": "Fast string similarity algorithms in Rust",
"version": "0.1.1",
"project_urls": {
"Repository": "https://github.com/pjwerneck/marhta"
},
"split_keywords": [
"string",
" similarity",
" levenshtein",
" jaro-winkler",
" fuzzy"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "06f55914c067bc4893ebdae2efa373c4226968e173aade96ca746f1af358cdcb",
"md5": "f19a2ab47eb1a741425f265eeeb3fbbf",
"sha256": "03375dc301db33b0673567670b9fadc40f9354cbaf81f892db251b89cfe66123"
},
"downloads": -1,
"filename": "marhta-0.1.1-cp310-cp310-manylinux_2_34_x86_64.whl",
"has_sig": false,
"md5_digest": "f19a2ab47eb1a741425f265eeeb3fbbf",
"packagetype": "bdist_wheel",
"python_version": "cp310",
"requires_python": ">=3.8",
"size": 2252494,
"upload_time": "2025-01-31T23:01:54",
"upload_time_iso_8601": "2025-01-31T23:01:54.125371Z",
"url": "https://files.pythonhosted.org/packages/06/f5/5914c067bc4893ebdae2efa373c4226968e173aade96ca746f1af358cdcb/marhta-0.1.1-cp310-cp310-manylinux_2_34_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "102a16a447f5663867d8013cd87dcf2a84f0d1e4fd6194e1f934f7b90420f196",
"md5": "aa8c724bd106edf09680caf35c4910eb",
"sha256": "bb2d1c521d018c5b1fa0c0b066b63e481474138f4e555d7bd37a9b003405b24c"
},
"downloads": -1,
"filename": "marhta-0.1.1-cp311-cp311-manylinux_2_34_x86_64.whl",
"has_sig": false,
"md5_digest": "aa8c724bd106edf09680caf35c4910eb",
"packagetype": "bdist_wheel",
"python_version": "cp311",
"requires_python": ">=3.8",
"size": 2247903,
"upload_time": "2025-01-31T23:01:56",
"upload_time_iso_8601": "2025-01-31T23:01:56.604633Z",
"url": "https://files.pythonhosted.org/packages/10/2a/16a447f5663867d8013cd87dcf2a84f0d1e4fd6194e1f934f7b90420f196/marhta-0.1.1-cp311-cp311-manylinux_2_34_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "9cd65ba4e5870078fb3a0322a7b996a3eef603cf26f59a9fdf137c2543321892",
"md5": "12b64e5f9405dad8d960ef92e839b33c",
"sha256": "9673929705adc1433d03c36f353fff9402e6f0c382bd46816fcc0a5f87121d48"
},
"downloads": -1,
"filename": "marhta-0.1.1-cp312-cp312-manylinux_2_34_x86_64.whl",
"has_sig": false,
"md5_digest": "12b64e5f9405dad8d960ef92e839b33c",
"packagetype": "bdist_wheel",
"python_version": "cp312",
"requires_python": ">=3.8",
"size": 2242310,
"upload_time": "2025-01-31T23:01:59",
"upload_time_iso_8601": "2025-01-31T23:01:59.640672Z",
"url": "https://files.pythonhosted.org/packages/9c/d6/5ba4e5870078fb3a0322a7b996a3eef603cf26f59a9fdf137c2543321892/marhta-0.1.1-cp312-cp312-manylinux_2_34_x86_64.whl",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-01-31 23:01:54",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "pjwerneck",
"github_project": "marhta",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "marhta"
}