mirror of
https://github.com/elder-plinius/OBLITERATUS.git
synced 2026-06-08 15:23:59 +02:00
64 lines
2.2 KiB
Python
64 lines
2.2 KiB
Python
"""Obliteratus — Master Ablation Suite for HuggingFace transformers."""
|
|
|
|
__version__ = "0.1.2"
|
|
|
|
# Lazy imports for the main pipeline classes
|
|
__all__ = [
|
|
"AbliterationPipeline",
|
|
"InformedAbliterationPipeline",
|
|
"set_seed",
|
|
"run_sweep",
|
|
"SweepConfig",
|
|
"SweepResult",
|
|
"save_contribution",
|
|
"load_contributions",
|
|
"aggregate_results",
|
|
"TourneyRunner",
|
|
"TourneyResult",
|
|
"get_adaptive_recommendation",
|
|
"AdaptiveRecommendation",
|
|
]
|
|
|
|
|
|
def __getattr__(name):
|
|
if name == "AbliterationPipeline":
|
|
from obliteratus.abliterate import AbliterationPipeline
|
|
return AbliterationPipeline
|
|
if name == "InformedAbliterationPipeline":
|
|
from obliteratus.informed_pipeline import InformedAbliterationPipeline
|
|
return InformedAbliterationPipeline
|
|
if name == "set_seed":
|
|
from obliteratus.reproducibility import set_seed
|
|
return set_seed
|
|
if name == "run_sweep":
|
|
from obliteratus.sweep import run_sweep
|
|
return run_sweep
|
|
if name == "SweepConfig":
|
|
from obliteratus.sweep import SweepConfig
|
|
return SweepConfig
|
|
if name == "SweepResult":
|
|
from obliteratus.sweep import SweepResult
|
|
return SweepResult
|
|
if name == "save_contribution":
|
|
from obliteratus.community import save_contribution
|
|
return save_contribution
|
|
if name == "load_contributions":
|
|
from obliteratus.community import load_contributions
|
|
return load_contributions
|
|
if name == "aggregate_results":
|
|
from obliteratus.community import aggregate_results
|
|
return aggregate_results
|
|
if name == "TourneyRunner":
|
|
from obliteratus.tourney import TourneyRunner
|
|
return TourneyRunner
|
|
if name == "TourneyResult":
|
|
from obliteratus.tourney import TourneyResult
|
|
return TourneyResult
|
|
if name == "get_adaptive_recommendation":
|
|
from obliteratus.adaptive_defaults import get_adaptive_recommendation
|
|
return get_adaptive_recommendation
|
|
if name == "AdaptiveRecommendation":
|
|
from obliteratus.adaptive_defaults import AdaptiveRecommendation
|
|
return AdaptiveRecommendation
|
|
raise AttributeError(f"module {__name__!r} has no attribute {name!r}")
|