code: def generate_column_labels(full_pipeline, numeric_cols, text_cols):
      # Check if one hot encoding was performed
      if "cat" in full_pipeline.named_transformers_:
          # If ca was used
          if isinstance(
              full_pipeline.named_transformers_["cat"][-1], CA
          ):
              ca = full_pipeline.named_transformers_["cat"][-1]
              encoded_cols = [
                  f"CA_{x}" for x in range(len(ca.eigenvalues_))
              ]
              cols = [*list(numeric_cols), *encoded_cols, *text_cols]
  
          else:
              try:
                  encoded_cols = full_pipeline.named_transformers_[
                      "cat"
                  ]["one_hotencoder"].get_feature_names()
                  cols = [
                      *list(numeric_cols),
                      *encoded_cols,
                      *text_cols,
                  ]
  
              except Exception as error:
                  # For debugging only
                  (error)
                  cols = list(numeric_cols)
  
          return cols
      else:
          return [*list(numeric_cols), *text_cols]
  
imports: import numpy
  import pandas
  from sklearn.compose import ColumnTransformer
  from sklearn.feature_extraction.text import TfidfVectorizer
  from sklearn.pipeline import Pipeline
  from prince.ca import CA
  from nltk.stem import WordNetLemmatizer
  from nltk.tokenize import word_tokenize
  from nltk.corpus import stopwords
  from autocorrect import Speller
  from sklearn.model_selection import train_test_split
  from sklearn.impute import SimpleImputer
  from sklearn.preprocessing import OneHotEncoder, StandardScaler, FunctionTransformer, LabelEncoder
  from pandas.api.types import is_numeric_dtype
  import warnings
label_desc: Use image node_id 7 for calling a global function with example usage: generate_column_labels(full_pipeline, numeric_cols, text_cols) and returns: cols, list