cursus.step_catalog.adapters.config_resolver¶
Config resolver adapters for backward compatibility.
This module provides adapters that maintain existing config resolver APIs during the migration from legacy discovery systems to the unified StepCatalog system.
- exception ResolutionError(message, failed_nodes=None, suggestions=None)[source]¶
Bases:
ExceptionFallback when the compiler exceptions module is unavailable.
- class StepConfigResolverAdapter(workspace_root=None, confidence_threshold=0.7)[source]¶
Bases:
objectEnhanced adapter maintaining backward compatibility with StepConfigResolver.
Replaces: src/cursus/core/compiler/config_resolver.py
This enhanced version includes essential legacy methods needed for production while leveraging the unified step catalog for superior discovery capabilities.
- JOB_TYPE_KEYWORDS = {'calibration': ['calibration', 'calib'], 'evaluation': ['evaluation', 'eval', 'test'], 'inference': ['inference', 'infer', 'predict'], 'training': ['training', 'train']}¶
- STEP_TYPE_PATTERNS = {'.*calibrat.*': ['ModelCalibration'], '.*currency.*': ['CurrencyConversion'], '.*data_load.*': ['CradleDataLoading'], '.*eval.*': ['XGBoostModelEval'], '.*hyperparam.*': ['HyperparameterPrep'], '.*model.*': ['XGBoostModel', 'PyTorchModel'], '.*packag.*': ['MIMSPackaging'], '.*payload.*': ['MIMSPayload'], '.*preprocess.*': ['TabularPreprocessing'], '.*regist.*': ['ModelRegistration'], '.*risk.*': ['RiskTableMapping'], '.*train.*': ['XGBoostTraining', 'PyTorchTraining', 'DummyTraining'], '.*transform.*': ['BatchTransform']}¶
- resolve_config_map(dag_nodes, available_configs, metadata=None)[source]¶
Resolve every DAG node to a config, or RAISE listing every node that cannot be resolved.
This is the compile-path entry point. It delegates each node to
_resolve_single_node()— the same safe matcherresolve_config_for_step/preview_resolutionuse — which raisesResolutionErroron a no-match and warns below the confidence threshold. Previously this method had its own weaker 3-tier loop whose tier-3 “first available config” silently bound any unmatched node tonext(iter(available_configs.values()))— compiling a structurally WRONG pipeline from an incomplete config (deep dive 2026-07-03). The fix unifies the two entry points on_resolve_single_nodeand turns “can’t resolve” into a loud failure that names EVERY unsatisfiable node, never a plausible-but-wrong binding.