On the Learnability of Model Reprogramming: A Reachability and Relabeling Perspective

Zesheng Ye, Pin-Yu Chen, Feng LiuNeurIPS 2026

TL;DR

Suppose you want an existing, frozen neural network—perhaps locked behind an API that only spits out discrete class labels—to solve a brand-new task without touching a single weight. Model Reprogramming (MR) pulls this off by sandwiching the frozen model between a learnable input adapter and a learnable output translator. This paper provides the first finite-sample learning theory focused on the wrapper itself, revealing exactly how many examples you need to train it and pinpointing why—and where—the pipeline hits its fundamental performance limits.

What Problem Does This Paper Address?

Pre-trained models are massive repositories of hard-won capabilities, yet we often only access them through restricted interfaces (like checkpoints or black-box APIs) and have very little data for our new downstream tasks. Model Reprogramming adapts a frozen "source" model to a "target" task by wrapping it in two lightweight, learnable stages: an input transformation (like adding a learnable pixel border to an image) and an output mapping (translating source labels like "tabby cat" into target labels like "tumor").

Empirically, MR works remarkably well across vision, text, time-series, and even protein sequences. Yet theory has lagged behind practice. Previous theoretical work asked which source models are reprogrammable based on internal architecture or alignment. That leaves a glaring blind spot for practitioners working with limited data: what properties of the wrapper itself control learning? Specifically:

  1. Estimation Error: How many target samples do we need to find the best possible wrapper in our chosen design space?
  2. Approximation Error: Even with infinite target data, how far is that best wrapper from the true optimal predictor (the Bayes risk)?
Figure 1: We present a finite-sample learnability analysis for hard-label MR through the MR wrapper structure, organized by the estimation error (Sections 3 to 5) and approximation error (Section 6) perspectives, respectively.

Methods

Instead of peering inside the frozen classifier $f_{\text{S}}$, the authors analyze the sequential two-stage bottleneck of hard-label MR (where $f_{\text{S}}$ outputs discrete class IDs rather than continuous probabilities):

  • Factorizing Complexity (Reachability & Relabeling): Rather than treating the composite wrapper as an opaque black box, the authors observe that on any finite batch of target inputs, the input transformation $g$ can only coax the frozen model into producing a certain set of source-label patterns (reachability). The output mapping $h$ only ever gets to relabel those specific patterns (conditional relabeling). Using Probable Approximately Correct (PAC) learning theory, they factorize the wrapper's complexity into these two sequential pieces.
  • Concrete Instantiations & Tightness: They derive closed-form sample complexity rates for standard additive input transformations ($x + M\theta$, such as masked perturbations) paired with affine or ReLU source networks by counting geometric hyperplane arrangements. They also construct an explicit binary classification family and apply Assouad's lemma to prove a matching minimax lower bound.
  • Exact Approximation Split & Certificates: At the population level, they decompose the irreducible approximation error into two exact pieces, and derive an empirically estimable upper-bound "certificate" that extends to source models exposing continuous logits.

Datasets

Because optimizer quirks like gradient noise can muddy theoretical water, the authors test their theory under exact Empirical Risk Minimization (ERM) on two controlled setups:

  • Synthetic 16-Basis Benchmark: A newly constructed binary classification task over 16 basis vectors in $\mathbb{R}^{16}$ (grouped into 8 pairs with a 10% label-flip noise floor, giving a Bayes risk of $0.10$) designed to cleanly swap capacity and bottlenecks between the input and output stages.
  • Pretrained MNIST → $90^\circ$-Rotated MNIST Parity: Frozen MLP and minimal-LeNet models pre-trained on standard upright MNIST digits (exposing only hard digit IDs 0–9), reprogrammed to predict odd/even parity on unseen $90^\circ$-rotated MNIST digits.

Key Insights and Ideas

  • Sample Complexity is Additive and Symmetric: The number of target samples needed to train an MR wrapper scales additively with the log-growth of reachable source patterns ($d_{\mathcal{R}}$) and conditional relabelings ($d_{\mathcal{H}}$), roughly $\widetilde{O}((d_{\mathcal{R}} + d_{\mathcal{H}})/\varepsilon^2)$. Because of the matching lower bound, neither stage can bail out the other—bits of information learned via input steering and output relabeling are independently identifiable.
  • Unreachable Labels Cost You Nothing: Suppose your frozen ImageNet model has 1,000 classes, so your output mapper looks dangerously complex on paper. Because relabeling capacity is conditioned on reachability, if your input adapter only ever triggers 5 of those classes on your target data, you only pay the statistical sample-complexity price for relabeling 5 classes—an exponential savings over naive complexity bounds.
  • Input Distribution Alignment Isn't Strictly Required: The exact approximation error splits into source-label information loss (when distinct target classes get squashed onto the same source label) and target-relabeling restriction (when your output head isn't expressive enough, like using one-to-one label matching when many-to-one is needed). Crucially, your transformed target inputs don't actually need to look like the source training distribution—they just need to land on opposite sides of the frozen model's decision boundaries!

Key Results

  • Perfect Capacity Symmetry: In the synthetic benchmark, putting $r$ bits of capacity entirely in the input transformation versus entirely in the output head yielded identical estimation errors across every sample size—for $r=8$, error started at 0.1765 ($n_{\text{T}}=8$), dropped to 0.0050 ($n_{\text{T}}=64$), and hit 0.0000 by $n_{\text{T}}=512$.
  • Diagnostic Separation of Bottlenecks: Two broken synthetic wrappers with the exact same suboptimal risk (0.5000 at $m=8$ affected pairs) were cleanly diagnosed by the theory's plug-in estimators: one suffered purely from source-label merging (0.4000 info loss, 0.0000 head loss), and the other purely from an overly rigid output head (0.0000 info loss, 0.4000 head loss).
  • Joint Adaptation on Neural Sources: On $90^\circ$-rotated MNIST parity, combining a 4-rotation input adapter with a full binary output head achieved sub-1% test risk (0.0098 on MLP, 0.0058 on LeNet) with just $n_{\text{T}}=50$ samples. Restricting either the input (identity only) or output (threshold head) caused test error to stall above 0.33–0.40 even at $n_{\text{T}}=3200$. Meanwhile, reprogramming an untrained random network hovered near random guessing (0.4355 and 0.5075), confirming wrappers only work when the frozen source already carves up space usefully.

Limitations and Future Work

  • Beyond Piecewise-Linear Sources: While the general PAC bound holds for any frozen classifier, the explicit closed-form parameter rates rely on counting constant-label cells, which breaks down on smooth Transformer operations like softmax attention, LayerNorm, and GELU. Extending explicit rates there will require margin-based covering numbers or Rademacher complexity.
  • Continuous Logit Sample Complexity: When a source model exposes continuous logits instead of hard labels, the paper's approximation certificates carry over, but the combinatorial growth factorization for finite-sample ERM does not automatically apply.
  • Optimization Dynamics: The theory characterizes exact/approximate ERM and evaluates fixed wrappers, leaving open how iterative gradient-based training navigates the two approximation bottlenecks in practice.

Summary updated

Abstract

Model reprogramming adapts a *frozen* source model to a target task by wrapping it in a *learnable* input transformation from target input to the source-model input space, and an output mapping from source-model outputs to target predictions. Despite extensive empirical progress, the *finite-sample learnability* of the induced wrapper hypothesis class $\mathcal{F}\_{\rm MR}$ remains underexplored. We address this for source models that expose hard sou2rce labels and analyze through the wrapper structure: on any target samples, the input transformation selects *reachable* source labels that the output mapping relabels. Through this lens, we answer two questions: ① how many target samples are needed to approach the best predictor in $\mathcal{F}\_{\rm MR}$, and ② what gap remains between the optimum over $\mathcal{F}\_{\rm MR}$ and the target Bayes risk. For ①, the wrapper structure factorizes the sample-wise complexity of $\mathcal{F}\_{\rm MR}$ into a *reachability* term counting reachable source-label patterns, and a *conditional relabeling* term counting their relabelings. This yields an agnostic-PAC bound on the *estimation error*, with sample complexity scaling additively in the two terms; this bound becomes closed-form on additive input transformations and is matched by a lower bound on an explicit binary classification construction. For ②, the same structure decomposes the *approximation error* exactly into the source-label information loss and output-mapping restriction with a source-conditional upper bound on this gap. We extend the approximation analysis to logit-exposing source models, where the upper bound is empirically estimable. The wrapper-side analysis localizes both errors to specific components, giving a structural view of reprogramming practice. Code is available [here](https://github.com/zyecs/repgm-slt).
BibTeX
@inproceedings{ye2026learnability,
  author = {Zesheng Ye and Pin-Yu Chen and Feng Liu},
  title = {{On the Learnability of Model Reprogramming: A Reachability and Relabeling Perspective}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2026},
  url = {https://openreview.net/forum?id=6W21Zo9L7E},
}
Figure