Refactor architecture.