mlsanityData to 7 Oct 2026

BODHI: Precise OS Kernel Specification Inference

arXiv 2605.23931 ↗First posted 22 Apr 2026cs.AI cs.PL cs.SEcited by 0

Not on the map. Why?

Abstract (arXiv)

The formal verification of operating system kernels requires precise specifications that capture the intended behavior of system calls. Writing these specifications manually demands deep domain expertise, motivating the use of large language models (LLMs) to automate the process. However, in OSV-Bench, a benchmark of 245 specification generation tasks derived from the Hyperkernel OS kernel, the best reported Pass@1 is 55.10%. We propose a domain knowledge prompting method (BODHI), which augments the standard few-shot prompt with a structured C-to-Python translation guide covering 15 categories of domain-specific translation patterns. Inspired by Structured Chain-of-Thought (SCoT) prompting, the guide organizes translation by separation of concerns, addressing pre-condition extraction and post-condition generation as distinct categories. Evaluated on nine models from six providers (Anthropic, Mistral, Amazon, DeepSeek, Meta, Alibaba), covering dense, mixture-of-experts and reasoning architectures, BODHI improves every model tested, with gains ranging from +11% to +32%. The best configuration (Claude Opus 4.6 + BODHI) reaches 96.73% Pass@1. BODHI reduces both syntax and semantic errors, with the strongest effect on models that have sufficient instruction-following capability to utilize structured reference material. These results demonstrate that domain knowledge injection is a model-agnostic technique that substantially bridges the gap between general-purpose code generation and formal specification synthesis.

Key facts. No citing papers in the map yet (data through 7 Oct 2026). Builds on 16 of its 23 references that are in the map. First posted on arXiv 22 Apr 2026.

Builds on

16 of 23 references.

References · 16

  1. 2022Chain-of-Thought Prompting Elicits Reasoning in Large Language Modelscited by 12,302
  2. 2020Retrieval-Augmented Generation for Knowledge-Intensive NLP Taskscited by 9,160
  3. 2021Program Synthesis with Large Language Modelscited by 3,509
  4. 2023Lost in the Middle: How Language Models Use Long Contextscited by 3,383
  5. 2024A Survey on Large Language Models for Code Generationcited by 646
  6. 2023Structured Chain-of-Thought Prompting for Code Generationcited by 136
  7. 2023Baldur: Whole-Proof Generation and Repair with Large Language Modelscited by 118
  8. 2024IRIS: LLM-Assisted Static Analysis for Detecting Security Vulnerabilitiescited by 100
  9. 2023Scallop: A Language for Neurosymbolic Programmingcited by 63
  10. 2024SpecGen: Automated Generation of Formal Program Specifications via Large Language Modelscited by 51
  11. 2025When LLMs Meet API Documentation: Can Retrieval Augmentation Aid Code Generation Just as It Helps Developers?cited by 12
  12. 2025OSVBench: Benchmarking LLMs on Specification Generation Tasks for Operating System Verificationcited by 8
4 more
  1. 2025Locus: Agentic Predicate Synthesis for Directed Fuzzingcited by 8
  2. 2024Relational Programming with Foundation Modelscited by 7
  3. 2025QLCoder: A Query Synthesizer For Static Analysis of Security Vulnerabilitiescited by 7
  4. 2025Lobster: A GPU-Accelerated Framework for Neurosymbolic Programmingcited by 4

Built on by

Not cited yet.

Similar, not cited

Close in wording, no citation either way

  1. 2025AssertCoder: LLM-Based Assertion Generation via Multimodal Specification Extraction
  2. 2026SyzHarness: Patch-Based Kernel Bug Reproduction with LLM-Synthesized Fuzzing Harnesses
  3. 2026FVRuleLearner: Operator-Level Reasoning Tree (Op-Tree)-Based Rules Learning for Formal Verification
  4. 2026Kernel Contracts: A Specification Language for ML Kernel Correctness Across Heterogeneous Silicon
  5. 2024Learning to Estimate System Specifications in Linear Temporal Logic using Transformers and Mamba
  6. 2026Don't Regenerate, Debug: A Domain-Specific Agent for Repairing Near-Miss Hardware Operators
  7. 2026Fine-Tuning Qwen3-27B for C-to-Rust Code Translation: A Three-Stage Curriculum of Pretraining, Debugging-Aware SFT, and Task-Specific SFT
  8. 2025SysVCoder: An LLM-Driven Framework for Systematic Generation of System-Level Design