add track-record reset; drop dead distance_penalty_factor knob
Track Record: new "Reset" action (POST /admin/track-record/reset) deletes all trade setups so stats start fresh after material scoring/setup changes — live setups regenerate on the next scan. Guarded by a confirm dialog. Recommendation config: remove distance_penalty_factor, which was exposed in the admin UI but consumed nowhere (the touch-probability model superseded it). A knob that silently does nothing is worse than no knob. Remaining defaults are left as-is — they're reasonable, and the honest way to tune them is backtesting against accumulated outcomes, not invented "researched" numbers. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -274,6 +274,16 @@ async def cleanup_data(
|
||||
return APIEnvelope(status="success", data=counts)
|
||||
|
||||
|
||||
@router.post("/admin/track-record/reset", response_model=APIEnvelope)
|
||||
async def reset_track_record(
|
||||
_admin: User = Depends(require_admin),
|
||||
db: AsyncSession = Depends(get_db),
|
||||
):
|
||||
"""Wipe the track record: delete all trade setups so stats start fresh."""
|
||||
counts = await admin_service.reset_trade_setups(db)
|
||||
return APIEnvelope(status="success", data=counts)
|
||||
|
||||
|
||||
# ---------------------------------------------------------------------------
|
||||
# Job control
|
||||
# ---------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user