Custom thresholds with user macro context