  The addressability of parallel spatially multimode quantum memory for light
allows one to control independent collective spin waves within the same cold
atomic ensemble. Generally speaking, there are transverse and longitudinal
degrees of freedom of the memory that one can address by a proper choice of the
pump (control) field spatial pattern. Here we concentrate on the mutual
evolution and transformation of quantum states of the longitudinal modes of
collective spin coherence in the cavity-based memory scheme. We assume that
these modes are coherently controlled by the pump waves of the on--demand
transverse profile, that is, by the superpositions of waves propagating in the
directions, close to orthogonal to the cavity axis. By the write-in, this
allows one to couple a time sequence of the incoming quantized signals to a
given set of superpositions of orthogonal spin waves. By the readout, one can
retrieve quantum states of the collective spin waves that are controllable
superpositions of the initial ones and are on demand coupled to the output
signal sequence. In general case, the memory is able to operate as a
controllable delayed multi-port beamsplitter, capable of transformation of the
delays, the durations and time shapes of signals in the sequence.
  We elaborate the theory of such light--matter interface for the spatially
multivariate cavity-based off--resonant Raman--type quantum memory. Since in
order to speed up the manipulation of complex signals in multivariate memories
it might be of interest to store relatively short light pulses of a given time
shape, we also address some issues of the cavity-based memory operation beyond
the bad cavity limit.
