Can behavioral event boundaries make neural tokens transfer across sessions?

TWS tokenizes population activity between task events, letting a decoder trained on mice transfer to macaques without per-session fitting.

Direct answer

Yes, in this paper's tests. Tokenization with States (TWS) replaces per-neuron identity with the population activity between task events, so a decoder fit on some sessions works on unseen ones: on 53 held-out IBL sessions it decoded movement at MCC 0.565 while a per-neuron foundation model pretrained on those same sessions decoded at chance.

1sources cited

This article was generated with WisPaper-powered search and paper analysis.

Neuron identity makes every session out of distribution

Extracellular electrophysiology records a different set of neurons in every session. Electrode positions shift between insertions, impedance changes alter unit isolation, and spike sorting yields different populations even from identical trajectories. The paper verifies the consequence on the IBL Brain Wide Map: across all 29,403 session pairs from 109 subjects, no neuron label is shared. Of the 361 pairs from the same subject, 342 (94.7%) never come within 100 µm of each other, with a median closest approach of 1.2 mm, and even the 19 close pairs have mismatched labels because spike sorting assigns session-local cluster indices.

This matters because neural foundation models build tokens that carry the identity of one neuron and of the session it came from. If no neuron label recurs, that vocabulary is entirely session-specific, and every new session is an input the model has never seen. The paper's framing is that a usable tokenizer needs a unit that a single decoder can apply in every session and that also carries behavioral meaning.

Population geometry replaces neuron identity as the token

TWS looks for that unit in population activity, the joint activity of the recorded neurons. The paper's premise is that this activity evolves on a low-dimensional manifold that persists across neuronal turnover and, once sessions are aligned, across animals. The manifold changes regime at task events such as stimulus onset and movement onset. Within each regime the population occupies a state, meaning the part of the manifold it spans between two events, and each state carries its own behavioral meaning.

Concretely, TWS segments each trial at those events and converts every state into tokens of population geometry, with no neuron or session embedding. Each session enters with at most 128 units, in 20 ms bins from 0.5 s before stimulus onset or go cue to 1.5 s after it. A shared neuron encoder with the same parameters across all sessions embeds the neurons of a state, permutation-invariant aggregation pools them, and orthogonalization yields six Grassmannian tokens that a token-mixing backbone consumes. Because the token describes the manifold rather than naming neurons, all sessions share one token space.

Held-out sessions decode movement where per-neuron models fail

The central comparison is on 53 held-out IBL sessions. TWS reaches a movement MCC of 0.565 ± 0.006 (mean ± SD over 5 model seeds), while a per-neuron foundation model pretrained on those same sessions decodes at chance. The paper also reports that TWS decodes movement even from regime boundaries that carry no information about the target, which is the point of using state geometry rather than target-related activity.

MCC here is the Matthews correlation coefficient, a single number balancing correct and incorrect binary predictions, so 0.565 is well above the 0 that chance-level decoding would produce. The same held-out protocol gives TWS an RTR² of 0.402 ± 0.003, a choice MCC of 0.038 ± 0.006, and a block MCC of 0.026 ± 0.004. Those three targets are far weaker than movement, so the headline result should be read as strong cross-session movement decoding rather than uniform success on every behavioral variable.

Frozen on mice, the tokenizer still reads macaque reaches

The stronger test is transfer across species and hardware. After training on mice alone, TWS is frozen and applied to macaques and Utah arrays with only a linear probe fitted on each dataset. On reach direction, a target that its boundaries do not define, it achieves a Matthews correlation of 0.23, where the event time alone achieves 0.01. The gap indicates that the state tokens carry reach information beyond what the segmentation times already supply.

The scope conditions are explicit in the data. Reach direction is defined in the 84 center-out sessions of the 111 Utah array sessions from 4 reaching macaques, and it is scored there. The comparison against event time alone is the relevant baseline for this target, because the boundaries themselves do not encode reach direction; a tokenizer that merely marked event times would score near 0.01.

The token matters more than the model on top

The paper's summary claim for cross-session generalization is that the token matters more than the model on top. Supporting this, a probe fit on five sessions outperforms every baseline fit on all sessions on reaction time, which is what a shared token space is supposed to buy: a decoder trained on a few sessions generalizes to the rest.

The backbone is deliberately secondary. TWS uses a convolutional mixer by default, four blocks of a kernel-3 convolution over the six state tokens with d=256, and the paper reports it leads Mamba and Transformer backbones by at most 0.03 in movement MCC, with backbones that mix tokens decoding within 0.03 MCC of each other. Removing the Gram-Schmidt orthogonalization changes cross-session decoding by less than 0.01 on every target, so the Grassmannian form is a convenient realization of the tokens rather than a requirement. A manifold dimensionality ablation shows movement accuracy of 0.864, 0.865, and 0.867 for k_dim of 1, 2, and 4, and the paper selects k_dim = 2.

The invariance has a price the design sets

The discussion states the limits directly and ties them to the design. A tokenizer without neuron identity need not preserve a variable whose decoding direction differs from session to session. Averaging inside a regime gives up the time course within it. And TWS needs the event times that a task records, so free behavior would require a tokenizer that finds the regimes in the data itself.

These are not incidental caveats; they explain why the weakest results in the held-out table are choice and block MCC rather than movement. The paper positions TWS as a practical model for the electrophysiology datasets most laboratories hold: it fits nothing per session, it asks only for the event times a task already records, and a probe fit on a few sessions with behavioral labels generalizes to the remaining sessions.

Choose the token when sessions never share neurons

The decision this paper supports is specific. When every session records a different population and no neuron label recurs, as in the 29,403 IBL session pairs examined, per-neuron and per-session embeddings start from a vocabulary that cannot cover the next session. In that setting the paper's evidence favors investing in a shared population-geometry token over a larger model on top: the token change moves held-out movement decoding from chance to MCC 0.565, while backbone choice moves it by at most 0.03.

The same evidence sets the boundary of that priority. The gain is strongest for movement, weaker for RTR² at 0.402 and near zero for choice and block MCC, and cross-species transfer to reach direction reaches 0.23 against 0.01 for event time alone. TWS also assumes the task supplies event times and that averaging within a regime is acceptable, so a setting with free behavior or with a variable whose decoding direction shifts across sessions is where the token's advantage is least established.

Sources used in this answer

1

Neural Data Needs Semantic Tokenization: Behavioral Events as Boundaries of Session-Transferable Tokens

TWS tokenizes population activity between task events without neuron or session embeddings; on 53 held-out IBL sessions it decodes movement at MCC 0.565 while a per-neuron foundation model pretrained on those sessions decodes at chance, and frozen after training on mice it transfers to macaques and Utah arrays with a linear probe.