  In a previous paper we constructed $\textit{higher}$ theta series for unitary
groups over function fields, and conjectured their modularity properties. Here
we prove the generic modularity of the $\ell$-adic realization of higher theta
series in cohomology. The proof debuts a new type of Fourier transform,
occurring on the Borel-Moore homology of moduli spaces for shtuka-type objects,
that we call the $\textit{arithmetic Fourier transform}$. Another novelty in
the argument is a $\textit{sheaf-cycle correspondence}$ extending the classical
sheaf-function correspondence, which facilitates the deployment of
sheaf-theoretic methods to analyze algebraic cycles. Although the modularity
property is a statement within classical algebraic geometry, the proof relies
on derived algebraic geometry, especially a nascent theory of $\textit{derived
Fourier analysis}$ on derived vector bundles, which we develop.
