This is a top-level function defined in the grinder library.