Projectional Decoding: Towards Semantic-Aware LLM Generation

Fuente: arXiv
Enregistré dans:
Détails bibliographiques
Auteurs principaux: Chen, Boqi, López, José Antonio Hernández, Babikian, Aren A.
Format: Preprint
Publié: 2026
Sujets:
Accès en ligne:
Tags: Ajouter un tag
Pas de tags, Soyez le premier à ajouter un tag!
_version_ 1866916061591371776
author Chen, Boqi
López, José Antonio Hernández
Babikian, Aren A.
author_facet Chen, Boqi
López, José Antonio Hernández
Babikian, Aren A.
contents Large language models (LLMs) are increasingly used to generate software artifacts across many software engineering (SE) tasks, yet ensuring the semantic validity of these artifacts remains a fundamental challenge. Existing constrained decoding techniques can enforce syntactic correctness and, in some cases, specific semantic rules, but lack a general representation that bridges LLM-generated text with the reasoning required for semantic validation in SE. In this paper, we propose projectional decoding, a novel conceptual framework that integrates domain semantics directly into the generation process by maintaining, alongside text, a partial graph model as the primary artifact representation throughout generation. This abstract representation enables incremental semantic validation by explicitly capturing uncertainty and natively supporting error detection, while guiding generation toward semantically valid outputs with provable guarantees. We present preliminary results on a program generation task which demonstrate the potential of this approach to improve the semantic validity of LLM-generated artifacts. We also discuss how projectional decoding can enable verifiable automation with LLMs across various SE activities.
format Preprint
id arxiv_https___arxiv_org_abs_2605_30054
institution arXiv
publishDate 2026
record_format arxiv
spellingShingle Projectional Decoding: Towards Semantic-Aware LLM Generation
Chen, Boqi
López, José Antonio Hernández
Babikian, Aren A.
Software Engineering
Artificial Intelligence
Large language models (LLMs) are increasingly used to generate software artifacts across many software engineering (SE) tasks, yet ensuring the semantic validity of these artifacts remains a fundamental challenge. Existing constrained decoding techniques can enforce syntactic correctness and, in some cases, specific semantic rules, but lack a general representation that bridges LLM-generated text with the reasoning required for semantic validation in SE. In this paper, we propose projectional decoding, a novel conceptual framework that integrates domain semantics directly into the generation process by maintaining, alongside text, a partial graph model as the primary artifact representation throughout generation. This abstract representation enables incremental semantic validation by explicitly capturing uncertainty and natively supporting error detection, while guiding generation toward semantically valid outputs with provable guarantees. We present preliminary results on a program generation task which demonstrate the potential of this approach to improve the semantic validity of LLM-generated artifacts. We also discuss how projectional decoding can enable verifiable automation with LLMs across various SE activities.
title Projectional Decoding: Towards Semantic-Aware LLM Generation
topic Software Engineering
Artificial Intelligence
url https://arxiv.org/abs/2605.30054