Document with per-term distribution over topics. The assignments in
termTheta and the totals in theta must be kept in sync by the caller.
Duplicate observations are collapsed into a single termIndex with termCount.