forked from LearningCircuit/local-deep-research
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
282 lines (246 loc) · 6.98 KB
/
pyproject.toml
File metadata and controls
282 lines (246 loc) · 6.98 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
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
[build-system]
requires = ["pdm-backend>=2.4.3"]
build-backend = "pdm.backend"
[project]
name = "local-deep-research"
dynamic = ["version"]
description = "AI-powered research assistant with deep, iterative analysis using LLMs and web searches"
readme = "README.md"
requires-python = ">=3.11,<3.15"
license = {file = "LICENSE"}
authors = [
{name = "LearningCircuit", email = "185559241+LearningCircuit@users.noreply.github.com"},
{name = "HashedViking", email = "6432677+HashedViking@users.noreply.github.com"},
{name = "djpetti", email = "djpetti@gmail.com"},
]
classifiers = [
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
]
dependencies = [
"langchain~=1.2",
"langchain-community~=0.4",
"langchain-core~=1.2",
"langchain-ollama~=1.0",
"langchain-openai~=1.1",
"langchain-anthropic~=1.3",
"duckduckgo-search~=8.1",
"python-dateutil~=2.9",
"typing-extensions~=4.15",
"justext~=3.0",
"playwright~=1.57",
"beautifulsoup4~=4.14",
"flask~=3.1",
"werkzeug>=3.1.5", # CVE-2026-21860 fix
"flask-cors~=6.0",
"flask-socketio~=5.6",
"sqlalchemy~=2.0",
"sqlalchemy-utc~=0.14",
"wikipedia~=1.4",
"arxiv~=2.3",
"pypdf>=6.6.2", # CVE fix for GHSA-4f6g-68pf-7vhv, GHSA-4xc4-762w-m6cg, CVE-2026-24688
"sentence-transformers~=5.2",
"faiss-cpu~=1.13",
"pydantic~=2.12",
"pydantic-settings~=2.12",
"toml~=0.10",
"platformdirs~=4.5",
"dynaconf~=3.2",
"requests~=2.32",
"urllib3>=2.6.3", # CVE-2026-21441 fix
"tiktoken~=0.12",
"xmltodict~=1.0",
"lxml~=6.0",
"defusedxml~=0.7", # XXE-safe XML parsing
"nh3~=0.3", # Backend HTML sanitization
"pdfplumber~=0.11",
"unstructured~=0.18",
"google-search-results~=2.4",
"importlib-resources~=6.5",
"setuptools~=80.10",
"jaraco-context>=6.1.0", # CVE GHSA-58pv-8j8x-9vj2 fix for path traversal
"flask-wtf~=1.2",
"optuna~=4.6",
"elasticsearch~=9.2",
"methodtools~=0.4",
"loguru~=0.7",
"cachetools~=6.2",
"matplotlib~=3.10",
"pandas~=2.3",
"plotly~=6.5",
"kaleido~=1.2",
"aiohttp~=3.13",
"tenacity~=9.1",
"apscheduler~=3.11",
"rich~=14.2",
"click~=8.3",
"flask-login~=0.6",
"flask-limiter~=4.1",
"sqlcipher3-binary>=0.5,<0.6; sys_platform == \"linux\" and platform_machine == \"x86_64\"",
"sqlcipher3>=0.5,<0.6; (platform_machine == \"aarch64\" or platform_machine == \"arm64\") and sys_platform == \"linux\"",
"sqlcipher3>=0.5,<0.6; sys_platform != \"linux\"",
"lxml-html-clean~=0.4",
"weasyprint~=68.0",
"jaraco-context>=6.1.0", # Transitive dep - pinned for GHSA-58pv-8j8x-9vj2
"apprise~=1.9",
"markdown~=3.10",
"datasets~=4.4",
"pyarrow~=22.0",
"langchain-experimental~=0.4",
]
[project.optional-dependencies]
vllm = [
"torch>=2.0.0",
"transformers>=4.30.0",
"vllm>=0.4.0",
]
[project.urls]
"Homepage" = "https://github.com/LearningCircuit/local-deep-research"
"Bug Tracker" = "https://github.com/LearningCircuit/local-deep-research/issues"
[project.scripts]
ldr = "local_deep_research.main:main"
ldr-web = "local_deep_research.web.app:main"
[tool.setuptools]
include-package-data = true
[tool.setuptools.package-data]
"local_deep_research.web" = ["templates/*", "static/*", "static/**/*"]
"local_deep_research.defaults" = ["*.toml", "*.py", "*.template", ".env.template"]
"local_deep_research.notifications" = ["templates/*.jinja2"]
[tool.pdm]
distribution = true
version = { source = "file", path = "src/local_deep_research/__version__.py" }
[[tool.pdm.source]]
url = "https://download.pytorch.org/whl/cpu"
name = "torch"
include_packages = ["torch", "torch*"]
[dependency-groups]
dev = [
"virtualenv>=20.36.1", # CVE-2026-22702 fix (GHSA-597g-3phw-6986)
"pre-commit~=4.5",
"cookiecutter~=2.6",
"pandas~=2.3",
"optuna~=4.6",
"pytest-mock~=3.15",
"pytest~=9.0",
"pytest-cov~=7.0",
"pytest-timeout~=2.4",
"pytest-asyncio~=1.3",
"pytest-xdist~=3.8",
"ruff~=0.14",
"freezegun~=1.5",
"mypy~=1.19",
"types-requests~=2.32",
"types-setuptools~=80.9",
"types-toml~=0.10",
"hypothesis~=6.148",
]
[tool.pytest.ini_options]
markers = [
"requires_llm: marks tests that require a real LLM (not fallback)",
"integration: marks integration tests",
"slow: marks slow tests",
"asyncio: marks async tests that use asyncio",
]
# Global timeout for all tests - fail fast instead of hanging
timeout = 60
timeout_method = "signal"
[tool.coverage.run]
source = ["src"]
branch = true
omit = [
"*/tests/*",
"*/__pycache__/*",
"*/migrations/*",
# Experimental strategies (will be cleaned up)
"*/strategies/*",
# CLI entry points (hard to unit test)
"*/cli.py",
"*/cli/*",
# Visualization code
"*/visualization.py",
# Experimental browsecomp decoding
"*/answer_decoding/*",
]
[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"if TYPE_CHECKING:",
"raise NotImplementedError",
]
fail_under = 0
show_missing = true
[tool.coverage.html]
directory = "coverage/htmlcov"
[tool.ruff]
# Exclude a variety of commonly ignored directories.
exclude = [
".bzr",
".direnv",
".eggs",
".git",
".git-rewrite",
".hg",
".ipynb_checkpoints",
".mypy_cache",
".nox",
".pants.d",
".pyenv",
".pytest_cache",
".pytype",
".ruff_cache",
".svn",
".tox",
".venv",
".vscode",
"__pypackages__",
"_build",
"buck-out",
"build",
"dist",
"node_modules",
"site-packages",
"venv",
]
# Same as Black.
line-length = 80
indent-width = 4
[tool.ruff.lint]
# Enable Pyflakes (`F`) and a subset of the pycodestyle (`E`) codes by default.
select = ["E4", "E7", "E9", "F"]
ignore = ["E722"]
# Allow fix for all enabled rules (when `--fix`) is provided.
fixable = ["ALL"]
unfixable = []
# Allow unused variables when underscore-prefixed.
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
[tool.ruff.format]
# Like Black, use double quotes for strings.
quote-style = "double"
# Like Black, indent with spaces, rather than tabs.
indent-style = "space"
# Like Black, respect magic trailing commas.
skip-magic-trailing-comma = false
# Like Black, automatically detect the appropriate line ending.
line-ending = "auto"
[tool.mypy]
python_version = "3.11"
warn_return_any = true
warn_unused_configs = true
disallow_untyped_defs = false
check_untyped_defs = true
warn_redundant_casts = true
warn_unused_ignores = true
no_implicit_optional = true
strict_equality = true
show_error_codes = true
# Start permissive - allow missing imports for third-party packages without stubs
ignore_missing_imports = true
# Gradually enable strict checking for specific modules
[[tool.mypy.overrides]]
module = "tests.*"
ignore_errors = true
# Enable stricter checking for new/critical code as type hints are added
# [[tool.mypy.overrides]]
# module = "local_deep_research.new_module.*"
# disallow_untyped_defs = true