Factor decider out of workflow.swf