  The offline software framework of the LHCb experiment has undergone a
significant overhaul to tackle the data processing challenges that will arise
in the upcoming Run 3 and Run 4 of the Large Hadron Collider. This paper
introduces FunTuple, a novel component developed for offline data processing
within the LHCb experiment. This component enables the computation and storage
of a diverse range of observables for both reconstructed and simulated events
by leveraging on the tools initially developed for the trigger system. This
feature is crucial for ensuring consistency between trigger-computed and
offline-analysed observables. The component and its tool suite offer users
flexibility to customise stored observables, and its reliability is validated
through a full-coverage set of rigorous unit tests. This paper comprehensively
explores FunTuple's design, interface, interaction with other algorithms, and
its role in facilitating offline data processing for the LHCb experiment for
the next decade and beyond.
