code: def run_test_gbm_category(vocab_size, tmpdir, backend_config):
      """Test that the GBM model can train and predict a categorical output (multiclass classification)."""
      input_features = [
          number_feature(),
          category_feature(encoder={"reduce_output": "sum"}),
      ]
      output_feature = category_feature(
          decoder={"vocab_size": vocab_size}
      )
      output_features = [output_feature]
  
      preds, _ = _train_and_predict_gbm(
          input_features, output_features, tmpdir, backend_config
      )
  
      prob_col = preds[output_feature["name"] + "_probabilities"]
      if backend_config["type"] == "ray":
          prob_col = prob_col.compute()
      assert len(prob_col.iloc[0]) == vocab_size
      assert prob_col.apply(sum).mean() == pytest.approx(1.0)
  
imports: import os
  import numpy
  import pytest
  from ludwig.api import LudwigModel
  from ludwig.constants import INPUT_FEATURES, MODEL_TYPE, OUTPUT_FEATURES, TRAINER
  from ludwig.error import ConfigValidationError
  from ludwig.schema.model_types.base import ModelConfig
  from tests.integration_tests import synthetic_test_data
  from tests.integration_tests.utils import binary_feature
  from tests.integration_tests.utils import category_feature
  from tests.integration_tests.utils import generate_data, number_feature, text_feature
label_desc: Use image node_id 11 for calling a global function with example usage: run_test_gbm_category(vocab_size, tmpdir, backend_config) without return types