[fix] agent: 보상함수를 q-table 상세 설명 v4 명세에 정합화
- 동적 가중치 W: 라운드 감쇠 → 상태 5차원 가중합 clip(Σwᵢ·Sᵢ, 0.2, 0.8) (식 12~13, 기존 w1~w5 연결) - 종료보상에 (1−W) 적용: R = W×R_price + (1−W)×R_end − λ×round (식 8) - R_price 3단계: P<anchor 시 1+β·(anchor−P)/anchor 초과달성 보너스 추가 (식 9~11, beta 의미 재정의) - price zone 경계는 명세(T)와 달리 anchor 유지(우선협상 규칙이 실제 의사결정 경계) — 사유 docstring 명시 - state_calculator/config 의 낡은 반대 컨벤션(anchor≥target) 주석 정정 - RewardCalculator(RewardConfig, StateConfig) 시그니처 변경 + 호출부 5곳 갱신, 테스트 기대값 정정 (76/76 PASS) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
43ac308a5e
commit
be1b4b968f
9 files changed
+57
-33
No files matched your search
@@ -59,7 +59,7 @@ class NegotiationService:
|
||||
decision.card_id = engine.mapper.get_card_id(decision.action_id)
|
||||
|
||||
# 4) 보상
|
||||
reward = RewardCalculator(engine.config.reward).calculate(snap)
|
||||
reward = RewardCalculator(engine.config.reward, engine.config.state).calculate(snap)
|
||||
|
||||
# 5) 학습: Q-learning 온라인 갱신 + touched 셀 영속화
|
||||
updated_q = decision.q_value
|
||||
|
||||
Reference in new issue
Block a user