Papers
Topics
Authors
Recent
Search
2000 character limit reached

Sparse Sinkhorn Token Translation (S2T2)

Updated 22 May 2026
  • The paper introduces S2T2 that leverages entropic regularized optimal transport to learn a sparse mapping between target and source tokens, improving perplexity and compression.
  • S2T2 formulates token translation via the Sinkhorn-Knopp algorithm with marginal constraints and sparsity penalties, enabling efficient domain adaptation.
  • Empirical results reveal that S2T2 outperforms baselines in protein sequence modeling by achieving lower perplexity and enhanced data compression with transferable translation matrices.

Sparse Sinkhorn Token Translation (S2T2) is an adaptation technique for pre-trained LLMs that leverages domain-specific tokenizers and structured, sparse token translation plans. It enables efficient reuse of next-token predictors across domains with differing token statistics, such as from natural language to protein sequences, by learning a transport matrix between token vocabularies, subject to marginal constraints and regularized for sparsity. S2T2 formalizes token translation as an entropic regularized optimal transport problem solved via the Sinkhorn-Knopp algorithm, producing a soft, potentially sparse mapping between target and source tokens to maximize model performance and compression in out-of-domain tasks (Feng et al., 2024).

1. Problem Statement and Notation

Let VsV_s be the source vocabulary (e.g., English byte-pair encoding) of size Vs=v|V_s| = v, for which a LLM LsL_s has been pre-trained to predict the next token via cross-entropy. For a new target domain where VsV_s does not yield efficient compression or semantic alignment—common in non-natural-language domains like proteins—a new tokenizer TtT_t is trained, producing a target vocabulary VtV_t of size Vt=u|V_t| = u. The adaptation problem is: reuse LsL_s (fixed weights) but operate over VtV_t by translating each target token tiVtt_i \in V_t into a sparse distribution over source tokens in Vs=v|V_s| = v0 (“soft” tokens), feed these through Vs=v|V_s| = v1 to predict the next source token, and translate the predicted source-token distribution back to Vs=v|V_s| = v2. This bidirectional translation is achieved with a learned matrix Vs=v|V_s| = v3 interpreted as a transport plan between Vs=v|V_s| = v4 and Vs=v|V_s| = v5 (Feng et al., 2024).

2. Mathematical Foundations of Sparse Sinkhorn Token Translation

The translation matrix Vs=v|V_s| = v6 is directly parameterized in Vs=v|V_s| = v7 and constrained such that: Vs=v|V_s| = v8 with frequency marginals Vs=v|V_s| = v9 typically uniform (LsL_s0, LsL_s1).

The S2T2 objective jointly optimizes tokenizer parameters LsL_s2 and LsL_s3: LsL_s4 where LsL_s5 is the one-hot encoding of a target sequence, LsL_s6 applies a regularized Sinkhorn projection, LsL_s7 is the fixed LM probability, and LsL_s8 enforces sparsity (e.g., LsL_s9 or group-L1 penalty).

The entropic regularized optimal transport solution is: VsV_s0 with VsV_s1 as a cost/score matrix and VsV_s2 produced by Sinkhorn-Knopp iterations:

  • Initialize VsV_s3 elementwise.
  • Iterate: VsV_s4, VsV_s5.
  • Form VsV_s6. After convergence, VsV_s7 satisfies prescribed marginals. Sparsity regularization is implemented by backpropagating through Sinkhorn steps into VsV_s8 and hence VsV_s9.

3. Optimization and Implementation Procedure

S2T2 parameters TtT_t0 are optimized end-to-end with TtT_t1 unrolled Sinkhorn iterations per forward pass. The workflow is:

  1. Sample target-domain data TtT_t2, tokenize with TtT_t3 and encode as TtT_t4.
  2. Compute Sinkhorn-projected transport TtT_t5.
  3. Feed “soft” source tokens TtT_t6 through the fixed TtT_t7 to calculate next-token cross-entropy.
  4. Add TtT_t8 to penalize translation density.
  5. Backpropagate through Sinkhorn iterations to update TtT_t9 and tokenizer merges.
  6. Hyperparameters: regularization weight VtV_t0 (0–1), Sinkhorn temperature VtV_t1–VtV_t2, VtV_t3 Sinkhorn iterations, batch size VtV_t4, sequence length VtV_t5, AdamW (VtV_t6, VtV_t7), cosine-annealed schedule with 20% warm-up (Feng et al., 2024).

4. Empirical Performance and Benchmarking

S2T2 is evaluated on adaptation from English to protein sequence modeling (UniRef50). A new BPE tokenizer VtV_t8 (vocab size VtV_t9) reduces token length by Vt=u|V_t| = u01.82Vt=u|V_t| = u1. Performance is measured via:

  • Perplexity (“perp”): LM accuracy conditioned on token translations.
  • Bits per byte (BpB): Vt=u|V_t| = u2.

Comparison with baselines (unconstrained M, dense Sinkhorn, finetuning with source/target tokenizers) is summarized:

Method Perplexity ↓ BpB ↓
Unconstrained M 174.20 4.09
+ continual finetune 130.44 3.86
Dense Sinkhorn M 167.74 4.06
+ continual finetune 136.12 3.89
S2T2 (sparse Sinkhorn M) 144.03 3.94
+ continual finetune 118.78 3.78
Finetune, orig. tokenizer 151.05 7.24
Finetune, new tokenizer 130.56 3.86

S2T2 combined with LM finetuning yields the lowest reported perplexity and best compression, outperforming both naive and dense translation strategies (Feng et al., 2024).

5. Transferability Across Model Scales

A notable property of S2T2 is the portability of the learned translation matrix Vt=u|V_t| = u3 across models of different sizes. Matrices trained on a 1B-parameter LLM (OLMo-1B) can be rescaled and directly plugged into larger models (OLMo-7B) without retraining Vt=u|V_t| = u4. Experiments show:

  • Direct transfer and initialization with fixed Vt=u|V_t| = u5 provides immediate perplexity and compression gains relative to both original and target-domain tokenizers.
  • Learning Vt=u|V_t| = u6 on a small model is approximately 7Vt=u|V_t| = u7 cheaper than training the same on the larger model.
  • Figure 1 in (Feng et al., 2024) shows that transferred S2T2 improves held-out loss from the outset, regardless of sparsity penalty Vt=u|V_t| = u8.

This suggests translation plans learned for token alignment are robust and reusable across model scales.

6. Advantages, Limitations, and Prospects

S2T2’s main advantages are:

  • Domain-specific tokenizer learning with preserved pre-trained LM capabilities.
  • Empirically superior perplexity and data compression compared to direct finetuning with static tokenizers.
  • Sparser translations enable efficient inference, as most target tokens map to a small number of source tokens.
  • Translation matrices are readily transferable across model scales, significantly reducing computational cost in adaptation (Feng et al., 2024).

Noted limitations and open questions include:

  • Computational overhead of Sinkhorn iterations and need to carefully tune temperature Vt=u|V_t| = u9 and number of iterations.
  • The choice of the sparsity penalty LsL_s0 strongly affects the trade-off between translation matrix density and accuracy.
  • Extension to multi-domain or multilingual adaptation would require block-structured, potentially hierarchical LsL_s1.
  • Adapting S2T2 to modalities beyond text (e.g., vision, code) would involve defining suitable “tokenizers” aligned with the modality structure.

7. Connections to Sparse Sinkhorn Attention and Broader Context

S2T2 incorporates entropic-regularized transport and Sinkhorn projections, drawing methodological parallels to Sparse Sinkhorn Attention (Tay et al., 2020). While S2T2 applies these mathematical operators for inter-vocabulary token translation, Sparse Sinkhorn Attention exploits them for sparse and efficient self-attention patterns via permutation of token blocks. Both fields share core theoretical machinery: Sinkhorn-Knopp normalization, doubly-stochastic constraints, and learned sparsity, but differ in application—token alignment versus attention routing. This broader context situates S2T2 as part of a trend leveraging optimal transport and differentiable combinatorial optimization techniques for scalable, sparse, and adaptable neural architectures (Tay et al., 2020, Feng et al., 2024).

Definition Search Book Streamline Icon: https://streamlinehq.com
References (2)

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to Sparse Sinkhorn Token Translation (S2T2).