  We give a comprehensive treatment of the transformation laws of theta
functions from an algebro-geometric perspective, that is, in terms of moduli of
abelian schemes. This is accomplished by introducing geometric notions of
theta-descent structures, metaplectic stacks, and bundles of half-forms, whose
analytic incarnations underlie different aspects of the classical
transformation laws. As an application, we lay the foundations for a geometric
theory of modular forms of half-integral weight and, more generally, for
modular forms taking values in the Weil representation. We discuss further
applications to the algebraic theory of Jacobi forms and to the theory of
determinant bundles of abelian schemes.
