Offline timed pattern matching under uncertainty

Étienne André, Ichiro Hasuo, Masaki Waga

Abstract

This paper introduces a method for parametric timed pattern matching, allowing researchers to identify not just when a specific behavior occurs in a system log, but also the timing constraints under which it holds. By reducing the matching problem to a reachability problem in Parametric Timed Automata (PTA), the authors provide a framework to synthesize unknown timing parameters directly from real-world execution data. The approach is shown to be decidable for finite logs and demonstrates linear scaling on realistic automotive benchmarks.

Introduction

In real-time systems, timed pattern matching typically identifies the start and end times of specific event sequences within fixed timing bounds. However, real-world scenarios often involve uncertainty regarding these bounds. For instance, an engineer might need to discover the actual maximum delay observed between a trigger and a response across a 10-hour log, rather than checking against a pre-defined 5ms deadline. This paper addresses the challenge of offline monitoring under uncertainty, where timing bounds are parameters to be discovered rather than fixed values.

Methodology

The authors propose a reduction of the pattern matching problem into a parametric reachability problem through several key steps:

  1. MakeSymbolic: A pattern, represented as a Timed Automaton, is transformed into a "symbolic pattern." Parameters $t$ and $t'$ are added to represent the start and end times of the match, and logic is included to allow the pattern to initiate at any point in the log.
  2. TW2PTA: The input log (a timed word) is converted into a non-parametric Timed Automaton. This log becomes a linear chain of states where transitions are guarded by the absolute time of events.
  3. Synchronized Product: The product of the symbolic pattern and the log automaton is computed. A match exists if the system can reach the accepting state of the pattern.
  4. Reachability Synthesis: The specialized tool IMITATOR is used for parametric timed model checking to solve for the parameters.
Figure 1: (a) A parametric timed automaton and (b) a corresponding timed word representing the system log.

An optimized version, PTPM_opt, was also developed to prune the search space when only the minimum or maximum possible values of a parameter are required.

Key Insights and Results

A significant theoretical insight is that while parametric timed automata analysis is generally undecidable, the problem becomes decidable in this context because the log is a finite sequence, bounding the state space.

Instead of discrete timestamps, the output of this process is a symbolic constraint—typically a union of polyhedra. This provides a mathematical description of the relationships between start times, end times, and unknown parameters (e.g., $1.7 < t < 2.8 - p_1$).

Figure 3: 2D projections of the synthesized constraints (polyhedra) on various parameter pairs, such as $p_1$ vs $p_2$ and $t$ vs $t'$.

Performance Evaluation

The approach was evaluated on three benchmarks: GEAR and ACCEL (automotive logs with up to 25,000 events) and BLOWUP (a combinatorial worst-case scenario). Key findings include:

  • Linear Scaling: For realistic automotive benchmarks, computation time scaled linearly with log length.
  • Efficiency: The optimized PTPM_opt algorithm provided a ~20% speedup and ~25% reduction in memory usage for the GEAR benchmark.
  • Complexity Handling: In the BLOWUP test, the optimized version maintained linear performance, processing a 1,000-event log in 1.2 seconds, whereas the standard algorithm took over 15 minutes.

Conclusion and Future Work

The proposed framework successfully handles large-scale logs, outputting complex symbolic matches in seconds. While currently limited to offline monitoring, future work aims to adapt the approach for real-time applications and integrate "skipping" algorithms (like Boyer-Moore) to further enhance search speeds. Interpreting the high-dimensional polyhedral outputs remains a challenge, though 2D projections offer a viable path for human analysis.

Summary updated

BibTeX
@inproceedings{andre2018offline,
  author = {Étienne André and Ichiro Hasuo and Masaki Waga},
  title = {{Offline timed pattern matching under uncertainty}},
  booktitle = {ICECCS},
  year = {2018},
  url = {https://openreview.net/forum?id=ylYhppGnmA},
}
Figure