Skip to content

Feature Request: Adaptive MultiPV Analysis for Enhanced Game Review #72

Description

@Chess321

Describe the issue

No Adaptive MultiPV Analysis for Enhanced Game Review.

Expected behavior

Adaptive MultiPV Analysis

Steps to reproduce

Run ShashChess 39.

Anything else?

Feature Request: Adaptive MultiPV Analysis for Enhanced Game Review

Hello ShashChess Team,

We'd like to propose a feature that could significantly enhance the quality and efficiency of game analysis, especially for longer, automated reviews. Recent tests using the Top Chess Engines Testsuite 2025 have provided strong evidence for this concept. As ShashChess 39 is arguably the best analysis engine in the world, this feature would be a perfect fit, further solidifying its leading position.

The Challenge

Currently, when analyzing a chess position with an engine, users typically set a fixed MultiPV value (e.g., 1, 3, or a very high number like 256 for "all" variations). This forces a trade-off:

Low MultiPV (e.g., 3): This focuses computing power on a few top lines, allowing for deeper analysis of those specific variations. However, it might miss crucial, less obvious candidate moves that only become apparent with a broader search.

High MultiPV (e.g., 256): This explores a much wider range of candidate moves, which is great for initial discovery but dilutes computing power across many lines, potentially sacrificing depth.

For long analysis times (e.g., several minutes or even hours per position), simply increasing the thinking time with a fixed MultiPV (e.g., MultiPV = 3) doesn't always yield proportional improvements in solution rates, as various tests have demonstrated.

Proposed Solution: Adaptive MultiPV Analysis

We propose an "Adaptive MultiPV Analysis" mode that intelligently combines the strengths of both approaches:

Initial Exploration Phase: For a set initial duration (e.g., the first 1 to 600 seconds, or a specified number of nodes), the engine would internally run with a very high MultiPV value (e.g., 256 or "all"). This allows for a broad exploration of the position, identifying a wider array of promising candidate moves, even if they aren't immediately obvious.

Deep Dive Phase: After this initial exploration time has elapsed, the engine would automatically switch to a lower, user-defined MultiPV value (e.g., 3) for the remainder of the analysis duration. By this point, the engine has a much better understanding of the most promising lines and can dedicate its full computing power to deepening the analysis of these top candidates.

Key Advantage: Consistent User Experience

Crucially, throughout both phases, the engine would only display the user's preferred number of top variations (e.g., 3 lines). This prevents the "jumping" or flickering of hundreds of lines on the screen during the initial broad search, providing a consistent and clean user interface, while still leveraging the benefits of wide exploration internally.

Evidence from Testsuite Results

Tests conducted with the Top Chess Engines Testsuite 2025 clearly illustrate the power of this concept. The following engine settings were used for all tests:

RAM: 32 GB

Threads: 8

MCTS by Shashin: On

MCTS Explore: On

MCTSThreads: 2

Full Depth Threads: 1

When analyzing 50 test positions:

1 Minute Analysis with MultiPV = 3: Solved 25 out of 50 positions (50%).

1 Minute Analysis with MultiPV = 256: Also solved 25 out of 50 positions (50%). This highlights that simply increasing MultiPV to a very high number for the entire duration does not necessarily improve the solution rate if not combined with sufficient depth.

2 Minutes Analysis with a fixed MultiPV = 3 (doubling time): Still solved 25 out of 50 positions (50%).

2 Minutes Analysis with Adaptive MultiPV (1 min MultiPV = 256 then 1 min MultiPV = 3): Solved 36 out of 50 positions (72%)!

This represents a +44% increase in solved positions by simply combining the two MultiPV strategies over the same total analysis time, compared to just doubling the time with a single MultiPV setting. This strongly suggests that the initial broad exploration helps the engine find solutions it would otherwise miss.

Further Benefits

More Accurate & Comprehensive Analysis: Leads to finding more "best" moves and deeper insights, especially in complex or less explored positions. This results in truly gold-standard analysis for critical game moments.

Improved Efficiency: Optimizes how computing power is utilized over time, making every second of analysis more productive. It's about working smarter, not just harder.

Increased Robustness Against Early Pruning: The initial wide search significantly reduces the risk of the engine overlooking and prematurely "pruning" promising but initially underestimated variations. This means fewer missed tactical opportunities or defensive resources.

Dynamic Resource Management: Allows the engine to dynamically allocate resources – searching broadly when discovery is key (at the start) and then deeply when the most promising candidates are identified. This is akin to a human grandmaster first surveying the whole board and then focusing on key lines.

Ideal for Automated / Overnight Analysis: Perfect for setting up long analysis sessions, as the engine will automatically utilize its time most effectively without manual intervention. Users can wake up to a more thoroughly analyzed game without manual adjustments.

Reduced User Frustration: Eliminates the need for users to manually switch MultiPV settings during long analysis sessions or restart analysis to explore different depths.

Enhanced Learning for Players: By consistently presenting the most accurate top lines found through this adaptive method, players gain deeper insights into why certain moves are superior, aiding their own improvement.

Uncovering Hidden Gems: The initial broad sweep can uncover surprising, counter-intuitive, or aesthetically pleasing lines that a deep but narrow search might never consider.

Better Human-Centric Error Detection: For reviewing human games, this approach can more effectively identify why a human player's choice might have been a "mistake" by considering a broader range of engine-preferred moves, as well as finding alternative "good enough" moves that were missed. This provides a richer understanding beyond just the single best engine move.

Adaptability to Various Position Types: This method inherently adapts to the nature of the position. In sharp, tactical positions, the initial broad search excels at identifying all critical lines. In quieter, positional ones, the subsequent deep dive refines subtle strategic nuances, making it a versatile approach for any game phase.

Optimized "Blunder" Identification: A broader initial search can more quickly and reliably pinpoint immediate losing lines (blunders) by exploring a wider array of responses to a given move.

We believe this "Adaptive MultiPV Analysis" would be a fantastic addition to ShashChess, significantly improving its game review capabilities and further cementing its status as a top-tier analysis tool.

Is this something the team would consider implementing?

Thank you for your hard work on ShashChess!

Operating system

All

ShashChess version

ShashChess 39

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions