Reversible Grammars for Unified Parsing and Generation

325 concepts199 papers1 proposal

In traditional natural language processing, understanding text (parsing) and producing text (generation) are often treated as separate, isolated tasks. A system designed to parse a sentence into a semantic representation requires one architecture, while a system designed to generate a sentence from that same representation requires another.

This decoupling introduces massive redundancy. If a system knows that a specific syntactic structure maps to a specific meaning, it should inherently know how to traverse that mapping in reverse. Reversible grammar architectures solve this by treating parsing and generation as symmetric processes governed by a single, shared linguistic ruleset.

Framing Generation as Parsing

How can a single computational interpreter operate in both directions? The key intuition lies in reframing how we view the input to a language system.

As Kay demonstrated in Chart Generation, natural language generation can be treated as a parsing task over semantic constraints rather than a sequence of words. In traditional parsing, the input is an ordered string of words, and a chart data structure organizes them into a hierarchical meaning representation. In generation, the input is an unordered set of semantic primitives. By utilizing the same chart data structure and agenda-based processing, the system can search for a surface string that satisfies these semantic constraints using the exact same grammar rules.

This symmetry allows a single engine to translate between linear surface strings and deep semantic structures bidirectionally, eliminating the need for redundant, task-specific dictionaries or separate architectures.

Declarative Knowledge and Monotonicity

For a grammar to be truly reversible, its underlying representations cannot rely on destructive, step-by-step procedural transformations. Instead, the linguistic knowledge must be strictly declarative and monotonic.

As Alshawi et al. argue in Monotonic Semantic Interpretation, the mapping between syntax and semantics must be monotonic—meaning information is progressively accumulated rather than deleted or overwritten during processing. When the logical representation preserves the original linguistic features, the functional boundary between comprehension and production disappears.

This declarative approach ensures linguistic consistency across bidirectional tasks. In machine translation frameworks like CRITTER, developed by Isabelle et al., a single set of declarative rules forces the system to act as its own quality filter: any structure the system is capable of parsing and understanding, it is inherently capable of generating in the target language.

Symmetry Across the Linguistic Stack

The principle of bidirectional reversibility operates uniformly across every level of language processing, from low-level phonology to high-level pragmatics.

Phonology and Morphology

At the word level, Koskenniemi demonstrated in Two-Level Model for Morphological Analysis that implementing linguistic rules as finite-state automata enables inherent bi-directionality. Because finite-state machinery can be traversed forward or backward with equal efficiency, the same underlying logic decomposes complex inflected words into base forms (analysis) or synthesizes surface forms from roots (generation).

Similarly, Meng et al. applied this dual-layer logic to speech systems. By treating the terminal nodes of a parse tree as a dual-layer of distinct representations—phonemes and graphemes—a single model can perform both letter-to-sound synthesis and sound-to-letter recognition.

Pragmatics and Dialogue

In conversation, an agent must constantly switch roles between speaker and listener while maintaining a consistent understanding of the dialogue state. Green et al. showed that a unified, plan-based framework can use the same discourse operators and pragmatic knowledge for both interpreting indirect user input and generating system responses.

The social and contextual rules an agent uses to decode a user's underlying intent are the exact same rules it applies to formulate its own polite or contextually appropriate replies. As noted by Williams, this bidirectional alignment ensures that an agent's communicative behavior remains internally consistent.

Why It Works: The Cognitive Synergy

Beyond reducing engineering overhead and eliminating redundant codebases, coupling comprehension and generation provides a powerful cognitive synergy. When a system's interpretive capabilities are perfectly aligned with its expressive capabilities, any improvement made to its understanding of language automatically enhances its production of language.

While early computational linguistics explored this through symbolic, rule-based systems, modern neural architectures are beginning to leverage the same underlying insight. For example, Gul et al. demonstrate in CoGen: Learning from Feedback with Coupled Comprehension and Generation that language models learn significantly more effectively from human feedback when their comprehension and generation pathways are tightly coupled during joint inference. By treating understanding and production as two sides of the same coin, models can leverage their internal reasoning about intent to drastically improve real-time communicative accuracy.

History & citationVersion 2 · 2026-10-04

Current · Permanent link

  1. Version 2 (latest) · 2026-10-04 · 188 papers
  2. Version 1 · 2026-10-04 · 169 papers
Cite this direction

Latest version (a living page):

@misc{lacuna_bidirectional_linguistic_modeling_8ee6173d,
  title = {bidirectional linguistic modeling},
  author = {{Lacuna}},
  howpublished = {Lacuna research direction},
  year = {2026},
  url = {https://lacuna.tiptreesystems.com/direction/bidirectional-linguistic-modeling/rdr_8ee6173dca994e3db519906ab77d4f4d},
  note = {Latest version of a living research direction; cite a version for a fixed text. Accessed 2026-11-19},
}

This exact version (version 2, frozen text):

@misc{lacuna_bidirectional_linguistic_modeling_8ee6173d_v2,
  title = {bidirectional linguistic modeling},
  author = {{Lacuna}},
  howpublished = {Lacuna research direction},
  year = {2026},
  url = {https://lacuna.tiptreesystems.com/direction/bidirectional-linguistic-modeling/rdr_8ee6173dca994e3db519906ab77d4f4d/v/2},
  note = {Version 2, frozen 2026-10-04. Accessed 2026-11-19},
}
About

These directions overlap with this one through shared papers.

See something wrong? Report a mistake