The name of this function makes me think it yields a class (we have a records class in backdrop.core) but it doesn't. Maybe worth renaming this to be clearer about what it does.