arXiv:2610.10933cs.LGOct 2026

Manuscript Offprint

arXiv:2610.10933

Rethinking the Tradeoff Between Temporal Encoding and Nonlinear Computation in Spiking Language Models

Hanfei Liu, Shuchang Feng, Yanxia Chen, Changzeng Fu, Shiqi Zhao

Abstract

Spiking language models face a tradeoff between representing continuous semantic features over short temporal windows and retaining costly nonlinear attention operations. We introduce Spora, which jointly designs spike encodings and attention operators. Binary temporal weights let T spikes represent compositional values with up to T bits of capacity, compared with O(log⁡2T)O(\log_2 T) bits for spike-count readout. Unipolar Binary Spiking (UBS) uses thresholds and spike-triggered residual decay to produce non-negative integer codes; Bipolar Binary Spiking (BBS) separates sign and magnitude and learns a scale for signed activations. These representations support accumulation-and-shift dot products and integer-exponent mappings in attention. With four time steps, Spora achieves 76.6 average GLUE score and 44.1 CoLA MCC, improving over SpikeLM by 1.2 and 6.2 points, respectively. Extending BBS to six steps raises these scores to 78.2 and 47.4. Conditional-decay analysis, matched-budget activation-quantization comparisons, event-workload statistics, and fixed-point evaluation further characterize the connection between encoding fidelity and computational cost.

Keywords: Spiking neural networks ; Language model ; Temporal encoding ; Approximate attention

1 Introduction

Spiking Neural Networks (SNNs) process information through discrete events and membrane-potential dynamics inspired by biological neurons (Mehonic and Kenyon, 2022; Zhang et al., 2020; Maass, 1997). Their sparse communication and event-driven computation offer a route to energy-efficient neural processing (Li et al., 2021). Recent advances in spiking vision (Wu et al., 2022; Hu et al., 2023), particularly Transformer-based architectures (Vaswani et al., 2017; Zhou et al., 2023a,b; Li et al., 2024; Yao et al., 2023), have achieved competitive performance with four or fewer time steps.

Motivated by the generalization capabilities of large-scale language models (Du et al., 2022), SpikeLM (Xing et al., 2024) and SpikeGPT (Zhu et al., 2023) demonstrate the feasibility of spike-driven language processing. Language representations, however, are dense, signed, and context-dependent. Transformer predictions depend on both the precision of these features and their inter-

∗^{*}Corresponding author.

Preprint.

(a) Rate coding

Figure

(b) TTFS coding

(c) Rank-order coding

(d) Few-Spike coding

Figure

(e) UBS (Spora)

(f) BBS (Spora)

Figure 1: Spike encodings: (a) rate, (b) TTFS, (c) rank-order, (d) Few-Spike, (e) UBS, and (f) BBS. Event labels denote readout weights; BBS traces show separate positive and negative inputs.

actions through attention. Mapping continuous activations into short spike sequences can therefore affect not only individual feature values but also the attention distributions that combine information across tokens.

Existing spiking language models approach this problem from two directions. Models that introduce spikes into selected linear modules retain floating-point Softmax to preserve attention fidelity (Xing et al., 2024). Hardware-oriented alternatives replace nonlinear operations with approximations (Tang et al., 2025; Zhou et al., 2026), while temporal budgets remain important for representation precision. Increasing the number of steps provides more encoding opportunities but also increases temporal processing. Although these two categories differ in implementation, they face the same fundamental challenge: preserving fine-grained semantic information within a short temporal window while avoiding costly nonlinear attention computation.

Figure 1 illustrates the relevant encoding choices. Rate coding counts events, TTFS uses first-spike latency (Yu et al., 2023), and rank-order coding uses relative firing order across neurons (Rufin Van Rullen, 2001). Weighted-spike and Few-Spike methods assign numerical readout weights to temporal events (Kim et al., 2018; Stöckl and Maass, 2021). Our approach uses binary place values: an event's time index identifies its numerical contribution. Unlike a spike-count estimate, this readout forms an integer operand that can enter subsequent arithmetic directly.

Following this principle, Spora combines Unipolar Binary Spiking (UBS) and Bipolar Binary Spiking (BBS) encodings. UBS configures input partitions through thresholds and spike-triggered residual decay while retaining fixed binary readout weights. BBS separates sign from magnitude and uses a learnable scale to represent signed activations. These complementary codes support accumulation-and-shift dot products and integer-exponent attention mappings. The design follows two requirements: encoding should adapt to activation distributions, and the resulting values should preserve the arithmetic structure needed by the next operator. Conditional decay and learned scales serve the first requirement; binary readout serves the second. This connects the temporal representation to the attention computation that consumes it.

Our contributions are:

(1) Unipolar encoding. UBS distinguishes the numerical values specified by binary readout from the input intervals determined by thresholds and conditional decay. This provides short-window integer representations for shift-based exponential approximation.

(2) Bipolar encoding. BBS applies a shared magnitude process to both signs, with a learnable scale that adapts its finite signed codebook to the feature range.

(3) Spiking attention and evaluation. The combined design replaces major attention multiplications and exponential evaluations with accumulation and shifts, yielding a theoretical 98.53% reduction in core attention energy. Four-step Spora reaches 76.6 average GLUE score and 44.1 CoLA MCC, exceeding SpikeLM by 1.2 and 6.2 points. Conditional-decay analysis, matched-budget Static-QAT comparisons, event workloads, and fixed-point experiments connect these task results to encoding fidelity and computational cost.

References (44)