← Lab /Software

AutoSpec boosts safety rule F1 to 0.98/0.93 and cuts false positives by up to 94%

AutoSpec can automatically evolve interpretable safety rules that achieve high precision/recall on LLM agents

Software arXiv 23 Jun 2026 Method Prototype evidence

Published as “AutoSpec: Safety Rule Evolution for LLM Agents via Inductive Logic Programming”

Why it matters

The method enables production LLM agents to keep their safety guardrails up-to-date without sacrificing interpretability, reducing operational false alarms and missed hazards.

Summary

AutoSpec evolves existing expert safety rules for LLM agents using ILP-guided CEGIS, raising rule F1 to 0.98 on code-execution traces and 0.93 on embodied-agent traces while cutting false positives by up to 94 % and converging in 4-5 iterations. The improvement over a heuristic CEGIS baseline is up to 4.8× higher F1. Evidence comes from 291 manually labeled traces across two domains, compared against expert rules, a neural classifier, heuristic CEGIS, and random search. The paper notes that evaluation is limited to two domains and that labels rely on human annotation.

What they found 4

  1. AutoSpec raises rule F1 to 0.98 and 0.93 across two domains with up to 94% false-positive reduction

    “AutoSpec raises rule F1 to 0.98 and 0.93 across the two domains, achieving up to 94% false positive reduction while maintaining high recall, and converges within 4-5 iterations.”

  2. ILP guidance yields up to 4.8× higher F1 than heuristic CEGIS

    “The ILP-guided approach achieves up to 4.8× higher F1 than heuristic CEGIS.”

  3. In code execution, AutoSpec achieves precision 0.960, recall 1.000, F1 0.980 with 2 false positives and 0 false negatives

    “AutoSpec (Ours) 0.960 1.000 0.980 2/0”

  4. In embodied agents, AutoSpec achieves precision 0.925, recall 0.942, F1 0.933 with 4 false positives and 3 false negatives

    “AutoSpec (Ours) 0.925 0.942 0.933 4/3”

Caveats 3

  • In the embodied-agent domain AutoSpec still produces 4 false positives and 3 false negatives, indicating recall is not perfect despite the headline claim of high recall
  • Our evaluation spans two domains, code execution and embodied agents, covering diverse safety properties; other settings such as web or database agents remain to be explored.
  • Labels rely on human annotation.

What’s new here 3

  • Automatically refines deployed expert safety rules using user annotations rather than building new classifiers
  • Integrates ILP to prioritize discriminating predicates, dramatically pruning the exponential rule-edit search space
  • Achieves near-optimal F1 with far fewer false positives while preserving rule interpretability