refactor systems