refactor habitat lookup methods