microsoft/hve-core

Public

mirrored from https://github.com/microsoft/hve-coreAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
feat/1637-l4-tests

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

scripts/evals/moderation/pyproject.toml

49lines · modecode

1[project]
2name = "hve-core-moderation"
3version = "1.0.0"
4description = "Content moderation tooling for eval input/output screening"
5requires-python = ">=3.11"
6dependencies = [
7 "detoxify==0.5.2",
8 "torch==2.12.0",
9 "transformers>=4.40,<5",
10]
11
12# Resolve torch from the CPU-only wheel index. This eval is a CPU-bound
13# Detoxify toxicity classifier with no GPU code path, so the default PyPI
14# torch wheel's nvidia-*-cu12 CUDA runtime dependencies are unnecessary.
15[[tool.uv.index]]
16name = "pytorch-cpu"
17url = "https://download.pytorch.org/whl/cpu"
18explicit = true
19
20[tool.uv.sources]
21torch = { index = "pytorch-cpu" }
22
23[tool.ruff]
24line-length = 120
25target-version = "py311"
26
27[tool.ruff.lint]
28select = ["E", "F", "I", "W"]
29ignore = []
30
31[tool.pytest.ini_options]
32testpaths = ["tests"]
33python_files = ["test_*.py", "fuzz_harness.py"]
34addopts = [
35 "-v",
36 "--strict-markers",
37 "--tb=short",
38]
39
40[dependency-groups]
41dev = [
42 "pytest>=8.0",
43 "pytest-cov>=7.0",
44 "pytest-mock>=3.14",
45 "ruff>=0.6",
46]
47fuzz = [
48 "atheris>=3.0",
49]
50