Provisional: refactor costing stuff