Move relevant constants to discover function. Add __repr__