-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
136 lines (127 loc) · 4.08 KB
/
Copy pathpyproject.toml
File metadata and controls
136 lines (127 loc) · 4.08 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
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
[project]
name = "warp-ingest"
# The version is derived from the latest git tag (v2.0.1 -> 2.0.1) by
# hatch-vcs, so cutting a release only requires pushing a tag -- there is no
# version string in the repo to bump (see [tool.hatch.version]).
dynamic = ["version"]
description = "Pure-Python, RAG-friendly document parsers (PDF/HTML/text/XML/Markdown). Java- and Tika-free."
readme = "README.md"
requires-python = ">=3.10,<3.15"
license = "Apache-2.0"
license-files = ["LICENSE.txt", "NOTICE.txt"]
authors = [
{ name = "Ambika Sukla", email = "ambika.sukla@nlmatics.com" },
{ name = "Jonathan", email = "jonathan.hilgart@gmail.com" },
{ name = "John Scrudato", email = "scrudato@umich.edu" },
]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"Intended Audience :: Legal Industry",
"Intended Audience :: Science/Research",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
]
dependencies = [
"beautifulsoup4>=4.12.0,<5.0.0",
"nltk>=3.9.1",
"numpy>=1.24,<3",
"pdfplumber>=0.11.4,<0.12.0",
"pypdfium2>=5",
]
[project.optional-dependencies]
# Parser dependencies live in the base install. This no-op extra exists so
# `pip install warp-ingest[parser]` is an explicit parser-only spelling.
parser = []
service = [
"fastapi>=0.115,<1.0",
"python-multipart>=0.0.9",
"uvicorn>=0.30,<1.0",
]
# opencv is rapidocr's image-ops backend (resize/normalize/perspective-crop
# around the ONNX models); the headless build has the identical cv2 API without
# linking GUI libs (libGL), which a server image doesn't have. rapidocr's own
# metadata pins the full `opencv-python`, so [tool.uv] override-dependencies
# below strips that pin and this extra supplies headless instead.
ocr = [
"onnxruntime>=1.17.0,<1.23; python_version == '3.10'",
"onnxruntime>=1.27.0; python_version >= '3.11' and python_version < '3.15'",
"opencv-python-headless>=4.13.0.92",
"pyclipper>=1.4.0",
"pyyaml>=6.0.3",
"rapidocr-onnxruntime>=1.3.0,<2.0.0",
"shapely>=2.1.2",
"six>=1.17.0",
]
# Full runtime install for the hosted ingestion service.
all = [
"fastapi>=0.115,<1.0",
"onnxruntime>=1.17.0,<1.23; python_version == '3.10'",
"onnxruntime>=1.27.0; python_version >= '3.11' and python_version < '3.15'",
"opencv-python-headless>=4.13.0.92",
"pyclipper>=1.4.0",
"python-multipart>=0.0.9",
"pyyaml>=6.0.3",
"rapidocr-onnxruntime>=1.3.0,<2.0.0",
"shapely>=2.1.2",
"six>=1.17.0",
"uvicorn>=0.30,<1.0",
]
[project.urls]
Repository = "https://github.com/Open-Source-Legal/Warp-Ingest"
Issues = "https://github.com/Open-Source-Legal/Warp-Ingest/issues"
[dependency-groups]
dev = [
"black>=26.3.1",
"fastapi>=0.115,<1.0",
"httpx>=0.27",
"isort>=5.13.2",
"pytest>=9.0.3",
"python-multipart>=0.0.9",
"reportlab>=4.0",
"uvicorn>=0.30,<1.0",
]
[build-system]
requires = ["hatchling", "hatch-vcs"]
build-backend = "hatchling.build"
[tool.hatch.version]
source = "vcs"
[tool.hatch.build.targets.wheel]
packages = ["warp_ingest"]
# Keep the sdist to the package itself (plus auto-included metadata files);
# tests/fixtures alone is ~90MB and has no place on PyPI.
[tool.hatch.build.targets.sdist]
include = ["warp_ingest"]
[tool.uv]
# Strip rapidocr-onnxruntime's `opencv-python` pin (never-true marker): the
# ocr extra supplies `opencv-python-headless` instead — same cv2 API, no libGL.
override-dependencies = ["opencv-python; sys_platform == 'never'"]
[tool.black]
target-version = ['py310']
include = '\.pyi?$'
extend-exclude = '''
/(
# directories
\.eggs
| \.git
| \.hg
| \.mypy_cache
| \.tox
| \.venv
| build
| dist
)/
'''
[tool.isort]
profile = "black"
line_length = 88
multi_line_output = 3
include_trailing_comma = true
force_grid_wrap = 0
use_parentheses = true
ensure_newline_before_comments = true