Profile cleanup and refactor to nested Metrics model.
Save step index to use when ordering profile steps.