Skip to content

Commit 8e8d9c9

Browse files
committed
build: trim unused release dependencies
1 parent 249a0e5 commit 8e8d9c9

3 files changed

Lines changed: 9 additions & 214 deletions

File tree

pyproject.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ dependencies = [
1919
"numpy>=2.4.3",
2020
"openai>=2.29.0",
2121
"openpyxl>=3.1.5",
22-
"pandas>=3.0.1",
2322
"prompt-toolkit>=3.0.52",
2423
"pydantic>=2.12.5",
2524
"pydantic-settings>=2.13.1",
@@ -28,7 +27,6 @@ dependencies = [
2827
"rank-bm25>=0.2.2",
2928
"requests>=2.32.5",
3029
"rich>=14.3.3",
31-
"scikit-learn>=1.8.0",
3230
"tenacity>=9.1.4",
3331
"tiktoken>=0.12.0",
3432
"volcengine-python-sdk[ark]>=5.0.18",

scripts/build_binary_release.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,13 @@
3939
"src.providers.jina",
4040
"src.providers.siliconflow_rerank",
4141
]
42+
EXCLUDED_MODULES = [
43+
"pandas",
44+
"scipy",
45+
"sklearn",
46+
"pytest",
47+
"_pytest",
48+
]
4249

4350

4451
def load_version() -> str:
@@ -93,6 +100,8 @@ def run_pyinstaller() -> None:
93100
]
94101
for hidden_import in HIDDEN_IMPORTS:
95102
command.extend(["--hidden-import", hidden_import])
103+
for excluded_module in EXCLUDED_MODULES:
104+
command.extend(["--exclude-module", excluded_module])
96105
command.append("main.py")
97106
subprocess.run(command, cwd=PROJECT_ROOT, check=True)
98107

0 commit comments

Comments
 (0)