Use slots for triple/resource/missing.

Memory usage optimization