Testing Deep Learning Libraries via Neurosymbolic Constraint Learning
M M Abid Naziri, Shinhae Kim, Feiran Qin, Marcelo d'Amorim, and Saikat Dutta

TL;DR
This paper introduces Centaur, a neurosymbolic testing approach that learns API constraints from seed inputs to generate valid test cases, significantly improving bug detection in deep learning libraries like PyTorch and TensorFlow.
Contribution
Centaur is the first technique to learn formal API constraints using a neurosymbolic approach with LLMs and SMT solvers, enhancing testing accuracy and coverage for DL libraries.
Findings
Achieves 94% recall and precision in constraint learning.
Covers significantly more branches than existing tools.
Detects 26 new bugs in popular DL libraries.
Abstract
Deep Learning (DL) libraries (e.g., PyTorch) are popular in AI development. These libraries are complex and contain bugs. Researchers have proposed various bug-finding techniques for such libraries. Yet, there is much room for improvement. A key challenge in testing DL libraries is the lack of API specifications. Prior testing approaches often inaccurately model the input specifications of DL APIs, resulting in missed valid inputs that could reveal bugs or false alarms due to invalid inputs. To address this challenge, we develop Centaur -- the first neurosymbolic technique to test DL library APIs using dynamically learned input constraints. Centaur leverages the key idea that formal API constraints can be learned from a small number of automatically generated seed inputs, and that the learned constraints can be solved using SMT solvers to generate valid and diverse test inputs. We…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsAdversarial Robustness in Machine Learning · Software Testing and Debugging Techniques · Software Engineering Research
