TWO CRITICAL BUGS FIXED:
1. Missing use_quality_filters parameter (Pine Script parity):
- Added use_quality_filters: bool = True to MoneyLineV11Inputs
- Implemented bypass logic in signal generation for both long/short
- When False: only trend flips generate signals (no filtering)
- When True: all filters must pass (original v11 behavior)
- Matches Pine Script: finalSignal = buyReady and (not useQualityFilters or (...filters...))
2. RSI index misalignment causing 100% NaN values:
- np.where() returns numpy arrays without indices
- pd.Series(gain/loss) created NEW integer indices (0,1,2...)
- Result: RSI values misaligned with original datetime index
- Fix: pd.Series(gain/loss, index=series.index) preserves alignment
- Impact: RSI NaN count 100 → 0, all filters now work correctly
VERIFICATION:
- Test 1 (no filters): 1,424 signals ✓
- Test 2 (permissive RSI): 1,308 signals ✓
- Test 3 (moderate RSI 25-70/30-80): 1,157 signals ✓
Progressive sweep can now proceed with corrected signal generation.