generalize
TrajRoformer: Learning-based Sparse Trajectory Recovery without Dense Training Data
Lin, Yan, Deng, Liwei, Hu, Jilin, Jensen, Christian S., Guo, Shengnan, Wan, Huaiyu
Vehicle GPS trajectories are the data foundation for many tasks in intelligent transportation. Yet, available trajectories are commonly sparse, with long sampling intervals that fail to preserve fine-grained movement and degrade the performance of downstream tasks. Trajectory recovery addresses this by recovering dense trajectories with short sampling intervals from sparse counterparts. Recent learning-based recovery methods are more accurate than traditional rule-based ones but rely on large-scale dense trajectory datasets for training, as they cannot generalize to shorter target intervals than those in their training trajectories. This is a problem as available trajectories are often capped at sparse sampling intervals. We propose TrajRoformer, a new learning-based trajectory recovery method that generalizes to target sampling intervals shorter than those in its training trajectories, through three innovations. First, encoding the relative temporal and spatial features between trajectory points as angular differences, turning recovery to a shorter interval into an interpolation within the range of relative features seen during training. Second, learning the dataset's collective movement explicitly by having the model teach itself from a denser to a sparser sampling, enabling recovery to a shorter interval to follow that movement. Third, filling the missing points from sparse to dense in halving steps, each a small upsampling within the range seen during training. We report on comprehensive experiments on two real-world trajectory datasets, showing that TrajRoformer achieves its design goal.
Capability and Interpretability of Transformers on Multi-task Recurrence
Chen, Xiamin, Liu, Linyu, Hu, Jiachen, Lu, Pinyan
Transformers are widely used in various language tasks, with limited understanding of their internal mechanisms. Motivated by the recurrent structure of many linguistic rules, we study the capability and interpretability of Transformers through a controlled family of linear recurrence tasks over finite cyclic groups. These tasks range from executing a single fixed rule to identifying a latent rule from context and switching between explicitly specified rules, with and without input masking. Through extensive experiments across different configurations, we find that switching specified rules is simpler than identifying latent rules for Transformers in general. We also identify how several key factors affect the generalization capability of Transformers, including the depth, width, and the algebraic structure of the linear recurrence. Curriculum training is extremely useful when the number of rules is large. With standard tools in mechanistic interpretability like linear probing and input patching, our study reveals how Transformers represent, identify, and execute multiple rules.
Language Model Harnesses can be Compositional Generalizers
Zhang, Alex L., Chakraborty, Souradip, Khattab, Omar
Modern language models (LMs) are post-trained and deployed as agents inside a "harness", but standard harness designs accumulate context that the neural network is forced to generalize to, making training for long-horizon tasks expensive and time-consuming. We study an alternative emerging path: training inherently neurosymbolic LM harnesses, which externalize and manage context programmatically to compose existing LM capabilities. We hypothesize that training around these harnesses can offer a better return on compute by enabling compositional generalization, as they can learn to decompose complex problems so that every observation their neural LM receives is locally in-distribution, even when the full task is novel. We find that harnesses like the Recursive Language Model (RLM) learn such decompositions readily under reinforcement learning post-training: (1) we demonstrate that training only on short tasks can generalize to tasks 2-64$\times$ longer while the base neural LM improves less, and (2) training on one domain transfers to novel domains that share latent structure. On messier, complex tasks, we find that we can target individual LLM calls within a harness by generating and training on easier, synthetically generated surrogate environments with fake tool / sub-calls, a technique we call surrogate harness training. From this finding, we train RLM-27B on synthetic data, and show it improves Qwen3.8-27B in the same RLM harness on a hard suite of long-context tasks like CTC-Bench and ExpertLongBench by 26.9% on average while using $\sim$2$\times$ fewer tokens at inference time. Finally, we show that harnesses can compose over these newly learned decompositions using recursive sub-harness calls.
Why ML-based cough models do not generalize: a systematic cross-dataset evaluation for tuberculosis screening
Zhang, Wensi, Teijeiro, Tomas, Thevenot, Jérôme, Atienza, David
Cough acoustics are promising for non-invasive tuberculosis (TB) screening, yet whether machine learning (ML) models capture disease-related acoustics or artifacts of data collection remains unresolved. We evaluated the cross-dataset generalizability of classical ML and deep learning (DL) cough-based TB classifiers across three independent datasets. Despite moderate within-dataset performance (ROC-AUC up to $0.76 \pm 0.06$), both pipelines fail to generalize, with external performance frequently below 0.6, indicating a possible limitation of the data. We further observed that audio representations are organized by recording device and dataset rather than TB status, predicted TB probability tracks country-level prevalence in CODA, and device mismatch degrades transfer while device-diverse training improves it. Additionally, a clinical-variable baseline generalizes more consistently (ROC-AUC $0.65-0.71$), indicating acquisition-specific variability in acoustics is a stronger driver of poor generalizability. High within-dataset performance is not enough. External validation is essential before cough-based TB models are clinically ready.
Examining form-based linguistic productivity in people and large language models
Wilson, Michael, Frank, Robert
Linguistic productivity, as evidenced by the use of words in novel contexts, is one of the most striking facts about human language. However, how abstract the knowledge that enables such productivity is remains unclear. We compare people's and computational language models' linguistic productivity in contexts where successful generalization depends on form-based information. We focus on extending the use of a novel verb learned in the active voice to passive contexts. We find people extend active to passive uses in a way consistent with abstract generalizations concerning linguistic form, even when no plausible meaning can be assigned to the novel verb. In contrast, large language models succeeded only when a meaning like an existing verb's could be assigned to the novel verb. We conclude that computational models' syntactic knowledge remains tied to the distribution and meaning of specific lexical items in a way that human syntactic knowledge is not.
Sparsity and Out-of-Distribution Generalization
Aaronson, Scott, Lee, Lin Lin, Li, Jiawei
Explaining out-of-distribution generalization has been a central problem in epistemology since Goodman's "grue" puzzle in 1946. Today it's a central problem in machine learning, including AI alignment. Here we propose a principled account of OOD generalization with three main ingredients. First, the world is always presented to experience not as an amorphous mass, but via distinguished features (for example, visual and auditory channels). Second, Occam's Razor favors hypotheses that are "sparse," meaning that they depend on as few features as possible. Third, sparse hypotheses will generalize from a training to a test distribution, provided the two distributions sufficiently overlap on their restrictions to the features that are either actually relevant or hypothesized to be. The two distributions could diverge arbitrarily on other features. We prove a simple theorem that formalizes the above intuitions, generalizing the classic sample complexity bound of Blumer et al. to an OOD context. We then generalize sparse classifiers to subspace juntas, where the ground truth classifier depends solely on a low-dimensional linear subspace of the features.
Character-aware Transformers Learn an Irregular Morphological Pattern Yet None Generalize Like Humans
Ramarao, Akhilesh Kakolu, Tang, Kevin, Baer-Henney, Dinah
Whether neural networks can serve as cognitive models of morphological learning remains an open question. Recent work has shown that encoder-decoder models can acquire irregular patterns, but evidence that they generalize these patterns like humans is mixed. We investigate this using the Spanish \emph{L-shaped morphome}, where only the first-person singular indicative (e.g., \textit{pongo} `I put') shares its stem with all subjunctive forms (e.g., \textit{ponga, pongas}) despite lacking apparent phonological, semantic, or syntactic motivation. We compare five encoder-decoder transformers varying along two dimensions: sequential vs. position-invariant positional encoding, and atomic vs. decomposed tag representations. Positional encoding proves decisive: position-invariant models recover the correct L-shaped paradigm clustering even when L-shaped verbs are scarce in training, whereas sequential positional encoding models only partially capture the pattern. Yet none of the models productively generalize this pattern to novel forms. Position-invariant models generalize the L-shaped stem across subjunctive cells but fail to extend it to the first-person singular indicative, producing a mood-based generalization rather than the L-shaped morphomic pattern. Humans do the opposite, generalizing preferentially to the first-person singular indicative over subjunctive forms. None of the models reproduce the human pattern, highlighting the gap between statistical pattern reproduction and morphological abstraction.
A Positional Realizability Theory of Length Generalization in Single-Head Attention
Han, Jiasong, Chai, Yunkai, Wang, Jintao
Why does length generalization (LG) depend so sharply on the positional encoding (PE)? Relative schemes extrapolate fixed offsets, absolute schemes fix positions, and neither handles growing offsets. We give a realizability theory for a deliberately controlled abstraction, a single positional-only attention head, that derives this well-documented empirical pattern and says precisely where it holds and breaks. The device is a simulation transfer operator $T_L$ that re-evaluates a selected length-$L_0$-realizing positional kernel on the longer grid, with a scalar $α_L \in [0,1]$ read off before any training from $(Φ, t_n)$ alone. Here $α_L$ serves as the computable witness of that taxonomy's derivation, not as a stronger empirical predictor. Our results are a relative-head deep-row characterization for kernels with a strict unique global maximizer (Theorem 2), an absolute/relative duality that derives the pattern (Proposition 4), a learned-absolute underdetermination result, and a static expressivity bound; a sufficiency theorem (Theorem 1) bridges $α_L$ to LG, and the general deterministic case is a precise open conjecture (correcting a tempting but invalid "outside-colspan" argument). Experiments confirm the structure: in the controlled single-head regime $α_L$ exactly separates the taxonomy's generalizing and non-generalizing (PE, task) cells (2625 trained-model measurements; stable at vocab 64/d=128). Together, these results turn the received PE taxonomy into a positional-kernel transfer theorem, and identify the content and depth mechanisms that escape it. The theory concerns the positional channel alone: tasks whose targets depend on token content, including the standard length-generalization suite such as addition and sorting, fall outside Theorem 2.
"Deep lifts": Neural networks can generalize even with the dumbest optimizer
Given a labeled dataset $\{(x_i, y_i)\}_{i = 1}^n$, consider drawing a parameter vector $\hatθ$ uniformly at random from those that interpolate the data within a width-$W$ depth-$D$ ReLU architecture with continuous weights bounded within $[-M, M]$. We study the generalization properties of $\hatθ$ in the case where the dataset can, in fact, be explained by a smaller $w$-by-$d$ ReLU network. Despite the obliviousness of the selection rule for $\hatθ$, it adaptively generalizes at the rate $\tilde O\left(\frac{wdWD}{n}\right)$, rather than being governed by the VC dimension of the full $W$-by-$D$ hypothesis class. The reason is due to a particular inductive bias in ReLU networks: the $w$-by-$d$ parameter *witnesses* an exponential volume of $W$-by-$D$ interpolating parameters, which dwarfs the volume of poorly generalizing parameters (conditioned on interpolation). We explicitly construct this set of near-equivalent $W$-by-$D$ parameters by a proof technique called *deep lifting*, and then tie the achievable volume to stability properties of the $w$-by-$d$ witness. Examples show that these techniques allow us to convert approximation-theoretic results into generalization guarantees for nonparametric classes. We further show that generalization of uniform-random interpolators can survive label corruptions.
The Long Delay to Arithmetic Generalization
Large language models today still make mistakes on multi-digit arithmetic when they do not have tools, and part of the reason is how numbers are split into tokens. Arithmetic is also a setting where the correct answer to every input and the algorithm that produces it are already known, so training transformers on it lets us study what they learn against a ground truth. These models often fit their training set long before they generalize to held-out inputs, and this delay, known as grokking, decreases as the training set grows. But, how does the representation of numbers change the amount of data a transformer needs to generalize? We study one-step Collatz prediction, in which a transformer reads the digits of an integer in a chosen base and outputs the digits of the next term in its Collatz sequence. We find that the long delay appears only when the training set has few different integers, and that the numeral base determines how many integers are sufficient. In bases where each output digit depends only on a few neighbouring input digits, because the carry between positions depends only on the current digit, a transformer needs several times fewer training integers. We predicted this ordering before training, and input length does not explain it. The same carry structure predicts which bases are easy for a second Collatz map, for integer division, for a decoder-only transformer, and across three model sizes. Finally, a linear probe recovers the low-order residues of the input as accurately from a randomly initialized encoder as from a trained one. Thus, high probe accuracy on such features does not reliably show that a model has learned to compute them. More broadly, we show that the choice of numeral representation affects sample efficiency in ways we can predict from the structure of the task before training.