HMC assumes a static model structure, but can deal with models like gaussian mixture models or HMMs where the discrete variables can be enumerated in parallel. Even then, sampling may be too slow and impractical for medium to large models. I would suggest looking at Variational Inference for this. You might find this discussion useful - Variational Inference for Dirichlet process clustering - #12 by fehiepsi.