Post-Adaptation Memory Tuning (PAMT)
- PAMT is a design pattern that separates a stable base (evolved or pretrained weights) from transient adaptation mechanisms, enabling localized tuning.
- It employs methods like fitness-scaled Hebbian updates, attention-weighted memory composition, and sparse parametric corrections to adapt behavior without full parameter retraining.
- PAMT enhances performance metrics (e.g., success rate, Dice score, average precision) while ensuring parameter efficiency and retaining core learned knowledge.
Searching arXiv for the cited PAMT-related papers and adjacent terminology. to=arxiv.search պարզ query 娱乐总代理 code: {"query":"(Hammami et al., 5 Aug 2025, Sprechmann et al., 2018, Chen et al., 6 Mar 2026, Mekonnen et al., 25 Apr 2026, Kim et al., 2023)"} to=arxiv_search code: {"query":"(Hammami et al., 5 Aug 2025)"} Post-Adaptation Memory Tuning (PAMT) denotes a family of post-training or post-evolution procedures in which a stable controller or model is retained as long-term memory, while a distinct adaptation mechanism modifies behavior after the primary learning stage. In the formulation introduced for evolutionary robotics, PAMT stores an evolved genotype as immutable genetic memory and applies fitness-scaled Hebbian plasticity only during a trial, after which the temporary perturbations are discarded (Hammami et al., 5 Aug 2025). Later uses of the term in medical image segmentation and continual generative retrieval similarly move adaptation away from wholesale backbone updates and toward memory composition or memory-only calibration with frozen core networks (Chen et al., 6 Mar 2026, Mekonnen et al., 25 Apr 2026). Related methods such as Memory-based Parameter Adaptation (MbPA) and Plug-in External Memory Adaptation (PEMA) do not always use the PAMT label, but they instantiate closely related ideas: transient local parameter modification or external-memory-mediated inference layered on top of a stable parametric model (Sprechmann et al., 2018, Kim et al., 2023).
1. Core structural pattern
Across the cited literature, PAMT is characterized by a separation between persistent memory and transient adaptation. In robotics, the genotype is fixed and the phenotype is reset from at the beginning of each trial; in MemSeg-Agent, the segmentation backbone remains frozen while static, few-shot, and test-time working memories are composed at inference; in continual generative retrieval, Stage 2 freezes the backbone and routing and updates only selected rows of a parametric memory head (Hammami et al., 5 Aug 2025, Chen et al., 6 Mar 2026, Mekonnen et al., 25 Apr 2026).
| Setting | Stable component | Adaptive component |
|---|---|---|
| Evolutionary robotics | Genotype | Hebbian plasticity during runtime |
| Medical image segmentation | Frozen backbone | Static, few-shot, and working memories |
| Continual generative retrieval | Frozen backbone and routing | Selected PMH value rows |
A recurring operational motif is that adaptation is local in scope and bounded in persistence. The robot “forgets” by reloading at the next trial; MbPA predicts with and then discards 0; MemSeg-Agent updates compact memory units rather than model parameters; and PAMT for generative retrieval trains only a fixed budget of memory values selected using decoding-time access statistics (Hammami et al., 5 Aug 2025, Sprechmann et al., 2018, Mekonnen et al., 25 Apr 2026). This suggests that PAMT is better understood as a design pattern than as a single fixed algorithm.
2. Original robotic formulation: genetic memory plus Hebbian overlay
In the mechanism introduced in “Why Evolve When You Can Adapt? Post-Evolution Adaptation of Genetic Memory for On-the-Fly Control,” a standard Genetic Algorithm evolves the weights of a Multi-Layer Perceptron controller in a static T-maze environment, and the final GA-optimized weight vector 1 is stored unchanged as the robot’s genetic memory (Hammami et al., 5 Aug 2025). The MLP has 16 inputs (8 light sensors + 8 proximity sensors), four hidden layers 2, and 2 outputs corresponding to left and right wheel velocities. At test time, each trial begins by loading 3, after which a Hebbian plasticity module monitors pre- and post-synaptic activations 4 and updates weights online.
The central update rule is a fitness-modulated Hebbian law. The instantaneous weight change is written as
5
with
6
Here the real-time fitness signal 7, computed exactly as in evolution from collision avoidance, forward motion, junction success, and goal distance, acts as a neuromodulator that scales the Hebbian learning rate (Hammami et al., 5 Aug 2025). To stabilize pure Hebbian growth, the implementation uses an exponentially decaying trace
8
with 9 and 0, and then applies
1
with 2. The reported base rates are 3, and 4 ensures a lower-bound learning if performance drops very low.
The experimental platform is an e-puck simulated in Webots on a T-maze navigation task. If a dedicated light source is ON, the robot must turn right at the junction; if OFF, it must turn left. Dynamic test conditions include a light-intensity change from luminosity 5 during evolution to 6 at test time, and obstacle insertion by adding 2 or 4 wall segments post-evolution (Hammami et al., 5 Aug 2025). Performance is reported via success rate, final position error to goal, time-to-goal, path length, average speed, and mean weight change magnitude.
The reported results define the original PAMT claim. In the light-change scenario, GA alone in low light yields mean position error 7 and success rate 8, whereas GA+PAMT reduces the error to 9 with success rate 0 (Hammami et al., 5 Aug 2025). In the obstacle scenario, GA alone gives 1 success with 2 or 4 obstacles, while GA+PAMT with 2 yields 3 success across all obstacle counts, with time-to-goal comparable to the base environment. The memory-reset step is essential: when the trial ends, all temporary Hebbian updates are discarded and the next trial restarts from 4, thereby preserving the core evolved policy.
3. Memory-space PAMT in medical image segmentation
MemSeg-Agent reformulates PAMT as adaptation in memory space rather than weight space. Its architecture is built around a frozen segmentation backbone 5, for example the SAM2 encoder–decoder, and three memory stores coordinated at inference by an agentic controller: Static Memory 6, Few-Shot Adaptation Memory 7, and Test-Time Working Memory 8 (Chen et al., 6 Mar 2026). During “post-adaptation” training, only the static pseudo-observations 9 are updated, while 0 and the frozen memory encoder 1 remain fixed. At test time, labeled support pairs are encoded into nonparametric memory tokens for 2, and human-in-the-loop corrections populate or update 3.
Memory addressing is formulated through a query key 4 and memory-slot keys 5. The scaled cosine similarity
6
is normalized by softmax to produce attention weights 7, and the read vector is
8
The agentic controller outputs nonnegative coefficients 9 summing to 1, yielding a grouped composition
0
The composed read is then concatenated or cross-attended into the frozen backbone to produce 1 (Chen et al., 6 Mar 2026).
Two update regimes are central. In federated learning, each client updates only its static pseudo-observations by minimizing a segmentation loss with the backbone fixed, then uploads 2 to the server for element-wise averaging: 3 In test-time working memory, a new correction 4 is encoded as 5, compared against existing slots, and either appended or merged by a gated EMA rule,
6
without any backbone-weight change (Chen et al., 6 Mar 2026).
The empirical claims are framed around parameter efficiency, communication efficiency, and domain robustness. Static memory alone matches or exceeds strong supervised baselines including U-Net, SwinUNETR, nnU-Net, and MedSAM2 on in-domain segmentation across CHAOS, ACDC, and CAMUS, using only 7 M memory parameters versus 8 M model weights (Chen et al., 6 Mar 2026). In a federated simulation over 4 sites, updating only static memory reduces per-round communication by 9 (0) compared to SAM2-tiny weight updates, with no loss in final Dice. In cross-domain evaluation from CAMUS to CardiacUDA, static memory alone reaches 1 average Dice, compared with nnU-Net’s 2 and MedSAM2’s 3, while Static + Working Memory rises to 4 average Dice, a 5 absolute gain. The paper further reports a monotonic “live” improvement curve as corrected samples accumulate.
4. PAMT as sparse memory-only stabilization for continual generative retrieval
In continual generative retrieval, PAMT appears as a second-stage stabilization procedure applied after sequential adaptation of a generative retriever on a new document slice. The relevant architecture attaches a Parametric Memory Head (PMH) to a Stage 1–adapted encoder–decoder backbone such as T5, then freezes the backbone and PMH routing while updating only selected PMH value rows 6 (Mekonnen et al., 25 Apr 2026). The PMH contains two key tables 7 and 8, a value table 9, and a learned query projection 0.
At each decoding step, the decoder hidden state 1 is projected into product-key queries and scored as
2
Top-3 retrieval per head yields sets 4, from which a hidden-space correction is formed: 5 During prefix-trie constrained decoding, the corrected logits over trie-valid tokens 6 become
7
where 8 is the frozen output embedding matrix (Mekonnen et al., 25 Apr 2026). PMH therefore acts as a sparse residual module that corrects decoder scores only on valid doc-ID tokens.
The distinctive algorithmic contribution is the row-selection rule that limits cross-slice interference. Historical access-frequency sketches 9 track whether a memory row was hit during decoding in previous sessions, current-session counts 0 are normalized to 1, a protected set 2 is defined as the top 3-fraction by historical usage, and the update-candidate score is
4
with
5
The top 6 non-protected rows form 7, and only those rows are optimized under a hinge ranking loss during teacher-forced decoding (Mekonnen et al., 25 Apr 2026). The backbone, the query projection 8, both key tables, and 9 remain frozen.
The reported motivation is the stability–plasticity trade-off. Stage 1 adaptation by full fine-tuning or LoRA yields strong gains on new documents but severe drops on earlier slices, i.e. negative backward transfer (Mekonnen et al., 25 Apr 2026). PAMT Stage 2 is intended to preserve earlier-slice retrieval behavior while keeping new-slice performance largely intact. After session 5 in the Expanded protocol, Full-FT–SPQ has AP 0, FWT1 2, and BWT 3, whereas PAMT–Full-FT–SPQ reaches AP 4, FWT5 6, and BWT 7 (Mekonnen et al., 25 Apr 2026). Full-FT–TU improves from AP 8 to 9 under PAMT, and BWT moves from 00 to 01. LoRA–SPQ rises from AP 02 to 03, and LoRA–TU from 04 to 05, again with substantially less negative BWT. The memory footprint is also explicitly bounded: PMH value rows satisfy 06 K on MS MARCO and 07 K on NQ, with updates restricted to 08 rows, corresponding to 09 M trainable parameters per session, while 10 of rows are protected.
5. Relation to MbPA and external-memory adaptation
MbPA provides a concrete mechanism that can be viewed through the lens of PAMT. It augments a standard parametric network with an episodic memory 11, where keys are produced by an embedding network 12 and values are labels or targets; at test time, a query 13 retrieves 14 nearest neighbors under Euclidean distance and forms kernel weights
15
The retrieved context defines a local MAP-style objective over adapted weights 16, with Gaussian prior centered at 17, and a one-step perturbation
18
Prediction is made with 19, after which the adaptation is discarded (Sprechmann et al., 2018). The paper’s own comparison states that this is “precisely MbPA” if PAMT is taken to mean memory-retrieved examples used to tune some weights before each prediction.
MbPA is empirically associated with fast, local adaptation in several regimes. On Permuted MNIST with 20 tasks and 10,000 examples each, it recovers old tasks from memory with only a few gradient steps and outperforms MLP and Elastic Weight Consolidation for most memory sizes (Sprechmann et al., 2018). On incremental ImageNet, the paper reports Top-1 accuracy of 20, 21, and 22 for novel classes after 23, 24, and 25 epochs respectively, outperforming parametric, mixture, and non-parametric baselines on several metrics. In language modelling, adding MbPA to an LSTM reduces PTB test perplexity from 26 to 27, and on WikiText-2 from 28 to 29 (Sprechmann et al., 2018).
PEMA is adjacent rather than identical to PAMT. It keeps a pre-trained LLM frozen except for its final LM head 30, stores a datastore of 31 pairs, and trains a low-rank adapter with matrices 32, 33, and 34 so that
35
Its Gradual Unrolling strategy mixes the adapter and PLM outputs as
36
with 37 decreasing over the generated sequence (Kim et al., 2023). Unlike MbPA, PEMA does not perform explicit nearest-neighbors lookup at inference; instead, the “memory” is encoded by learned adapter weights. This suggests a broader conceptual neighborhood in which PAMT-like systems differ chiefly in where memory resides and how it is queried: direct weight perturbation from retrieved exemplars, explicit memory-token composition, sparse parametric memory heads, or low-rank external-memory readers.
6. Limitations, misconceptions, and research directions
A common misconception is that PAMT necessarily means updating the main model weights during deployment. The cited formulations do not support that generalization. In the original robotic PAMT, the phenotype is reset from the fixed genotype at the start of every trial and temporary Hebbian changes are discarded at the end (Hammami et al., 5 Aug 2025). In MemSeg-Agent, test-time adaptation is carried by working-memory tokens rather than by backbone-weight changes, and federated learning updates static memory tensors instead of the SAM2-tiny backbone (Chen et al., 6 Mar 2026). In continual generative retrieval, Stage 2 freezes the backbone and routing and updates only selected PMH value rows (Mekonnen et al., 25 Apr 2026).
A second misconception is that PAMT denotes a single canonical update rule. The literature instead shows heterogeneous realizations. The robotic version uses a fitness-scaled Hebbian law with trace stabilization; MemSeg-Agent uses attention-weighted composition of static, few-shot, and working memories; MbPA performs a local MAP-style gradient correction from retrieved context; and continual generative retrieval uses product-key addressing plus value-only calibration under a row-selection policy (Hammami et al., 5 Aug 2025, Sprechmann et al., 2018, Mekonnen et al., 25 Apr 2026). This suggests that the unifying property is not a particular optimizer but the post hoc tuning of behavior through a memory-mediated substrate while preserving a stable base model.
The limitations are likewise domain-specific. In robotics, a static base rate 38 can cause over-adaptation under small or null environment changes, including the high-light case; the paper explicitly notes that the system should ideally detect novelty magnitude and scale 39 or disable plasticity when unnecessary (Hammami et al., 5 Aug 2025). Proposed extensions include automatic change detection via sensor novelty or a small spiking network, testing on richer sensory streams such as LiDAR or point clouds, and transferring the mechanism to multi-robot settings and other morphologies including drones and quadrupeds. In continual generative retrieval, the central problem is the stability–plasticity trade-off created by Stage 1 adaptation on new slices, and PAMT is presented as a memory-only stabilization stage rather than a full solution to sequential non-stationarity (Mekonnen et al., 25 Apr 2026). In segmentation, the emphasis is on communication economy, parameter efficiency, and online robustness to domain shift, with memory space proposed as the preferred locus of adaptation (Chen et al., 6 Mar 2026).
Taken together, these works suggest that PAMT is most useful when three conditions hold simultaneously: a stable pretrained or evolved substrate is already available, adaptation must occur after that substrate has been fixed, and unrestricted updating of the full parameter set is either undesirable or infeasible. Under those conditions, PAMT serves as an umbrella for mechanisms that preserve core knowledge while enabling local, often transient, post-adaptation behavior.