TL;DR
This paper introduces Embedding Temporal Logic (ETL), a novel framework that performs runtime safety and behavioral monitoring of perception-based autonomous systems directly within learned embedding spaces. By evaluating temporal logic predicates based on geometric distances to reference target embeddings rather than relying on brittle intermediate classifiers, ETL achieves high semantic accuracy. Furthermore, it incorporates a conformal prediction calibration method to provide rigorous, safety-oriented recall guarantees.
What Problem Does This Paper Address?
As autonomous systems (like self-driving cars and robotic manipulators) increasingly rely on deep learning for perception, they process high-dimensional sensor streams (e.g., camera images) into compact latent representations or embeddings.
Traditional runtime monitoring frameworks, such as Signal Temporal Logic (STL), ensure safety by checking if a system's execution satisfies formal rules. However, STL requires low-dimensional, explicit state variables (like exact object coordinates or velocities). To bridge the gap between raw images and these symbolic states, engineers must train ad-hoc perception modules (e.g., a classifier to detect if a gripper is "holding an object").
These intermediate modules introduce several critical flaws:
- Brittleness and Errors: They introduce new points of failure and calibration errors.
- Inflexibility: If the safety specification changes (e.g., adding a rule about "dropping an object"), engineers must train entirely new classifiers.
- Semantic Mismatch: There is a fundamental misalignment between the continuous latent spaces where modern policies operate and the discrete symbolic states required by traditional logic.
This paper tackles the challenge of formally monitoring autonomous systems directly on high-dimensional visual inputs without explicit state estimation or custom classifiers.
Methods
The authors propose Embedding Temporal Logic (ETL), which shifts the evaluation of temporal logic from explicit state spaces to learned embedding spaces.
1. Embedding Predicates
Instead of evaluating a boolean proposition like $x_{obstacle} < 0.5$, ETL defines predicates using geometric distances in a latent space. A user defines a visual concept by providing a set of Target Images ($O_G$). These targets are passed through a pretrained vision encoder to generate target embeddings ($Z_{target}$). At runtime, the distance between the current observation embedding ($z_t$) and the closest target embedding is evaluated against a threshold ($\epsilon$):
$$\delta_{ap}(z_t) = \min_{z_g \in Z_{target}} d(z_t, z_g) \le \epsilon$$
By combining these predicates with standard temporal operators (such as Always $\mathbf{G}$, Eventually $\mathbf{F}$, and Until $\mathbf{U}$), ETL can express complex, sequential behaviors.
2. Threshold Calibration
The choice of the threshold $\epsilon$ is critical. The authors propose two data-driven calibration methods using a small held-out dataset:
- F1-Optimal Threshold: Searches for an $\epsilon$ that balances false positives and false negatives by maximizing the F1 score against ground-truth labels.
- Conformal Threshold with Recall Guarantee: Adapts split conformal prediction to provide a statistical guarantee. Given a user-specified error tolerance $\alpha$, it ensures that the monitor will achieve perfect recall (never missing a true positive event, such as a safety violation) on a new trajectory with a probability of at least $1 - \alpha$.
Datasets
The authors evaluated ETL across three distinct domains:
- Simple Navigation Dubins Car: A simulated 2D navigation task where a robot must reach goals and avoid obstacles. It uses a Dreamer-based world model encoder.
- Simulated Manipulation Tasks:
- D3IL Benchmark: Complex robotic tasks including
SORTING(pushing blocks into color-matched boxes) andSTACKING(arranging blocks). - MetaWorld: Pick-and-place robotic arm tasks (
mw-pick-place-wall) requiring sequential grasping and placing. - Real-World Evaluation via DROID: A large-scale, in-the-wild robot manipulation dataset. The authors used a video diffusion model encoder (SVD VAE from Ctrl-World) trained directly on DROID data.
Key Insights and Ideas
- Leveraging Pretrained Geometry: Pretrained vision models (like DINOv2 or CLIP) inherently structure their latent spaces such that semantically similar scenes are geometrically close. ETL exploits this native structure as a zero-shot or few-shot specification tool.
- Specification by Example: Instead of writing complex code to define a state, an engineer can specify a safety region or goal simply by providing reference images (e.g., "avoid states that look like this image of fire").
- Distribution-Free Safety Guarantees: Applying conformal prediction to temporal logic allows the system to guarantee high recall without making restrictive assumptions about the underlying distribution of the embedding distances.
Key Results
ETL demonstrated strong alignment with ground-truth semantics and outperformed existing embedding-based and vision-language baselines.
- Dubins Car Navigation: ETL predicates closely matched state-based events, achieving F1 scores between 0.80 and 0.85 and over 96% trajectory-level agreement. Conformal calibration successfully increased recall from 0.83 to 0.93.
- Simulated Manipulation: Across Stacking, Sorting, and Pick-and-Place tasks, ETL achieved the highest average F1 score (0.817) compared to density-based (
logpZO, 0.790) and clustering-based (PCA-kmeans, 0.751) baselines. - Real-World Robot Data (DROID): When monitoring multi-phase manipulation tasks, ETL significantly outperformed a state-of-the-art Vision-Language Model baseline (Qwen2-VL-2B). ETL achieved a mean F1 score of 0.813 and 94% phase agreement, compared to Qwen2-VL's 0.390 F1 score and 56.7% agreement. It also correctly tracked sequential phase ordering in 4 out of 5 real-world episodes.
Limitations and Future Work
Despite its strong performance, the authors note two primary limitations:
- Interpretability: Because the predicates are defined as distances in a high-dimensional latent space, they lack human-understandable explanations (i.e., it is hard to know exactly why an embedding is far from the target).
- Representation Dependency: ETL's performance is strictly bound to the quality of the encoder. If the encoder maps distinct semantic phases into overlapping regions of the latent space, the monitor's accuracy degrades.
Future research directions include developing transparent predicate explanations, exploring online adaptive thresholding, and optimizing encoder selection to enforce better semantic separation.
Summary updated