Why does training a learned soft prompt need white-box access to the model, and why does a trained one not move to another model?
answer
- gradients need the whole computation
- vectors go in below the text layer
- text in, text out exposes neither
- coordinates mean nothing elsewhere
- keep the recipe, not only the matrix
basics
~20 sTraining joins vectors to the model's embedded input and backpropagates through its layers, and a text-only API accepts no vectors and returns no gradients. The vectors are fitted to one model's embeddings and weights, so another model means retraining.
solid answer
~50 sTraining needs three things: the weights loaded, a way to feed vectors in place of token IDs, and gradients through every layer. Serving needs the vector input again. A provider's text-only API takes text and returns text, so it offers neither vector input nor gradients; you can write prompts against it or search over text, but you cannot fit vectors. A trained soft prompt does not move because its numbers only mean something relative to one embedding space and the frozen layers that read it. If the width differs, the matrix does not even fit. If the width matches, the coordinates still have no shared meaning, since separately trained models have no aligned embedding spaces. So a model change means retraining and re-evaluating. A written prompt at least runs elsewhere, though its quality can drop too. Keep the labelled data, the configuration and any seed text, because those are what actually carry over.
code
json · 11 lines{
"artifact": "soft-prompt",
"task": "invoice-field-extraction",
"model": {"id": "team-model-v3", "weights_sha256": "<hash>", "embedding_width": 2048},
"virtual_tokens": 20,
"parameters": 40960,
"initialization": {"kind": "text", "seed_text": "Extract the invoice number and total."},
"training_data": "invoices-train-2026-10",
"held_out_data": "invoices-heldout-2026-10",
"held_out_f1": 0.91
}go deeper
Recall the two facts: training needs the model's internals, and the result belongs to one model. Be ready to say why a request that only carries text cannot deliver vectors.
Spell out what the mechanism requires: loaded weights, vector input, gradients through frozen layers, and vector input again at serving. Separate the width mismatch failure from the same-width one.
Point out that the same-width case runs silently, so only evaluation catches it. Describe the record you keep beside the matrix, and what a model upgrade costs across many tasks.
Treat this as a lock-in decision. Soft prompts bind a team to self-hosting one exact model, so count the retraining on every upgrade against what the shared frozen model saves.
## What white-box access means here **White-box access** means you can reach inside the model, rather than only send it requests. A learned soft prompt needs that at training time and at serving time: 1. **Load the weights** on hardware you control, since the forward pass runs there. 2. **Feed vectors directly.** The input to the first layer has to be a matrix you supply, because virtual tokens have no token IDs to send. 3. **Backpropagate through the model.** The gradient for the vectors is computed through every frozen layer, even though none of those layers is updated. 4. **Do it again at serving.** Each request joins the same vectors to the embedded input, so the serving path must accept them too. The papers on this family all run their own models and take this for granted. It is a consequence of the mechanism, not a measured finding. ## Why a text-only API rules it out An API that accepts text and returns text exposes neither of the required surfaces: - No vector input, because the request is text and the provider's own tokenizer and embedding table turn it into vectors. - No gradient, because the response holds output and perhaps some scores, not derivatives with respect to the input. What still works against such an API is anything built from text: written prompts, and search over readable prompts, which is covered with prompt optimization. A provider's own fine-tuning service is a different arrangement: it trains on its side, and you do not receive vectors you can use elsewhere. A provider could in principle fit soft prompts internally, since it holds the weights, but that does not change what you can do through a text interface. ## Why the vectors do not move The matrix is a set of coordinates, and coordinates need a map. - **Different width.** A matrix with 2,048 columns does not fit a model with 4,096-wide embeddings. This failure is at least loud. - **Same width.** The matrix loads and runs, which is the dangerous case. Separately trained models learn their embedding spaces independently, so nothing aligns their dimensions. Vectors fitted against one set of frozen weights have no reason to steer another. - **A new checkpoint of the same model family.** Treat it as another model. Evaluate on the held-out set, and expect to retrain. Compare a written prompt. The text does run on any model that accepts text, which is real portability of form. Its quality may not carry, however. Lester et al. (2021) tried another model's manual prompts on their own checkpoints and report performance far below the original, while noting differences in training data and architecture as possible reasons. Portable means it runs, not that it scores the same. | Moved to | Does it load? | What to expect | |---|---|---| | Different width | No | A shape error | | Same width, separately trained | Yes | Silent loss of quality, so retrain | | New checkpoint, same family | Usually | Unknown until evaluated | ## You cannot read it either Review is the other thing that does not transfer. Lester et al. looked at each trained token's nearest vocabulary neighbours and found tight clusters, such as a group of words about technology. As sequences, though, the prompts showed little interpretability. So nobody can read a soft prompt in review, meaningfully compare two versions, or spot a bad change. Only evaluation tells you what changed. ## What to keep beside the matrix The durable asset is the recipe, not the vectors. As common practice, not a finding from these papers: - The exact model identifier and a hash of its weights. - The labelled training set and held-out set, each with a version. - The token count, the initialization and any seed text. - The held-out score that justified shipping it. The seed text is the one piece worth reusing directly. A text start does not make trained vectors portable, but on a new model you can begin a fresh run from the same text. ## What this means for a model upgrade For the team running a dozen tasks on one self-hosted model, each upgrade becomes twelve training runs and twelve evaluations before the old model can be retired. Serving both models side by side covers the switch. That cost belongs in the decision before anyone standardises on the artifact.
- Does a new checkpoint of the same model count as another model?Treat it as one. Weights have changed, so the function the vectors were fitted against has changed, by an amount you cannot read from the matrix. Run the held-out evaluation before trusting it. A small shift may still pass, in which case you keep the vectors, and otherwise you retrain from the saved recipe.
- Does starting from a written instruction make the soft prompt portable?No. The text only sets the starting values, and the trained vectors are fitted to that one model. What does carry over is the text itself: on a new model, you can begin a fresh run from the same seed, then evaluate it on the same held-out set.
- Which part of the white-box requirement still holds if you only serve vectors someone else trained?Serving still needs a path that accepts vectors in place of token IDs, on the exact model they were trained for. You no longer need gradients or a training run, but a text-only endpoint still cannot use them. So buying trained vectors does not free you from hosting that model or an equivalent interface.
A soft prompt is like a calibration profile for one printer. The numbers were fitted to that machine's quirks, nobody can read them as instructions, and loading them on another printer may run without error and still produce poor output, so you calibrate again.
- You can train soft prompts on any provider's API by calling it many times with text.
- If two models share an embedding width, their soft prompts are interchangeable.
- Since the model is frozen, training needs no access to its layers.
- The vectors can be decoded to text, then pasted into another model's prompt.
- A written prompt keeps the same quality on every model because it is portable.