new architecture for better scope