|
All checks were successful
CI / changes (push) Successful in 10s
CI / changes (pull_request) Successful in 7s
CI / backend-tests (push) Has been skipped
CI / frontend-tests (push) Has been skipped
CI / openapi-codegen-check (push) Has been skipped
CI / backend-tests (pull_request) Has been skipped
CI / frontend-tests (pull_request) Has been skipped
CI / openapi-codegen-check (pull_request) Has been skipped
When v_prior == 0 and v_rec > 0, the old code unconditionally assigned trend_ratio = 2.0, producing an artificial 2x jump even for districts with negligible recent velocity. New formula: ratio = 1.0 + min(1.0, v_rec / _REF_VELOCITY) * (_TREND_CAP_VPRIOR_ZERO - 1.0) Where: _REF_VELOCITY = 10.0 (monthly flats/corpus — EKB "well-performing" benchmark) _TREND_CAP_VPRIOR_ZERO = 1.5 (max ratio for the v_prior==0 case) Tiny v_rec (e.g. 1 flat/month) → ratio ≈ 1.05 (near neutral) Large v_rec (≥ 10 flat/month) → ratio → 1.5 (capped, below old hard 2.0) v_prior > 0 branch is unchanged. Also fixes pre-existing ruff violations in the same file (E401 multi-import, E701 inline colon, E722 bare except, F401 unused import) so ruff check passes clean. |
||
|---|---|---|
| .. | ||
| cache | ||
| reports | ||
| static | ||
| .gitignore | ||
| 01_load_sites.py | ||
| 02_fetch_pois.py | ||
| 03_score.py | ||
| 04_report.py | ||
| 05_objective_pull.py | ||
| 06_match_economics.py | ||
| 07_objective_full_pull.py | ||
| 08_enrich_economics.py | ||
| 09_macro_and_trend.py | ||
| 10_score_v2.py | ||
| 11_refetch_pois_extended.py | ||
| 12_more_pois.py | ||
| db_init.py | ||
| server.py | ||