feat: 새로운 안전 규칙 및 최적화 적용을 통한 트레이딩 시스템 개선

변경 사항 (Changes):

구문 오류(Syntax error) 및 토큰 낭비를 방지하기 위해 에이전트 쉘(Agent shell)과 파이썬 코드 스니펫에 다수의 신규 안전 규칙(Safety rules)을 추가함.

스키마 검증 및 적절한 SQL 포맷팅을 보장하기 위해 임시(Ad-hoc) 데이터베이스 쿼리 작성 가이드라인을 도입함.

코드 수정 후 UI 기능이 정상 작동하는지 확인하기 위해, 백테스트 웹 서비스 재시작 및 브라우저 검증에 대한 새로운 규칙을 구현함.

시스템 전반의 무결성(Integrity)을 유지하기 위해 실전 매매(Live trading), 웹 백테스팅, 파라미터 탐색(Parameter searches) 간의 일관성 검사(Consistency checks) 체계를 확립함.

기대 효과 (Impact):

이러한 개선 사항들은 트레이딩 시스템의 견고성(Robustness)과 신뢰성을 향상시키며, 에러 발생을 최소화하고 다양한 시스템 컴포넌트 간의 원활한 상호작용을 보장함.
This commit is contained in:
Your Name
2026-07-17 01:09:09 +09:00
parent a4626e0351
commit fc27e726f9
151 changed files with 20718 additions and 6450 deletions

View File

@@ -15,6 +15,7 @@ from kis_trader.backtest.param_search_momentum import (
_momentum_combo_grid_valid,
_momentum_grids,
)
from kis_trader.backtest.param_search_scalping import _scalp_grids
from kis_trader.backtest.tail_param_search import _tail_grids
@@ -40,6 +41,12 @@ def _suggest_from_grid(trial: optuna.Trial, grid: Dict[str, List[Any]]) -> Dict[
return combo
def suggest_scalp_params(trial: optuna.Trial, mode: str) -> Dict[str, Any]:
combo = _suggest_from_grid(trial, _scalp_grids()[mode])
combo["use_macd_cross"] = False
return combo
def suggest_tail_params(trial: optuna.Trial, mode: str) -> Dict[str, Any]:
return _suggest_from_grid(trial, _tail_grids(mode))
@@ -59,6 +66,10 @@ def suggest_breakout_params(trial: optuna.Trial, mode: str) -> Dict[str, Any]:
return combo
def scalp_grid_axis_keys(mode: str) -> List[str]:
return list(_scalp_grids()[mode].keys())
def tail_grid_axis_keys(mode: str) -> List[str]:
return list(_tail_grids(mode).keys())