code: def test_predict_output_when_categorical_features_native_implementation_LGBMRegressor():
      """
      Test predict output when using LGBMRegressor and categorical variables.
      """
      df_exog = pd.DataFrame(
          {
              "exog_1": exog_categorical,
              "exog_2": ["a", "b", "c", "d", "e"] * 10,
              "exog_3": pd.Categorical(["F", "G", "H", "I", "J"] * 10),
          }
      )
  
      exog_predict = df_exog.copy()
      exog_predict.index = pd.RangeIndex(start=50, stop=100)
  
      categorical_features = df_exog.select_dtypes(
          exclude=[np.number]
      ).columns.tolist()
      transformer_exog = make_column_transformer(
          (
              OrdinalEncoder(
                  dtype=int,
                  handle_unknown="use_encoded_value",
                  unknown_value=-1,
                  encoded_missing_value=-1,
              ),
              categorical_features,
          ),
          remainder="passthrough",
          verbose_feature_names_out=False,
      ).set_output(transform="pandas")
  
      forecaster = ForecasterAutoreg(
          regressor=LGBMRegressor(random_state=123),
          lags=5,
          transformer_y=None,
          transformer_exog=transformer_exog,
          fit_kwargs={"categorical_feature": categorical_features},
      )
      forecaster.fit(y=y_categorical, exog=df_exog)
      predictions = forecaster.predict(steps=10, exog=exog_predict)
  
      expected = pd.Series(
          data=np.array(
              [
                  0.5857033,
                  0.3894503,
                  0.45053399,
                  0.49686551,
                  0.45887492,
                  0.51481068,
                  0.5857033,
                  0.3894503,
                  0.45053399,
                  0.48818584,
              ]
          ),
          index=pd.RangeIndex(start=50, stop=60, step=1),
          name="pred",
      )
  
      pd.testing.assert_series_equal(predictions, expected)
  
imports: import re
  import pytest
  import numpy
  import pandas
  from sklearn.exceptions import NotFittedError
  from skforecast.ForecasterAutoreg import ForecasterAutoreg
  from skforecast.preprocessing import TimeSeriesDifferentiator
  from sklearn.compose import ColumnTransformer
  from sklearn.preprocessing import StandardScaler
  from sklearn.preprocessing import OneHotEncoder
  from sklearn.preprocessing import OrdinalEncoder
  from sklearn.preprocessing import FunctionTransformer
  from sklearn.compose import make_column_transformer
  from sklearn.compose import make_column_selector
  from sklearn.pipeline import make_pipeline
  from sklearn.linear_model import LinearRegression
  from sklearn.ensemble import HistGradientBoostingRegressor
  from lightgbm import LGBMRegressor
  from .fixtures_ForecasterAutoreg import y
  from .fixtures_ForecasterAutoreg import exog
  from .fixtures_ForecasterAutoreg import data
label_desc: Use image node_id 8 for calling a global function with example usage: test_predict_output_when_categorical_features_native_implementation_LGBMRegressor() without return types