code: def interact_slice(
      model: ModelBridge,
      generator_runs_dict: TNullableGeneratorRunsDict = None,
      relative: bool = False,
      density: int = 50,
      slice_values: Optional[Dict[str, Any]] = None,
      fixed_features: Optional[ObservationFeatures] = None,
      trial_index: Optional[int] = None,
  ) -> AxPlotConfig:
      """Create interactive plot with predictions for a 1-d slice of the parameter
      space.
  
      Args:
          model: ModelBridge that contains model for predictions
          generator_runs_dict: A dictionary {name: generator run} of generator runs
              whose arms will be plotted, if they lie in the slice.
          relative: Predictions relative to status quo
          density: Number of points along slice to evaluate predictions.
          slice_values: A dictionary {name: val} for the fixed values of the
              other parameters. If not provided, then the status quo values will
              be used if there is a status quo, otherwise the mean of numeric
              parameters or the mode of choice parameters. Ignored if
              fixed_features is specified.
          fixed_features: An ObservationFeatures object containing the values of
              features (including non-parameter features like context) to be set
              in the slice.
  
      Returns:
          AxPlotConfig: interactive plot of objective vs. parameter
      """
  
      return AxPlotConfig(
          data=interact_slice_plotly(
              model=model,
              generator_runs_dict=generator_runs_dict,
              relative=relative,
              density=density,
              slice_values=slice_values,
              fixed_features=fixed_features,
              trial_index=trial_index,
          ),
          plot_type=AxPlotTypes.GENERIC,
      )
  
file_path: Ax/ax/plot/slice.py
imports: from copy import deepcopy
  from typing import Any, Dict, List, Optional, Tuple, Union
  import numpy
  from ax.core.observation import ObservationFeatures
  from ax.modelbridge.base import ModelBridge
  from ax.plot.base import AxPlotConfig, AxPlotTypes, PlotData
  from ax.plot.helper import axis_range, get_fixed_values, get_grid_for_parameter, get_plot_data, get_range_parameter, get_range_parameters, slice_config_to_trace, TNullableGeneratorRunsDict
  from ax.utils.common.typeutils import not_none
  from plotly import graph_objs
label_desc: Use image node_id 5 for calling a global function with example usage: interact_slice(model, generator_runs_dict, relative, density, slice_values, fixed_features, trial_index) and returns: AxPlotConfig