def METHOD_NAME(cls, obj: SearchSpace) -> "NlpSearchSpace":
    return cls(
        gradient_accumulation_steps=(
            obj.gradient_accumulation_steps if hasattr(obj, "gradient_accumulation_steps") else None
        ),
        learning_rate=obj.learning_rate if hasattr(obj, "learning_rate") else None,
        learning_rate_scheduler=obj.learning_rate_scheduler if hasattr(obj, "learning_rate_scheduler") else None,
        model_name=obj.model_name if hasattr(obj, "model_name") else None,
        number_of_epochs=obj.number_of_epochs if hasattr(obj, "number_of_epochs") else None,
        training_batch_size=obj.training_batch_size if hasattr(obj, "training_batch_size") else None,
        validation_batch_size=obj.validation_batch_size if hasattr(obj, "validation_batch_size") else None,
        warmup_ratio=obj.warmup_ratio if hasattr(obj, "warmup_ratio") else None,
        weight_decay=obj.weight_decay if hasattr(obj, "weight_decay") else None,
    )