dots-ocr-idcard / pyproject.toml
tommulder's picture
fix(hf): add hf_transfer for HF_HUB_ENABLE_HF_TRANSFER; remove deprecated symlink arg; add root / route
399c4d1
[project]
name = "kybtech-dots-ocr"
version = "1.0.0"
description = "Dots.OCR model integration for KYB text extraction"
authors = [
{name = "Algoryn", email = "info@algoryn.com"}
]
readme = "README.md"
requires-python = ">=3.9"
dependencies = [
"fastapi>=0.112.1",
"uvicorn[standard]>=0.30.6",
"python-multipart>=0.0.9",
"pydantic>=2.2.0,<3.0.0",
"opencv-python>=4.9.0.80",
"numpy>=1.26.0",
"pillow>=10.3.0",
"huggingface_hub",
"PyMuPDF>=1.23.0",
"torch>=2.0.0",
"transformers>=4.40.0",
"accelerate>=0.20.0",
"qwen-vl-utils",
"requests>=2.31.0",
"httpx>=0.27.0",
"hf_transfer>=0.1.6",
]
[project.optional-dependencies]
dev = [
"pytest>=7.0.0",
"pytest-asyncio>=0.21.0",
"black>=23.0.0",
"ruff>=0.1.0",
"mypy>=1.0.0",
]
[project.scripts]
kyb-ocr = "main:main"
[build-system]
requires = ["setuptools>=68", "wheel"]
build-backend = "setuptools.build_meta"
[tool.setuptools]
package-dir = {"" = "src"}
[tool.setuptools.packages.find]
where = ["src"]
[tool.black]
line-length = 88
target-version = ['py39']
[tool.ruff]
line-length = 88
target-version = "py39"
select = ["E", "F", "W", "C90", "I", "N", "UP", "YTT", "S", "BLE", "FBT", "B", "A", "COM", "C4", "DTZ", "T10", "EM", "EXE", "FA", "ISC", "ICN", "G", "INP", "PIE", "T20", "PYI", "PT", "Q", "RSE", "RET", "SLF", "SLOT", "SIM", "TID", "TCH", "INT", "ARG", "PTH", "TD", "FIX", "ERA", "PD", "PGH", "PL", "TRY", "FLY", "NPY", "AIR", "PERF", "FURB", "LOG", "RUF"]
ignore = ["S101", "PLR0913", "PLR0912", "PLR0915"]
[tool.ruff.per-file-ignores]
"__init__.py" = ["F401"]
[tool.mypy]
python_version = "3.9"
warn_return_any = true
warn_unused_configs = true
disallow_untyped_defs = true
disallow_incomplete_defs = true
check_untyped_defs = true
disallow_untyped_decorators = true
no_implicit_optional = true
warn_redundant_casts = true
warn_unused_ignores = true
warn_no_return = true
warn_unreachable = true
strict_equality = true
[tool.pytest.ini_options]
testpaths = ["tests"]
python_files = ["test_*.py"]
python_classes = ["Test*"]
python_functions = ["test_*"]
addopts = "-v --tb=short"