Repository navigation
Conversation
run() now calls one method per phase: the personas step, the question step (one method per source: --questions-from, the cached set, the golden set, generated), and the evaluation summary. The question-source resolution in __init__ moves into two helpers. The output is unchanged. The public question-set helpers (resolve_questions_from_path, compute_question_set_hash, load_questions_payload) move to orchestrator/question_sets.py, which pipeline.py imports, so the names still resolve from pipeline. This keeps pipeline.py under the 800-line growth cap. The run() complexity baseline entry is dropped. Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>
EvaluationPipeline.__init__ takes an EvaluationSettings dataclass with the same fields and defaults as the keyword arguments it had. The production callers (benchmark run and evaluate) pass settings=. The keyword form still works: it builds the settings, and a refusal reads the same as before. Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>
Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com> # Conflicts: # dokimi/dokimi/orchestrator/pipeline.py
Thread: PRRT_kwDOVBg7g87AQkCS Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>
Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>
The constructor was (*args, settings=None, **kwargs), so mypy could not check the fields of a call. It is now __init__(self, settings: EvaluationSettings). A non-EvaluationSettings value raises TypeError. Every caller moves to settings=EvaluationSettings(...): the production callers were already there; the tests (about 60 sites) and the methodology doc example move too. The keyword and positional forms are refused by the signature. A changed fragment records the API change. Stacked on intel#1648. Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>
Mutation of changed linesAt 2580ee4: 42 caught · 7 missed Each row is a small deliberate break (a mutant) of a line this PR changes that every test reaching that line still passes. Add a test that fails on it or, if it cannot change behaviour, put
Not checked:
Warning only: a missed break does not fail the job. Updated on every push; the full report is in the ci run summary. |
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1669 +/- ##
==========================================
- Coverage 96.44% 96.43% -0.01%
==========================================
Files 585 586 +1
Lines 76600 76636 +36
Branches 13175 13176 +1
==========================================
+ Hits 73876 73905 +29
- Misses 1671 1674 +3
- Partials 1053 1057 +4
🚀 New features to boost your workflow:
|
Summary
Stacked on #1648 (base
5d11fb161).EvaluationPipelinetakes its inputs only assettings=EvaluationSettings(...).__init__is typed, so mypy checksEvaluationSettingsfields at each call site again.EvaluationPipeline(questions_from=...)) now raiseTypeError.EvaluationSettingsvalue forsettings=raisesTypeError(wasAttributeError).settings=(codemod, byte-offset insertion). Production callers were already onsettings=. 19 test files touched, plusdocs/methodology.md.docs/methodology.mdusing the keyword form. Updated here.Evidence
EvaluationPipeline(questions_from=...)builds and runs.After: the same call raises
TypeError.EvaluationPipeline(settings=EvaluationSettings(questions_from=...))builds an identical pipeline.make ci-local: green exceptpip-audit, which fails withPermissionErroron the shared/mnt/cached_osescache dir. Environment issue, not in this diff.pr-reviewlocal passes (fresh-context children), no blocking findings. Nits acted on in pass 1. Declined: SPDX header on the new fragment (311 of 526 existing fragments also lack it), duck-typed settings (deliberately unsupported), old historical fragments that mention the keyword form (left as history).scripts/list_new_error_paths.py, not a CI gate): theTypeErrorinpipeline.pyand its tests intests/test_pipeline_settings.py. Requirement:docs/methodology.md(keyword form replaced bysettings=), public-API change recorded in the Changed fragment.Changelog: Changed fragment
20261206_100000_napetrov_arch-r15-3-pipeline-settings.md. The #1648 fragment20261205_221923_nikolay.a.petrov_pipeline-settings.mdis removed because it said positional and keyword arguments still work.Merge Danger
Door: two-way. Reverting restores the keyword/positional forms. Callers outside this repo that use the keyword form break until they move to
settings=.Stacking: this PR is based on #1648 (
arch/r14-4). Merge #1648 first, then retarget this PR tomain. Merging out of order would pull #1648's commits intomainthrough this branch's base.Blast Radius: public-api (
EvaluationPipelineconstructor, keyword and positional forms refused).🤖 Generated with Claude Code