Refactored cdoes for Programming Collective Intelligence