code: def plot_quantile_forecast(
      query_past: List[np.ndarray],
      query_future: List[np.ndarray],
      pred: List[np.ndarray],
      quantiles: List[str],
  ) -> plt.Figure:
      """
      Plots the provided forecasts for each sample with confidence intervals using all provided quantiles.
  
      Parameters
      ----------
      query_past: List[np.ndarray] of length n_samples, each array has shape [context length]
          The past query which the model uses to make a prediction.
      query_future: List[np.ndarray] of length n_samples, each array has shape [prediction horizon length]
          The ground truth for the forecast.
      pred: List[np.ndarray], of length n_samples, each array has shape  [prediction horizon length, n_quantiles]
          The prediction of the model.
      quantiles: List[float], shape[n_quantiles,]
  
      Returns
      -------
      plt.figure.Figure
          A plot containing one subplot for each sample. Each subplot displays the ground truth, predicted confidence
          intervals and the predicted median.
      """
      n_samples = len(query_past)
      fig, subs = plt.subplots(n_samples, figsize=(10, 4 * n_samples))
      if n_samples > 1:
          for i in range(n_samples):
              subs[i].set_title(f"sample {i}")
              _plot_quantile_forecast(
                  subs[i],
                  query_past[i],
                  query_future[i],
                  pred[i],
                  quantiles,
              )
      else:
          i = 0
          subs.set_title(f"sample {i}")
          _plot_quantile_forecast(
              subs, query_past[i], query_future[i], pred[i], quantiles
          )
      return fig
  
imports: from typing import List
  import numpy
  import matplotlib.pyplot
label_desc: Use image node_id 2 for calling a global function with example usage: plot_quantile_forecast(query_past, query_future, pred, quantiles) and returns: fig