Say I have a neural network that predicts whether a restaurant will be successful in a given neighborhood and uses the following features:

  • type of food served
  • type of music played
  • type of decoration
  • neighborhood name
  • average neighborhood revenue
  • average lunch price
  • ...

All categorical features are embedded in order to preserve meaningful relationships between different values.

The problem: several of these variables might be unknown/unavailable at inference time. For instance, I may want to predict the success of a restaurant for which I don't know about the type of decoration.

Ideally, in theory, I'd like the model to perform as if the entire category didn't exist when a given category is missing. But I don't want to build 45 different models to account for the different combinations of possible missing values.

Some ways I thought about for addressing this:

  • simply have a category "unknown", however the training samples with an "unknown" value might (very likely) be highly biased in one way or another. What if, unknowingly to us, almost all of the "unknown" training data has "lounge" decoration but at inference time, we predict a restaurant that has "classical" decoration (but unknown to us)?

  • in the training set, duplicate a representative fraction of rows and set the variable as "unknown" for this value in the duplicated rows — the issue is that if we have say 15 different variables that might be unknown, the combinatorial explodes

  • at inference time, set the embedding vector for the unknown category equal to the average embedding vector values — however, the "average" embedded vector might not exist and the average values might also represent a specific category, rather than conveying a notion of "unknown"

  • last idea I'm thinking of (and the one I'm currently leaning towards) is, if a categorical variable is unknown, infer multiple occurrences of the same restaurant but with a mix of different values for the unknown variable (e.g. try with 10 different values for "type of decoration") and average the predictions — this sounds a bit cumbersome though especially if multiple variables are unknown

What would be some interesting and effective ways to handle this problem? Is there some literature available on the topic?



Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.