-
Notifications
You must be signed in to change notification settings - Fork 81
Expand file tree
/
Copy pathpyproject.toml
More file actions
97 lines (87 loc) · 2.42 KB
/
Copy pathpyproject.toml
File metadata and controls
97 lines (87 loc) · 2.42 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
[project]
name = "islamic-qa-evaluator"
version = "0.1.0"
description = "LLM-as-judge evaluation framework for Islamic Q&A responses"
requires-python = ">=3.10"
dependencies = [
"litellm>=1.40.0",
"openai>=1.30.0",
"anthropic>=0.25.0",
"pydantic>=2.6.0",
"pandas>=2.2.0",
"numpy>=1.26.0",
"pyyaml>=6.0.1",
]
[tool.ruff]
line-length = 120
target-version = "py311"
exclude = [
"venv",
".venv",
"data",
]
[tool.ruff.lint]
select = [
"E", # pycodestyle errors
"F", # pyflakes
"I", # isort (import sorting)
"UP", # pyupgrade (modernization)
"B", # flake8-bugbear
"W", # pycodestyle warnings
]
ignore = [
"B008", # FastAPI dependency defaults are function calls by design
"E501", # line length is enforced by the formatter, not the linter
"UP042", # StrEnum requires Python 3.11+, project targets 3.10 for compatibility
]
[tool.ruff.lint.isort]
# Keep `from x import a, b as c` on one statement instead of splitting it.
combine-as-imports = true
[tool.ruff.lint.per-file-ignores]
# Tests routinely rebind fixtures and assert on broad exception shapes.
"tests/**" = ["B011"]
[tool.ruff.format]
quote-style = "double"
indent-style = "space"
[tool.mypy]
python_version = "3.11"
# scripts/ and test dirs have no __init__.py; without explicit package bases
# mypy sees e.g. scripts/foo.py as both "foo" and "scripts.foo".
plugins = ["pydantic.mypy"]
mypy_path = "."
explicit_package_bases = true
namespace_packages = true
warn_unused_configs = true
warn_redundant_casts = true
no_implicit_optional = true
exclude = [
"^venv/",
"^\\.venv/",
]
# main.py is the reference for the standard CONTRIBUTING.md sets: every
# function there carries parameter and return annotations. The rest of the
# tree is type-checked but not yet required to be fully annotated.
[[tool.mypy.overrides]]
module = "main"
disallow_untyped_defs = true
# store.py has pre-existing type errors unrelated to cache implementation
[[tool.mypy.overrides]]
module = "store"
ignore_errors = true
# google-generativeai and its api_core siblings ship incomplete stubs.
[[tool.mypy.overrides]]
module = [
"google.*",
"stellar_sdk.*",
"redis.*",
"yaml.*",
"firebase_admin.*",
]
ignore_missing_imports = true
[tool.evaluation]
correlation_target = 0.85
inter_judge_agreement_target = 0.80
cost_per_eval_limit = 0.05
throughput_per_hour_target = 100
false_positive_rate_max = 0.08
calibration_drift_limit = 0.05