Scopes

bad branch name. 

Makes improvements to the scopes PR issued by @almassapargali