Repository navigation
Expand file tree
/
Copy pathpyproject.toml
More file actions
112 lines (99 loc) · 3.76 KB
/
Copy pathpyproject.toml
File metadata and controls
112 lines (99 loc) · 3.76 KB
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
[build-system]
requires = ["setuptools>=77.0"]
build-backend = "setuptools.build_meta"
[project]
name = "scan-reader"
version = "1.0.0"
description = "AI legal document recognition, Zero-Trust verification, and 1C/Excel registry orchestration"
readme = "README.md"
authors = [{ name = "ScanReader Contributors" }]
license = "MIT"
license-files = ["LICENSE", "LICENSE_RU.md"]
requires-python = ">=3.9"
dependencies = [
"pydantic>=2.6,<3.0",
"openai>=1.30",
"Pillow>=10.0",
"pymupdf>=1.24.3",
"python-docx>=1.1.0",
"docx2txt>=0.8",
"openpyxl>=3.1",
"python-dotenv>=1.0",
]
classifiers = [
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"Intended Audience :: Legal Industry",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Topic :: Office/Business :: Financial :: Accounting",
]
keywords = [
"vlm", "ocr", "document-analysis", "legal-tech", "zero-trust",
"fssp", "court-orders", "1c", "excel-registry", "mcp"
]
[project.urls]
Homepage = "https://github.com/Riper21/ScanReader"
Repository = "https://github.com/Riper21/ScanReader"
Changelog = "https://github.com/Riper21/ScanReader/blob/main/CHANGELOG.md"
Issues = "https://github.com/Riper21/ScanReader/issues"
[project.optional-dependencies]
# OCR для кросс-модальной верификации сканов. Без него проект работает, но
# гейт для изображений опирается только на VLM-транскрипцию (независимый канал).
ocr = ["rapidocr-onnxruntime>=1.3"]
# Полный вариант: PaddleOCR с поддержкой GPU и большим языковым покрытием.
ocr-full = ["paddleocr>=2.7", "paddlepaddle>=2.5"]
dev = [
"build>=1.0",
"mypy>=1.13",
"pytest>=8.0.0",
"pytest-cov>=4.1.0",
"ruff>=0.9",
]
[project.scripts]
scan-reader = "scan_reader.cli:main"
scanreader = "scan_reader.cli:main"
[tool.setuptools.packages.find]
where = ["src"]
[tool.setuptools.package-data]
"scan_reader" = ["doc_types/*/*.json", "doc_types/*/*.md", "doc_types/*/*.py"]
[tool.pytest.ini_options]
pythonpath = ["src"]
testpaths = ["tests"]
python_files = ["test_*.py"]
addopts = "-ra"
[tool.coverage.run]
branch = true
source = ["scan_reader"]
[tool.coverage.report]
# Фаза 9: порог поднят с 55 %, которые перестали быть защитой после того, как
# добавлены регрессионные тесты Фаз 1-8.
# P3.4: 70 -> 75. Реестр плагинов теперь регистрирует модули схем в
# sys.modules под пакетными именами — раньше coverage.py не видел их
# исполнения, и 9 файлов doc_types показывались как 0 %, занижая измерение
# (Правило 8). Честное фактическое покрытие после исправления — ~77 %.
fail_under = 75
show_missing = true
skip_covered = true
[tool.ruff]
line-length = 120
target-version = "py39"
[tool.ruff.lint]
select = ["E4", "E7", "E9", "F"]
[tool.ruff.lint.per-file-ignores]
# Примеры добавляют src/ в sys.path перед импортом scan_reader
"examples/*.py" = ["E402"]
[tool.mypy]
python_version = "3.9"
files = ["src"]
check_untyped_defs = true
no_implicit_optional = true
ignore_missing_imports = true
warn_redundant_casts = true