  We present Diffstar, a smooth parametric model for the in-situ star formation
history (SFH) of galaxies. Diffstar is distinct from conventional SFH models
that are used to interpret the spectral energy distribution (SED) of an
observed galaxy, because our model is parametrized directly in terms of basic
features of galaxy formation physics. The Diffstar model assumes that star
formation is fueled by the accretion of gas into the dark matter halo of the
galaxy, and at the foundation of Diffstar is a parametric model for halo mass
assembly, Diffmah. We include parametrized ingredients for the fraction of
accreted gas that is eventually transformed into stars, $\epsilon_{\rm ms},$
and for the timescale over which this transformation occurs, $\tau_{\rm cons};$
some galaxies in Diffstar experience a quenching event at time $t_{\rm q},$ and
may subsequently experience rejuvenated star formation. We fit the SFHs of
galaxies predicted by the IllustrisTNG (TNG) and UniverseMachine (UM)
simulations with the Diffstar parameterization, and show that our model is
sufficiently flexible to describe the average stellar mass histories of
galaxies in both simulations with an accuracy of $\sim0.1$ dex across most of
cosmic time. We use Diffstar to compare TNG to UM in common physical terms,
finding that: (i) star formation in UM is less efficient and burstier relative
to TNG; (ii) galaxies in UM have longer gas consumption timescales, $\tau_{\rm
cons}$, relative to TNG; (iii) rejuvenated star formation is ubiquitous in UM,
whereas quenched TNG galaxies rarely experience sustained rejuvenation; and
(iv) in both simulations, the distributions of $\epsilon_{\rm ms}$, $\tau_{\rm
cons}$, and $t_{\rm q}$ share a common characteristic dependence upon halo
mass, and present significant correlations with halo assembly history.
[Abridged]
