Skip to content
Preprint

Withholding the Completing Chunk: Exact Release-Boundary Equivalence for Production Streaming Guardrails

Aug 2026 · 0 citations · 17 references
Computer Science

TL;DR

This work studies a production policy in which each ordered family is the conjunction of two regular-language predicates, and shows that the resulting monitor is release-boundary equivalent to an absorbing cumulative oracle for every policy in the declared grammar.

Abstract

Streaming language-model output creates an enforcement boundary: a control that detects a prohibited pattern after releasing its completing chunk cannot recall it. We study a production policy in which each ordered family is the conjunction of two regular-language predicates. Incremental matching is classical. The problem is exact composition at release time across arbitrary chunk partitions, including end-of-prefix word boundaries that can change on extension. We define an ASCII-explicit policy grammar, compile each predicate to a persistent nondeterministic finite automaton (NFA), distinguish stable from provisional assertion state, apply document-order family priority, and check the decision before releasing each chunk. We show that the resulting monitor is release-boundary equivalent to an absorbing cumulative oracle for every policy in the declared grammar. Production Python and TypeScript implementations were evaluated on 101,653 partitioned cases; a public surrogate added 100,345 cases. Both campaigns produced zero oracle, cross-runtime, or intended-family mismatches. In a frozen neutral-output profile, the memoized incremental and native-regex cumulative slopes at 64-character chunks were 0.973 and 1.976. At 16,384 characters the incremental median was 30.2 ms versus 96.6 ms for native cumulative scanning at that chunk size. Native regex remained faster at 512-character chunks (12.4 versus 29.4 ms), exposing the constant-factor crossover rather than hiding it. A shared per-stream cache cap and 129-symbol alphabet bound optimization state; the campaign peaked at 364 of 4,096 without bypass. The result is policy conformance for a deterministic backstop, not evidence of semantic safety or policy completeness.

View source

Similar papers

Jul 2026

GRID: Grammar-Railed Decoding for Enterprise SQL Generation

This work presents GRID (Grammar-Railed Decoding), a grammar-constrained decoding engine that keys exact next-token masks on parser configurations rather than on token sequences, and uses the incrementally advanced LALR(1) parser itself as a viable-prefix oracle.

Mohsen Arjmandi · 0 citations
Jul 2026

IFHierBench: Hierarchical Instruction Following for Large Language Models

IFHierBench is introduced, a hierarchical instruction-following benchmark of 600 prompts stratified across four constraint-tree depths and 35 distinct constraints, each prompt paired with a deterministic checker that verifies satisfaction at every scope.

Yuetian Mao, Chunyang Chen · 0 citations
Preprint Aug 2026

Failure-Aware Long-Form Translation: Design and Implementation of a Recoverable LLM Translation System

A recovery protocol developed for a deployed translation system with heterogeneous inputs and provider APIs is described, which delays the first visible release behind a 64-character window, validates the assembled output, and uses typed stream events to distinguish replacement from continuation.

Yanling Yu · 0 citations
Jul 2026

Ultrametric Convergence of Guarded Automata and Applications to Structural Input Validation

This work equips language-equivalence classes of deterministic finite automata with a distinguishing-word ultrametric and identifies the resulting space isometrically with the regular languages, and outlines a practical WAF pipeline combining learned grammar models, finite-state construction, and \(O(1)\)-memory runtim...

A. Ilchev, Hristo Kiskinov, G. Pashev et al. · 1 citation

We use cookies to run the site and, with your consent, for analytics and to show ads. See our Cookie Policy.