{"version":1,"type":"story","url":"https://digestai.news/story/llm-generated-acsl-contracts-for-numerical-libraries","json":"https://digestai.news/story/llm-generated-acsl-contracts-for-numerical-libraries.json","markdown":"https://digestai.news/story/llm-generated-acsl-contracts-for-numerical-libraries.md","slug":"llm-generated-acsl-contracts-for-numerical-libraries","headline":"LLM-generated ACSL contracts for numerical libraries","summary":"A new approach uses large language models (LLMs) to automatically generate a small, human-certifiable Automated C Specification Language (ACSL) contract from function documentation. This combined with a deterministic toolchain that supports a restricted ACSL profile and generates a driver using the CIVL verifier checks the implementation against the contract and an existing reference model. The pipeline was demonstrated on three PETSc functions: MatAXPY, MatAYPX, and the non-compressing mode of MatFilter. This approach discovered a previously undiscovered bug in MatAYPX that has been present since 1997.","keyPoints":["LLM-generated ACSL contracts for numerical libraries","Demonstrated on three PETSc functions: MatAXPY, MatAYPX, and non-compressing mode of MatFilter","Discovered a previously undiscovered bug in MatAYPX since 1997"],"whyItMatters":"This approach could potentially automate the process of generating ACSL contracts for numerical libraries, which can help reduce bugs and improve the reliability of scientific applications.","category":{"slug":"research","name":"Research","url":"https://digestai.news/category/research"},"entities":{"companies":["PETSc"],"models":[],"people":[]},"firstPublishedAt":"2026-09-29T04:00:00Z","updatedAt":"2026-09-29T04:00:00Z","sourceCount":1,"hasPrimarySource":true,"sources":[{"outlet":"arXiv cs.CL","title":"Verification of PETSc with CIVL using LLM-generated ACSL contracts and deterministic driver generation","url":"https://arxiv.org/abs/2609.31687","publishedAt":"2026-09-29T04:00:00Z","type":"primary","primary":true,"lead":true}],"sourceNotes":null,"discussions":[],"thread":null,"cite":{"text":"Digest AI, \"LLM-generated ACSL contracts for numerical libraries\", 29 September 2026, https://digestai.news/story/llm-generated-acsl-contracts-for-numerical-libraries","publisher":"Digest AI","title":"LLM-generated ACSL contracts for numerical libraries","datePublished":"2026-09-29T04:00:00Z","url":"https://digestai.news/story/llm-generated-acsl-contracts-for-numerical-libraries"},"generatedBy":"Written by Digest AI's editorial model from the linked sources; the sources are the record.","license":"Headlines, digests and key points are written by Digest AI and may be quoted with a link to the story page. Linked articles belong to their publishers. Terms: https://digestai.news/terms#reuse"}