File size: 2,815 Bytes
547bc5b
 
7535e76
547bc5b
 
 
7535e76
547bc5b
 
 
 
 
 
 
 
 
 
 
 
 
 
 
7535e76
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2617189
547bc5b
a00fee9
 
 
547bc5b
 
 
a00fee9
547bc5b
 
2617189
547bc5b
 
 
 
 
 
 
7535e76
 
 
 
a00fee9
7535e76
 
 
 
 
 
 
 
 
 
 
 
 
2617189
7535e76
547bc5b
 
2617189
547bc5b
7535e76
 
 
 
2617189
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
[build-system]
requires = ["setuptools>=68.0"]
build-backend = "setuptools.build_meta"

[project]
name = "multilingual-absa"
version = "2.1.0"
description = "Multilingual Aspect-Based Sentiment Analysis for English, Hindi, and Hinglish"
readme = "README.md"
license = {text = "MIT"}
requires-python = ">=3.10"
keywords = ["absa", "sentiment-analysis", "nlp", "multilingual", "fastapi", "hindi"]
classifiers = [
    "Development Status :: 4 - Beta",
    "Intended Audience :: Developers",
    "Intended Audience :: Science/Research",
    "License :: OSI Approved :: MIT License",
    "Programming Language :: Python :: 3.10",
    "Programming Language :: Python :: 3.11",
    "Topic :: Scientific/Engineering :: Artificial Intelligence",
    "Topic :: Text Processing :: Linguistic",
]
dependencies = [
    # ML / NLP
    "transformers>=4.41.0",
    "datasets>=2.19.0",
    "torch>=2.3.0",
    "onnxruntime>=1.18.0",
    "optimum[onnxruntime]>=1.19.0",
    "peft>=0.10.0",
    "fasttext-predict>=0.9.2.4",
    "indic-nlp-library @ git+https://github.com/anoopkunchukuttan/indic_nlp_library.git",
    "nlpaug>=1.1.11",
    # Data & Metrics
    "scikit-learn>=1.4.2",
    "pandas>=2.2.3",
    "numpy>=1.26.4",
    "seqeval>=1.2.2",
    # Experiment tracking & pipelines
    "mlflow>=2.15.0",
    "dvc>=3.51.1",
    "evidently>=0.4.30",
    "python-multipart>=0.0.9",
    "slowapi>=0.1.9",
    "pydantic>=2.7.1",
    "python-dotenv>=1.0.1",
    "prometheus-fastapi-instrumentator>=7.0.0",
    "httpx>=0.28.0",
]

[project.optional-dependencies]
dev = [
    "pytest>=8.2.0",
    "pytest-asyncio>=0.23.7",
    "pytest-cov>=5.0.0",
    "coverage>=7.5.0",
    "ruff>=0.6.0",
    "mypy>=1.10.0",
    "bandit>=1.7.9",
    "radon>=6.0.1",
    "scalene>=1.5.30",
]

[tool.setuptools.packages.find]
where = ["src", "."]
include = ["absa*"]

[tool.setuptools.package-data]
absa = ["py.typed"]

[tool.pytest.ini_options]
testpaths = ["tests"]
python_files = ["test_*.py"]
pythonpath = [".", "src"]
asyncio_mode = "auto"
asyncio_default_fixture_loop_scope = "function"
addopts = "--cov=absa --cov-report=term-missing --cov-report=xml"

[tool.ruff]
target-version = "py310"
line-length = 120

[tool.ruff.lint]
select = ["E", "F", "I", "N", "W"]
extend-ignore = ["N999"]  # module file name style

[tool.mypy]
python_version = "3.10"
plugins = ["sqlalchemy.ext.mypy.plugin"]
warn_return_any = true
warn_unused_configs = true
ignore_missing_imports = true
check_untyped_defs = true
exclude = [
    "tests/",
    "scripts/",
    "notebooks/",
    "docs/",
]

[tool.bandit]
exclude_dirs = ["tests", "scripts"]
targets = ["absa"]
skips = ["B101"]  # allow assert (pytest usage)

[tool.coverage.run]
source = ["absa"]
omit = ["*/tests/*", "*/__pycache__/*"]

[tool.coverage.report]
show_missing = true
skip_covered = true
fail_under = 18