Generalized Task Markets for Human and Machine Computation