Formula

General Recurrent Formula for Memory Update

The update process for a memory component in a memory-based attention mechanism can be described by a general recurrent function. At each time step i, the new memory state, Mem, is computed by a function f. This function takes the current key-value pair, (ki,vi)(\mathbf{k}_i, \mathbf{v}_i), and the previous memory state, MempreMem_{pre}, as its inputs. The formula is expressed as: Mem=f((ki,vi),Mempre)Mem = f((\mathbf{k}_i, \mathbf{v}_i), Mem_{pre}) This general framework can be instantiated with specific models for the update function f, such as a recurrent neural network or a simple moving average.

Image 0

0

1

Updated 2026-04-23

Contributors are:

Who are from:

Tags

Ch.2 Generative Models - Foundations of Large Language Models

Foundations of Large Language Models

Foundations of Large Language Models Course

Computing Sciences