Refactor Scope to use struct instead of tuple