  Hybrid models composing mechanistic ODE-based dynamics with flexible and
expressive neural network components have grown rapidly in popularity,
especially in scientific domains where such ODE-based modeling offers important
interpretability and validated causal grounding (e.g., for counterfactual
reasoning). The incorporation of mechanistic models also provides inductive
bias in standard blackbox modeling approaches, critical when learning from
small datasets or partially observed, complex systems. Unfortunately, as the
hybrid models become more flexible, the causal grounding provided by the
mechanistic model can quickly be lost. We address this problem by leveraging
another common source of domain knowledge: \emph{ranking} of treatment effects
for a set of interventions, even if the precise treatment effect is unknown. We
encode this information in a \emph{causal loss} that we combine with the
standard predictive loss to arrive at a \emph{hybrid loss} that biases our
learning towards causally valid hybrid models. We demonstrate our ability to
achieve a win-win, state-of-the-art predictive performance \emph{and} causal
validity, in the challenging task of modeling glucose dynamics post-exercise in
individuals with type 1 diabetes.
