Infinity Algo

Renamed "Dark Indicator" to "Infinity Algo"
Added possible Long/Short coming + Alerts (beta) + History
Added dynamic Take Profits and Stop Loss
Added option to view only Long or Short Trades
Default Leverage changed to 50x
Added Beta Take Profits
Changes to text
Bux Fixes
Changed Colors
New ribbon and channel bands
New Bar Coloring Based on Signal Strenght
New Background Coloring
Order Blocks with Breaks and Exits
-New Filter for ranging market
-New menu
โ ๏ธRemove the old script and reload the script from invite-only scripts again to get a new version.
๐Docs will be updated in the near future.
๐พYou can contact us regarding bugs.
-Adjusted plotshapes sizing
โ ๏ธRemove the old script and reload the script from invite-only scripts again to get a new version.
๐Docs will be updated in the near future.
๐พYou can contact us regarding bugs.
This update represents a significant evolution from V2.0, introducing powerful new adaptive capabilities and refining existing features.
๐ Major Updates & New Features:
Pine Script V6 Update: The script has been migrated to Pine Script version 6, leveraging the latest features and potential performance improvements of the platform.
๐ง AI Optimization Engine (Major Addition):
Adaptive Signals: Introduced a new "AI" signal mode (Show Signals Type input). When selected, the indicator dynamically adapts its core parameters based on machine learning analysis of recent market conditions.
Parameter Simulation: The AI engine continuously simulates hundreds of configurations for the primary momentum oscillator (Sensitivity, Upper/Lower Thresholds) on historical data.
Performance Evaluation: Each simulated configuration is scored based on a user-selectable metric (e.g., "Profit Factor \* Sqrt(Trades)", "Win Rate", "Average Profit"). Dedicated AI simulation TP/SL percentages are used for this evaluation.
Volatility Clustering (K-Means): Configurations are automatically grouped (clustered) based on their performance scores. These clusters typically align with different market volatility regimes (Low, Medium, High).
Dynamic Selection: The indicator identifies the current volatility regime and selects the best-performing configuration from the corresponding cluster (with sufficient simulated trades).
Real-time Threshold Adjustment: The selected AI thresholds are further fine-tuned based on immediate volatility fluctuations.
AI Dashboard: An optional on-chart dashboard displays the parameters (Sensitivity, Winrate, Thresholds, Trade Count) of the currently active AI configuration.
New AI Inputs: Added a dedicated ๐ง AI Clustering section in settings to control the AI engine (Enable, Update Frequency, Sensitivity Range, Dashboard, Performance Metric, Simulation TP/SL).
๐งน Removed Features (Moved to New Indicator, Now rolling):
Order Blocks / Buy Sell Zones: The functionality for identifying and displaying Order Blocks (Buy/Sell Zones) has been removed.
Keltner Channel Bands: The optional Keltner Channel visualization has been removed.
Take Profit Exit: Simplified the inputs.
โจ Refinements & Improvements:
Signal Type Input: Changed Show Signals from a number (1-4) to a descriptive dropdown string (Normal + Smart, Normal Only, Smart Only, Regular, AI) for better usability.
Global Settings & Themes:
Consolidated Text Color, Text Size, Color Theme, and Precision inputs into a single "Global Settings" group for better organization.
Introduced a wide array of predefined Color Themes (Default, Dark, High Contrast, Colorblind, Neon Teal, Infinity, etc.) that apply consistent coloring across indicator elements, replacing the simple Bull/Bear color inputs.
TP/SL/Entry Visualization: Changed the plotting style for Take Profit, Stop Loss, and Entry Price levels from individual circles to cleaner dotted lines with associated text labels, which extend forward from the entry bar. Old lines/labels are now correctly deleted when a new position starts.
TP Hit Plotting: Implemented a more efficient system to detect and plot Take Profit hits using small circles, reducing the number of plotshape calls.
"Possible Trade" Indicator: Refined the visual indicator for potential upcoming trades, now using an emoji (โ) and clearer text formatting.
๐ Alerts:
Added new alert conditions specifically for the "AI" Buy/Sell signals.
Improved Take Profit alert conditions to correctly trigger based on the refined TP hit detection logic when using 'Percentage' exits.
Removed alerts related to Order Blocks.
Code Structure: General code refactoring and organization improvements, including better commenting and grouping of related logic (especially the new AI sections).
We are currently updating the documentation
Note: Bugs may appear
This update focuses on a significant overhaul of the AI engine for more robust performance, the introduction of a brand-new signal mode, and several key usability improvements.
๐ Major Updates & New Features
- New "HL Sniper" Signal Mode:
- The old "Regular" signal type has been replaced with the new, more advanced HL Sniper mode.
- Completely Overhauled AI Engine:
- Advanced Performance Simulation:
The AI's back-testing engine has been rebuilt from the ground up. It now runs a more realistic simulation, accounting for Stop Loss, Take Profit, and opposite-signal exits to score each configuration. This provides a far more accurate evaluation of a strategy's true historical performance.
- Simplified & More Robust AI Selection:
The AI no longer separates strategies into volatility clusters. Instead, it now analyzes all simulated configurations and selects the single best-performing strategy overall, making its choice more direct and reliable.
- Stable AI Parameters:
Redesigned AI Dashboard:
- The dashboard has been revamped to display more meaningful, at-a-glance performance data.
- It now includes leveraged PnL projections (both in % and $), using the script's Leverage input and a simulated starting capital.
- The "Sim. Metric Val" field has been removed and replaced with the active Leverage setting for better clarity.
โจ Refinements & Improvements
- Granular Sensitivity Control:
- The main Sensitivity input now accepts decimal values (e.g., 18.1, 18.5), allowing for finer control over the oscillator's period.
- Customizable Thresholds:
- Added Upper Threshold and Lower Threshold inputs. Users can now directly adjust the RSI levels required to trigger buy and sell signals, offering greater control over sensitivity.
- Removed Ranging Market Filter:
The experimental Ranging Market Filter (Beta) toggle has been removed to simplify settings and focus on the more advanced AI and HL Sniper modes.
- Cleaner Chart Interface:
- The redundant "Show Buy/Sell Signals?" toggle has been removed.
- When a Take Profit level is hit, its price label is now hidden along with the line, preventing chart clutter during an open trade.
- Consistent Theming:
- The AI Dashboard text color is now correctly synced with the Global Text Color setting.
โ Important: How to Update โ
To ensure you have the latest version, you must remove the existing indicator from your chart and re-add it from the "Invite-Only Scripts" section.
If you require access or have any issues, please feel free to contact us.
Stop Loss Hit Alerts:
We've added two new alert conditions:
- 2.2 Stop Loss Long Hit
- 2.3 Stop Loss Short Hit
You can now create alerts to be notified the instant your Stop Loss level is triggered.
โจ Improvements & Bug Fixes
- Alert System Overhaul: All alert conditions have been re-structured and re-numbered sequentially for clarity and ease of use. This cleanup includes removing redundant combined alerts and adding back individual Buy/Sell - Normal and Buy/Sell - Smart alerts for more granular control.
- Corrected "Possible Coming" Signal Logic: Fixed a critical bug where the "Possible Long/Short Coming" alerts would trigger incorrectly when using the AI or HL Sniper signal modes. These pre-signal warnings are now correctly restricted to only the RSI-based modes (Normal & Smart).
โ Important: How to Update โ
To ensure you have the latest version, you must remove the existing indicator from your chart and re-add it from the "Invite-Only Scripts" section.
**Static Optimization Mode** ๐
- "Train once, apply forever" optimization
- Analyzes first 4900 bars to find optimal settings
- Locks configuration for consistent forward testing
- Perfect for backtesting and strategy validation
- Prevents parameter drift and overfitting
**AI Sniper Mode** โจ
- New signal type combining AI with advanced algorithms
- Independent optimization tracking from standard AI mode
- Designed for high-precision entries in volatile markets
**Advanced Performance Metrics** ๐
- Sharpe Ratio & Sortino Ratio
- Calmar Ratio & Martin Ratio
- System Quality Number (SQN)
- Robust ML Score with Lorentzian distance
- Sortino + Calmar Composite scoring
**AI Confidence Scoring** ๐ฏ
- Real-time confidence percentage (0-100%)
- Visual progress bars in dashboard
- Separate tracking for AI and Sniper modes
- Dynamic updates based on market alignment
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ **CHANGED**
**AI Optimization Modes** ๐ง
- New choice: Walk-Forward vs Static optimization
- Walk-Forward: Continuous adaptation every N bars
- Static: One-time optimization with locked parameters
- Static mode optimizes at bar 4900 for best results
**AI Update Frequency** โก
- Static mode eliminates update lag completely
- Massive performance improvement (up to 3x faster)
- Prevents timeouts on all timeframes
**Dashboard Redesign** ๐จ
- Modern UI with gradient effects
- Professional color schemes
- Mode indicators: "SIMULATED", "STATIC (LOCKED)", "OPTIMIZING"
- Live configuration counter
- Enhanced metric organization
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ **IMPROVED**
**HL Sniper Mode** ๐ฏ
- Enhanced calculations
- Better parameter optimization
- Improved signal accuracy
**Performance & Memory** ๐
- 5000 bar lookback capability
- Advanced caching system
- Intelligent configuration pruning
- 40% reduction in computational overhead
- Static mode eliminates real-time recalculation
**Mathematical Precision** ๐ฌ
- Lorentzian distance for outlier resistance
- Enhanced normalization algorithms
- More stable optimization convergence
- Better handling of edge cases
Improvements:
- Faster loading - AI disabled by default
- Fixed dashboard leverage calculation
Enable AI Optimization manually in settings when needed
๐ฏ New Features
- New Exit Strategy Option: Added "Opposite Signal" exit type
- Peak Profit Display Control: New toggle to show/hide peak profit labels for cleaner chart visualization
- Visual Stop Loss Indicators: Stop loss lines now change to dot markers when hit for better visual feedback
- Enhanced TP/SL Markers: Clear visual indicators showing exactly where take profits and stop losses trigger
โ๏ธ Performance Improvements
- Signal Accuracy: Refined AI signal generation algorithms for more reliable entry/exit points
- AI Backtesting Reliability: Enhanced validation requirements for more accurate historical performance data
- Calculation Optimization: Improved mathematical calculations including Lorentzian Distance normalization
- Memory Management: Optimized indicator performance for smoother operation on lower timeframes
๐ง User Experience Updates
- Alert System: Improved stop loss alerts that trigger only once per event
- Label Management: Better handling of on-chart labels with increased label capacity
- Strategy Metrics: Improved advanced performance metrics for better strategy evaluation
- Visual Feedback: Enhanced visual markers for position management events
๐ Bug Fixes
- Fixed duplicate alert triggering issues
- Resolved peak profit label display inconsistencies
- Corrected profit calculation methods for more accurate results
- Fixed visual marker positioning on take profit and stop loss events
- Improved position tracking reliability
๐ Important Notes
- Existing strategies may show different results due to improved calculation methods
- Please reconfigure your alerts if using stop loss notifications
- Check the new "Show Peak Profit" option in Visualization Settings
โก Performance Optimization
- Faster Loading: Significantly improved indicator initialization and loading times
- Smart Processing: Calculations now run only when needed based on selected signal type
- Resource Efficiency: Reduced memory usage when certain signal modes are not active
๐ฏ New Features
- Advanced Stop Loss Trailing: New trailing stop system with three modes:
โข None: Traditional static stop loss
โข Breakeven: Automatically moves SL to entry price after hitting your chosen TP level
โข Moving Target: Progressively trails SL to previous TP levels as new targets are reached - Customizable Trailing Triggers: Choose which TP level (TP1-TP6) activates trailing behavior
- Visual Trailing Indicators: Stop loss labels now show (BE) for breakeven or (TP#) for current trail level
โ๏ธ Performance Improvements
- Enhanced Signal Detection: Refined AI Sniper signal generation for more reliable entries
- Optimized Exit Logic: Improved handling of opposite signal exits and TP/SL interactions
- Better Trade Management: More accurate tracking of position states and exit conditions
๐ง Visual Enhancements
- Smart Label Management: Entry price labels automatically hide when SL moves to breakeven to reduce clutter
- Dynamic Line Colors: Entry lines dim when stop loss is at breakeven for better visual clarity
- Improved SL Display: Stop loss line converts to dots when hit (as previously announced)
๐ Bug Fixes
- Fixed signal filtering logic for more consistent behavior
- Corrected TP price calculations for all enabled levels
- Fixed configuration display formatting
- Improved exit signal processing accuracy
๐ Important Notes
- The new trailing stop features are optional - existing strategies continue to work unchanged
- Check the "Exit Settings" group for new trailing options
- Trailing stops can significantly impact strategy performance - test thoroughly
- Visual improvements help track complex trailing scenarios more easily
Invite-only script
Only users approved by the author can access this script. You'll need to request and get permission to use it. This is typically granted after payment. For more details, follow the author's instructions below or contact InfinityAlgo directly.
Note that this private, invite-only script has not been reviewed by script moderators, and its compliance with House Rules is undetermined. TradingView does NOT recommend paying for or using a script unless you fully trust its author and understand how it works. You may also find free, open-source alternatives in our community scripts.
Author's instructions
Disclaimer
Invite-only script
Only users approved by the author can access this script. You'll need to request and get permission to use it. This is typically granted after payment. For more details, follow the author's instructions below or contact InfinityAlgo directly.
Note that this private, invite-only script has not been reviewed by script moderators, and its compliance with House Rules is undetermined. TradingView does NOT recommend paying for or using a script unless you fully trust its author and understand how it works. You may also find free, open-source alternatives in our community scripts.