def get_subset_def_data_for_eval_key(
        self, ctx, eval_key, _, name, subset_def
    ):
        """
        Builds and returns an execution cache key for each type of scenario.
        - eval key + name + type + subset definition
        """
        scenario_type = self.get_scenario_type(ctx.params)

        if scenario_type == ScenarioType.CUSTOM_CODE:
            key = [
                "sample-distribution-data",
                eval_key,
                name,
                scenario_type,
                str(subset_def),
            ]
        elif scenario_type == ScenarioType.VIEW:
            key = [
                "sample-distribution-data",
                eval_key,
                name,
                scenario_type,
                subset_def.get("view", ""),
            ]
        else:
            if isinstance(subset_def, list):
                subset_def = subset_def[0]

            key = [
                "sample-distribution-data",
                eval_key,
                name,
                scenario_type,
                str(subset_def),
            ]

        return key

        Builds and returns an execution cache key for each type of scenario.
        - eval key + name + type + subset definition
        
plugins/operators/model_evaluation/__init__.py