From 11b370095992a35058a33afec00ed67cbc8e0f53 Mon Sep 17 00:00:00 2001 From: gahusb Date: Fri, 22 May 2026 03:12:24 +0900 Subject: [PATCH] =?UTF-8?q?feat(weight-evolver):=20run=5Fsimulation?= =?UTF-8?q?=EC=9D=B4=20active=20W=EB=A5=BC=20score=5Fcombination=EC=97=90?= =?UTF-8?q?=20=EC=A0=84=EB=8B=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lotto/app/generator.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lotto/app/generator.py b/lotto/app/generator.py index 3fac585..ec3a142 100644 --- a/lotto/app/generator.py +++ b/lotto/app/generator.py @@ -25,6 +25,7 @@ from .db import ( ) from .analyzer import build_analysis_cache, build_number_weights, score_combination from .utils import weighted_sample_6 +from .weight_evolver import get_active_weight def run_simulation( @@ -54,6 +55,7 @@ def run_simulation( # ── 1. 통계 캐시 및 가중치 구성 (시뮬레이션 전체에서 재사용) ──────────── cache = build_analysis_cache(draws) weights = build_number_weights(cache) + active_weights = get_active_weight() # None → analyzer uses fixed default # ── 2. 후보 생성 및 스코어링 ────────────────────────────────────────────── candidates: List[Dict[str, Any]] = [] @@ -69,7 +71,7 @@ def run_simulation( continue seen_keys.add(key) - scores = score_combination(nums, cache) + scores = score_combination(nums, cache, weights=active_weights) candidates.append({ "numbers": sorted(nums), **scores,