TRANSMISSION // 2611.17866v2
Teaching a Learner to Turn Examples into Rules About Time
Source published
A new framework learns temporal-logic rules from labelled traces and informal hints. Tests on simulated tasks show promise, but also expose limits around search size, incorrect hints and real users.

Formal rules can describe how events should unfold, but writing them requires specialist knowledge. Rajarshi Roy and Xiaowei Huang propose a learner that asks people to label example sequences and, optionally, explain what seems wrong in ordinary language.
The challenge: describing behaviour over time
A rule for a robot, software system or agent often needs to say more than what should happen: it must specify when events happen and how they relate. For example, a delivery robot might be required to deliver an object after picking it up, without picking up another object first. Such requirements can be written in linear temporal logic on finite traces (LTLf), a formal language for describing sequences of events. But translating an everyday intention into a precise formula can be difficult, especially for people without training in formal methods.
The paper, Active Learning of Temporal Specifications through Distinguishing Queries, asks whether a computer can learn these rules through a more approachable exchange. Instead of asking a person to judge whether a proposed formula is fully equivalent to their intention or to construct a technical counterexample, the learner asks them to label example traces: sequences of events that are either acceptable or unacceptable.
How the learner narrows the possibilities
The system keeps a “version space”: a collection of candidate formulas that agree with all the labels received so far. It chooses two candidates that disagree and finds a trace on which their predictions differ. The teacher labels that trace, ruling out candidates that conflict with the answer. If no trace can distinguish two formulas, the system treats them as equivalent within the trace setting being considered.
The learner can also ask optional questions in natural language. A person might identify a mismatch as a missing event or an ordering problem, then describe a partial requirement, such as “every pickup must eventually be followed by a delivery.” The framework uses such hints to rank candidates or, in a more aggressive mode, restrict which candidates it searches first. The authors assume that a more detailed hint has already been translated into a formula; they do not evaluate whether an AI system can translate such language reliably.
The researchers implemented the approach with grammar-based formula enumeration, and also compared it with a SAT-based way of representing candidates. They tested it using a simulated teacher that labels traces according to known target formulas. The evaluation covered 36 targets: 20 over unrestricted event sequences and 16 in four configurations drawn from Office world, Taxi and MiniGrid DoorKey. The initial sample contained 10 labelled traces. The search was limited to formulas within a specified size and temporal-depth range; in these experiments, the size limit was set using the target’s size plus one.
What the tests showed
When the learner compared all remaining candidates, it identified every benchmark target: either exactly on unrestricted traces or as equivalent on all feasible traces in an environment. With the default candidate order, it used an average of 16.2 labelled traces for unrestricted tasks and 12.5 for environment tasks, including the 10 initial examples. These are results on the tested targets, not a guarantee that the system can learn any rule from any collection of examples.
Stopping early after comparing only a shortlist was less reliable. Depending on the ordering strategy, the shortlist approach succeeded in 64 to 100 of 100 unrestricted runs and 40 to 64 of 80 environment runs. In some cases, it stopped despite distinguishable candidates remaining. This illustrates a practical trade-off: comparing everything can support identification under the paper’s assumptions, but quick stopping can leave the learner with the wrong rule.
Correct hints sometimes made the search more efficient. In the reported experiments, hint-based pruning cut the average number of labelled queries by up to 16% and reduced the number of generated candidates by about a fifth. But pruning based on an incorrect hint could exclude the target: exhaustive identification then succeeded in only 74 of 100 unrestricted runs with incorrect Level-1 hints, and 43 of 80 environment runs. Incorrect hints used only to rank candidates did not prevent identification in these tests, though they could affect which questions were asked.
The enumeration-based method was faster than the SAT-based version-space implementation at every tested target size. For size-7 targets, the reported mean times were 8.82 seconds and 22.35 seconds, respectively, in the comparison setup. That advantage came with a memory cost as the search expanded: a run with a larger size bound generated 31.4 million formulas and used 3.4 GB of memory. The authors also note that a SAT-based approach may use less memory in some settings.
What remains uncertain
These are controlled experiments with a simulated, consistent teacher—not a study of people using the tool. The authors identify human users, noisy labels, automatic translation of hints and learning without a known size bound as future work. The method’s guarantees also depend on conditions such as the target being within the searched formula class and the distinguishing procedure finding relevant traces. In an environment, two formulas may differ in theory yet be indistinguishable on feasible executions; the result then establishes equivalence only within that environment.
The work is available as an arXiv preprint, so its claims should be read as research results rather than settled evidence. Its central contribution is a structured way to turn examples and partial explanations into candidate temporal rules. Whether that interaction is genuinely easier—or dependable enough for real verification and monitoring—still needs testing with human users and broader tasks.
- active learning
- temporal logic
- formal methods
- LTLf
- specification learning
- verification
Related reading
Automatically matched by shared topic keywords. These links do not imply that the sources agree or establish a consensus.
A classifier translates robot instructions into temporal logic
Source published
Shared keywords: formal methods
Teaching AI teams to react to adversaries with logic
Source published
Shared keywords: formal methods
One mathematical representation for quantum loops
Source published
Shared keywords: formal methods
Verifying the Verifier: Safer Neural Network Checks
Source published
Shared keywords: formal methods
Why AI-written chip repairs need more than a passing test
Source published
Shared keywords: formal methods