Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ on:
pull_request:
push:
branches:
- master
- '*'

jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
python-version: [3.7, 3.8, 3.9]
python-version: [3.10, 3.11, 3.12]
os: [ubuntu-latest, windows-latest]

steps:
Expand Down
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
env/
env*/
__pycache__/
*.pyc
*.egg-info
File renamed without changes.
82 changes: 82 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

[project]
name = "string-grouper"
dynamic = ["version"]
description = "String grouper contains functions to do string matching using TF-IDF and the cossine similarity. Based on https://bergvca.github.io/2017/10/14/super-fast-string-matching.html"
readme = "README.md"
requires-python = ">3.10"
authors = [
{ name = "Chris van den Berg", email = "fake_email@gmail.com" },
{ name = "Ruben Menke", email = "rum@bankingcircle.com" },
]
classifiers = [
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
]
dependencies = [
"numpy",
"pandas>=0.25.3",
"scikit-learn",
"scipy",
"sparse_dot_topn>=1.1.1",
]

[project.urls]
Homepage = "https://github.com/Bergvca/string_grouper"
Documentation = "https://github.com/unknown/string-grouper#readme"
Issues = "https://github.com/unknown/string-grouper/issues"
Source = "https://github.com/unknown/string-grouper"

[tool.hatch.version]
path = "string_grouper/__init__.py"

[tool.hatch.build.targets.sdist]
include = [
"/string_grouper",
]


[tool.hatch.envs.test]
dependencies = ["pytest", "pdbpp"]

[tool.hatch.envs.test.scripts]
tests = "python -m unittest {args}"
base = "pytest {args}"
cov = "pytest --cov-report=term-missing --cov-config=pyproject.toml --cov=diss --cov=api --cov=llm {args}"
htmlcov = "pytest --cov-report=html --cov-config=pyproject.toml --cov=diss --cov=api --cov=llm {args}"
xmlcov = "pytest --cov-report=xml --cov-config=pyproject.toml --cov=diss --cov=api --cov=llm {args}"
code_check = "pre-commit run --all-files"

[[tool.hatch.envs.test.matrix]]
python = ["3.10", "3.11"]



[tool.black]
line-length = 120
include = '\.pyi?$'
exclude = '''
/(
\.git
| \.hg
| \.mypy_cache
| \.tox
| \.venv
| _build
| buck-out
| build
)/
'''

[tool.isort]
profile = "black"
30 changes: 0 additions & 30 deletions setup.py

This file was deleted.

11 changes: 9 additions & 2 deletions string_grouper/__init__.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,9 @@
from .string_grouper import compute_pairwise_similarities, group_similar_strings, match_most_similar, match_strings, \
StringGrouperConfig, StringGrouper
from .string_grouper import (
compute_pairwise_similarities,
group_similar_strings,
match_most_similar,
match_strings,
StringGrouperConfig,
StringGrouper,
)
__version__ = "0.5.0"
Loading