With regards to this phrase "checking the model’s input data prototype,"?
Can I understand a bit more about what this means?
I have been thinking about a package that takes a model object as input and generates a function that can validate any new input data for types, whether the categories are all there and where there are any nulls etc.
One issue is that the data could come to a deployed model in any format (json, xml, cvs, etc). Some data types might need to be re-encoded to be consistent with the training data. For example, we want to make sure that data ingested as character ends up being coerced into a factor with the correct factor levels. Similarly, date fields and time zones etc.
I don't think that we do it this way, but the idea is similar to what vec_cast() does.