Faithful Autoformalization of Natural Language Assertions

작성자

카테고리:

← 피드로
arXiv cs.AI · Hongyi Liu, Madhusudan Parthasarathy, Adithya Murali · 2026-07-20 AI

[Submitted on 14 Jul 2026 (v1), last revised 16 Jul 2026 (this version, v2)]

View PDF HTML (experimental)

Abstract:Formal contracts are essential for software testing and verification, yet writing them remains labor-intensive and error-prone. LLMs offer a promising path toward autoformalization: synthesizing executable assertions from natural-language specifications and thereby bridging the gap between informal developer intent and formal executable specifications. We present Monty: an autoformalization framework for assertions that tackles the challenges of expectations of validity of assertions and ambiguity in natural-language. Our techniques are based on filtering formalizations using a novel conformance score metric and validity scores obtained from testing the code against formalized assertions. We evaluate our approach on 541 assertion-generation tasks derived from 22 collection-like Java classes, and show that our technique produces the ground truth more reliably (improving upto 20 points in precision on average) than when using LLMs naively to translate assertions.

Submission history

From: Hongyi Liu [view email]
[v1] Tue, 14 Jul 2026 22:12:14 UTC (165 KB)
[v2] Thu, 16 Jul 2026 21:38:03 UTC (165 KB)

원문에서 계속 ↗

추출 본문 · 출처: arxiv.org · https://arxiv.org/abs/2607.13303

코멘트

답글 남기기

이메일 주소는 공개되지 않습니다. 필수 필드는 *로 표시됩니다