This paper introduces a highly efficient method for designing randomized controllers in complex, uncertain environments by leveraging gradient descent—a staple of modern machine learning—applied to the formal verification of probabilistic systems. By showing how to compute gradients efficiently within parametric Markov chains, the authors achieve a performance leap that outperforms existing state-of-the-art synthesis tools by at least an order of magnitude.
TL;DR
The authors present a novel approach to synthesize randomized controllers for partially observable systems by applying gradient descent to parametric Markov chains (pMCs). Their method efficiently computes gradients through linear equation systems, enabling the synthesis of controllers with thousands of parameters and outperforming current state-of-the-art techniques by over 10x in speed and scalability.
What Problem Does This Paper Address?
Designing controllers for systems that only have partial information about their environment (like a robot with noisy sensors) is notoriously difficult. Randomization is a key strategy for making these controllers robust, but finding the "right" amount of randomness is a complex optimization problem.
Formally, this is often framed as parameter synthesis for parametric Markov chains (pMCs). The goal is to find specific values for symbolic probabilities in a model so that the system meets a requirement, such as "the probability of a crash is less than 0.01%."
The challenge is that this problem is ETR-complete (as hard as finding roots of multivariate polynomials), and existing exact methods fail when the number of parameters grows beyond a few dozen. Real-world applications, however, often require thousands of parameters.
Methods
The core contribution is a principled way to evaluate gradients in pMCs efficiently. The authors demonstrate two equivalent ways to characterize the gradient of an expected reward (or reachability probability) with respect to a parameter:
- Equation-System Based: The gradient is the solution to a linear equation system derived by applying the product and sum rules to the standard equations for expected rewards.
- Automaton Based: The gradient can be viewed as the expected reward of a "derived" weighted finite automaton (WFA).
By solving these linear systems numerically (using methods like GMRES), they can compute the gradient at a specific point in the parameter space very quickly. They then evaluate several flavors of gradient descent, including:
- Classical methods: Plain GD, Momentum, and Nesterov accelerated GD.
- Adaptive methods: Adam, RMSProp, and RAdam.
- Sign methods: Variants that only use the sign of the gradient, not its magnitude.
To ensure parameters remain valid probabilities (between 0 and 1), they compared three restriction methods: Projection (clipping values to the boundary), Barrier Functions (adding a penalty near boundaries), and Logistic Functions (mapping unrestricted space to [0,1]).
Datasets
The authors evaluated their approach on a diverse set of benchmarks derived from:
- POMDPs: Including classic problems like
drone,refuel,4x4grid, andmaze. - Bayesian Networks: Such as
hailfinderandchild. - Network Protocols: Specifically the
nrp(network repair protocol) andnetwork2-prios.
These benchmarks ranged from small models to massive ones like maze2, which contains nearly 30,000 parameters and over 60,000 states.
Key Insights and Ideas
- Momentum-Sign is the Winner: Surprisingly, a simple "Momentum-Sign" method (which ignores the gradient's magnitude and only uses its direction combined with momentum) performed best. This is likely because many parameters in these models are "easy"—they naturally want to be at 0 or 1—and the sign-based approach pushes them there efficiently without getting bogged down by vanishingly small gradients.
- Projection is Robust: While barrier functions are popular in optimization, the authors found that simple projection was more effective. Barrier functions often pushed the search away from the edges of the parameter space, where optimal solutions frequently reside.
- Efficiency via Linear Algebra: The realization that gradients can be computed by solving $(|V| + 1)$ linear systems (where $|V|$ is the number of parameters) allows the method to scale linearly with the number of parameters, a massive improvement over symbolic methods.
Key Results
- Speedup: The proposed Gradient Descent method (specifically Momentum-Sign with Projection) outperformed existing baselines like Particle Swarm Optimization (PSO) and Quadratically-Constrained Quadratic Programming (QCQP) by at least one order of magnitude on most benchmarks.
- Scalability: The method successfully found feasible controllers for the
maze2benchmark with 29,749 parameters, a scale previously unreachable by state-of-the-art synthesis tools. - Reliability: Unlike PSO, which sometimes failed due to internal errors or memory limits on larger models, the GD approach proved to be highly stable across the entire benchmark suite.
Limitations and Future Work
While powerful, the authors note a few areas for improvement:
- Local Optima: Like all gradient-based methods, it can get stuck in local optima. The authors currently handle this with random restarts, but more sophisticated global search strategies could be explored.
- Parameter Ordering: The order in which parameters are updated in mini-batch settings might affect convergence speed. Investigating "parameter influence" could lead to better update schedules.
- Preprocessing: Integrating monotonicity checking (determining if a property always increases/decreases with a parameter) could further prune the search space before optimization begins.
Summary updated