Text this: Construction and optimization of a smart classroom system for emotional computing