Source-linked AI summary
TeLoGraF: Temporal Logic Planning via Graph-encoded Flow Matching
Yue Meng, Chuchu Fan
TL;DR
General STL planning lacks diverse paired data and effective encoders for conditioning one model on varied specifications. TeLoGraF combines a GNN STL encoder with flow matching, trains on over 200K paired specifications, and outperforms classical and learning-based baselines across five environments while maintaining fast inference. Its main scope boundary is that data-driven performance degrades on complex or heavily out-of-distribution STL syntax and lacks soundness and completeness guarantees.
Problem
Existing methods rarely train one model for general STLs, while diverse paired datasets and effective STL encoders are also lacking.
Method
TeLoGraF uses graph encoding with a GNN and flow matching to generate trajectories for general STL specifications, trained on over 200K paired demonstrations.
Results
Across five simulation environments, TeLoGraF outperforms classical and learning-based baselines in STL satisfaction while providing fast inference and handling varied STL forms.
Takeaways & Limitations
Graph-based STL encoding and flow matching support planning across diverse specifications, including complex and out-of-distribution cases within the evaluated scope.
Takeaways & Limitations
TeLoGraF lacks soundness and completeness guarantees, and its performance degrades on complex or heavily out-of-distribution STL syntax.
Abstract
from arXiv · showhide
Learning to solve complex tasks with signal temporal logic (STL) specifications is crucial to many real-world applications. However, most previous works only consider fixed or parametrized STL specifications due to the lack of a diverse STL dataset and encoders to effectively extract temporal logic information for downstream tasks. In this paper, we propose TeLoGraF, Temporal Logic Graph-encoded Flow, which utilizes Graph Neural Networks (GNN) encoder and flow-matching to learn solutions for general STL specifications. We identify four commonly used STL templates and collect a total of 200K specifications with paired demonstrations. We conduct extensive experiments in five simulation environments ranging from simple dynamical models in the 2D space to high-dimensional 7DoF Franka Panda robot arm and Ant quadruped navigation. Results show that our method outperforms other baselines in the STL satisfaction rate. Compared to classical STL planning algorithms, our approach is 10-100X faster in inference and can work on any system dynamics. Besides, we show our graph-encoding method's capability to solve complex STLs and robustness to out-distribution STL specifications. Code is available at https://github.com/mengyuest/TeLoGraF
1. Introduction
Complex STL-constrained planning matters for real-world tasks, but existing methods struggle with general specifications, diverse data, and efficient encoding. TeLoGraF addresses these gaps with graph-encoded flow matching, a 200K-specification dataset, and broad empirical evaluation.
- Motivation: Temporal-logic planning supports applications including navigation, autonomous vehicles, and industrial assembly by enforcing safety, efficiency, and correctness constraints.Examples include reaching destinations while avoiding obstacles and performing actions in sequence.
- Motivation: STL planning is difficult because specifications are non-Markovian, synthesis is NP-hard, and existing methods struggle to balance quality and efficiency on complex or high-dimensional systems.Classical approaches include sampling-, optimization-, and gradient-based methods.
- Research gap: Existing learning-based methods usually target fixed or parametrized STLs, so new specifications often require retraining and no prior model handled general STL inputs directly.Other approaches either require differentiable environments or remain constrained by their original data distributions.
- Research gap: Three gaps limit STL-conditioned learning: insufficiently diverse specifications, no large paired-demonstration dataset, and limited analysis of effective STL encoders.These gaps concern both data coverage and how temporal-logic information reaches downstream models.
- Contributions: TeLoGraF combines graph-encoded flow matching with four STL templates and over 200K paired specifications collected across robot domains.The framework uses a GNN encoder and demonstrations generated with off-the-shelf solvers.
- Results: Across five environments from 2D dynamics to Franka Panda and Ant navigation, TeLoGraF improves STL satisfaction and inference efficiency relative to learning and classical baselines.The study also reports effectiveness on complex and out-of-distribution STL specifications.
2. Related work
Related work spans generative modeling for robotics and temporal-logic planning. Prior STL methods include sampling, optimization, evolutionary, and gradient-based approaches, while generative robotics methods imitate demonstrations across several input modalities.
- Generative models for robotics: Diffusion-model research in robotics has expanded rapidly, motivating surveys and demonstration-based neural approaches.The cited paradigm trains models to imitate collected trajectories.
- Generative models for robotics: Robotics generative models commonly learn from real-world demonstrations or off-the-shelf solvers and include state-based, 2D, 3D, and vision-language-action approaches.These methods differ in input modality and output form.
- Signal Temporal Logic: STL planning has used sampling-based, mixed-integer, evolutionary, and gradient-based methods because STL lacks the well-formed automaton available for LTL.The related-work passage lists representative methods and references across these categories.
3. Preliminaries
The paper formulates STL over discrete-time dynamical-system signals and introduces four representative specification templates. Flow matching is presented as a continuous transformation between data trajectories and Gaussian noise.
- Signal Temporal Logic: A discrete-time system generates a signal s = x_0, x_1, ..., x_T from an initial state and control sequence, and STL evaluates properties of that signal.The dynamics are written as x_{t+1} = f(x_t, u_t).
- STL templates: The four templates are single-goal, multi-goal, sequential, and partial specifications, differing in goal selection and temporal ordering.Single-goal uses timed reachability, multi-goal permits valid subsets, sequential imposes strict order, and partial imposes only some precedence constraints.
- STL syntax: STL formulas are built from true, predicates, negation, conjunction, and until with time intervals; derived operators include or, eventually, and always.Satisfaction is denoted s, t |= ϕ when the signal satisfies the formula at time t.
- Flow matching: Diffusion and flow matching learn data distributions through forward and inverse processes, while flow matching continuously transforms samples toward Gaussian noise with a vector field.The inverse process generates samples by reversing the learned transformation.
4. Methodology
TeLoGraF represents STL specifications as syntax-tree graphs, encodes them with a GNN, and conditions a flow model on the resulting embedding and initial state to generate trajectories. Its methodology covers four temporal-logical templates, graph features capturing operators and spatial-temporal attributes, and ODE-based trajectory generation.
- STL specification templates: The dataset uses four STL templates—single-goal, multi-goal, sequential, and partial-order—paired with reach and avoid semantics to emphasize temporal and logical complexity.The templates represent absolute timing, temporal ordering, multi-choice goals, and dependencies, with safety constraints paired through ϕavoid.
- STL graph representation: TeLoGraF models STL specifications as directed graphs whose nodes represent operators or atomic propositions and whose child-to-parent edges preserve syntax-tree structure.Each node stores operator type, temporal bounds, object geometry, and an Until-child ordering indicator.
- GNN encoder: A multilayer GNN performs message passing over the specification graph and aggregates final node representations into a fixed-dimensional STL embedding for downstream trajectory generation.Neighbor aggregation uses permutation-invariant functions, while nonlinear message and update functions increase encoder expressiveness.
- Simulation environments: The methodology is evaluated across Linear, Dubins, PointMaze, AntMaze, and Franka Panda environments spanning 2D navigation, maze navigation, and robot-arm manipulation.The benchmarks include circular regions and obstacles, square maze tiles, and cube-reaching tasks with collision avoidance.
- Conditional flow for trajectory generation: The conditional flow model receives the STL embedding and initial state, learns a velocity field from Gaussian source samples toward demonstrated trajectories, and generates planned trajectories by solving an ODE.Training interpolates between source and target samples; inference integrates the learned field from a random Gaussian sample to obtain the final trajectory.
5. Experiments
Across five simulation environments, TeLoGraF variants are evaluated against classical and learning-based planners, with analyses of runtime, flow-step efficiency, encoder design, STL-category coverage, and robustness. The experiments show strong overall solution quality and efficiency, while exposing weaker generalization on complex or heavily out-of-distribution STL syntax.
- 5.1. Main results: TeLoGraD achieves the highest STL satisfaction with lower computation budgets than almost all baselines, while TeLoGraF variants improve the solution-quality/runtime trade-off.On Franka Panda, TeLoGraF (Fast) is 123.6X faster than Grad and 60.7X faster than CEM while achieving a higher satisfaction rate.
- 5.2. Ablation study on the flow steps: TeLoGraF (Fast) matches TeLoGraF’s STL satisfaction using one-tenth the runtime, motivating its use with 10 ODE sampling steps.In Dubins, satisfaction does not drop until the number of ODE steps reaches 10; with 2 steps, validation satisfaction is 0.34 versus 0.45 for the original model.
- 5.3. Ablation study on encoder designs for STL: GNN and TreeLSTM generalize better than GRU and Transformer to unseen STL syntax, and GNN is selected because its performance is similar to TreeLSTM with a briefer encoding design.Graph encoders’ permutation invariance may make learning syntax more efficient.
- 5.4. Encoder coverage analysis on varied STL types: Graph-encoding improvements over sequence models are concentrated in sequential and partial STL types, although all models struggle with complex categories in several environments.The category analysis covers single-goal, multi-goal, sequential, and partial STL specifications.
- 5.5. Robustness test for encoders on out-domain STLs: Under duplicated-node STL augmentations, all encoders degrade as augmentation increases, but GNN and TreeLSTM remain resilient and often outperform sequence models on out-of-domain inputs.The robustness test changes STL syntax while keeping trajectories fixed.
- Limitations: TeLoGraF is data-driven, lacks soundness and completeness guarantees, and degrades on complex or heavily out-of-distribution STL syntax.The paper suggests trajectory refinement with classical methods as future work to improve generalization and robustness.
6. Conclusion
TeLoGraF is a learning-based framework for solving general STL tasks through graph encoding and flow matching. The paper reports flexible specification handling, strong performance against classical and data-driven baselines, fast inference, and a new diverse STL-planning dataset.
- TeLoGraF solves general STL tasks through graph encoding and flow matching while handling flexible specification forms.
- The framework outperforms existing classical and data-driven baselines while maintaining fast inference speed.
- The paper introduces a dataset for temporal logic planning to address the lack of diverse and structured STL benchmarks.
- Future work targets improved generalization and robustness to more complex and out-of-distribution STL specifications.
Impact Statement
The work aims to advance robotics and decision-making for long-horizon tasks. Deployment of a fully autonomous robot using the algorithm could lead to unsafe behavior, so a safety filter or backup policy is needed.
- Deployment of a fully autonomous robot using the algorithm could lead to potentially unsafe behavior.
- A safety filter or backup policy is needed for deploying the planned behavior.
A.1.1. LINEAR
The LINEAR environment uses a single-integrator model with 2D positions and velocity controls. Demonstrations are generated by optimizing STL robustness while constraining and smoothing the control inputs.
- The environment uses a single-integrator model with 2D position state (x, y) and velocity control input (u, v).The time step duration is ∆t = 0.5.
- Demonstration trajectories are generated with gradient-based trajectory optimization implemented in PyTorch.Goal regions and circular obstacles are randomly generated, and STL specifications are procedurally constructed.
- The loss maximizes truncated STL robustness, constrains control magnitude to 1, and minimizes control magnitude for smoother trajectories.
A.1.2. DUBINS
The DUBINS and related benchmark setups combine car-like or robotic dynamics with procedurally generated STL tasks and demonstration-collection procedures. The experiments span 2D navigation, an 8-DoF quadruped, a 7-DoF arm, and guidance-based baselines.
- A.1.2. DUBINS: The car-like model uses state (x, y, θ, v) and controls angular velocity ω and acceleration a.The time step duration is ∆t = 0.5.
- A.1.2. DUBINS: Its dynamics update position, heading, and velocity using the current velocity, heading, angular velocity, acceleration, and ∆t.
- A.1.3. POINTMAZE: PointMaze and AntMaze use maze navigation with horizons of 512 steps, collecting trajectories through waypoint planning and goal-reaching controllers or policies.PointMaze uses a 2D point mass, while AntMaze uses an 8-DoF quadruped with 27-dimensional observations and 8-dimensional torque control.
- A.1.4. FRANKA PANDA: The Franka Panda setup uses a 7-DoF robot arm simulated in PyBullet, with procedural STL formulas containing goals and obstacles.
- Baseline data collection varies gradient-descent iterations by environment, while the Cross Entropy Method uses elite size 25, population size 64, and 100 iterations.
- Guidance-based baselines add goal-conditioned flow matching and, for LTLDoG, an STL classifier used during generation; classifier training is 10-20X slower than flow-model training.
B. Additional visualizations from our flow-matching model
The visualizations examine TeLoGraF trajectories in the Dubins environment as the ODE-step count varies, using 100 steps as the original setup and decreasing to 1.
- At 100 ODE steps, TeLoGraF uses its original Dubins-environment setup for trajectory generation.
- As ODE steps decrease, the generated trajectory set becomes more concentrated.
- The predicted trajectories satisfy the STL until ODE steps reach 1, when the trajectory fails to reach goal-1.
C. Additional visualizations from demonstration dataset
The demonstration visualizations cover five environments and multiple STL task types, while the dataset contains 200K specifications paired with 400K trajectories.
- The dataset contains 200K STLs and 400K trajectories, obtained by randomly selecting two demonstrations per STL for each benchmark.
- Linear environment: In the Linear environment, demonstrations begin from eight initial locations with eight random control sequences per location, retaining trajectories that satisfy the STL.
- Demonstration visualizations span Linear, Dubins, PointMaze, AntMaze, and Franka Panda environments.
- The visualizations include single-goal, multi-goal, sequential, and partial STL tasks across the environments.
- Dubins environment: Dubins demonstrations are more diverse and change substantially over time because of large angular velocity and acceleration rate.
- Additional figures show collected demonstration trajectories for the Linear, Dubins, PointMaze, AntMaze, and Franka Panda settings.