harbor run -t openthoughts/tasktrove-mix-h8-adversarial-tests-v2-mix-h8-adversarial-1234harbor download openthoughts/tasktrove-mix-h8-adversarial-tests-v2-mix-h8-adversarial-1234Task description
Goal Implement a minimal imblearn-compatible transformer named InstanceHardnessThreshold that can be imported as: from imblearn.under_sampling import InstanceHardnessThreshold and used by tests as shown. The implementation must live in a Python package named imblearn under the /app directory (i.e., either as /app/imblearn.py or, preferably to match imports in tests, as /app/imblearn/ with an init.py and a submodule under_sampling.py). The tests rely on the class behaving exactly as described below.
What to implement
estimator").estimator" during fit_resample(X, y)estimator" when estimator lacks predict_proba.By implementing the described class and package layout, the tests should pass, and the agent will have a clear, self-contained, and actionable task to complete.