toolkits refactor