Consolidate risk code into RunRisk.scala