code: def __init__(
      self,
      api_key: Optional[str] = None,
      model: str = "gpt-3.5-turbo",
      streaming_callback: Optional[
          Callable[[StreamingChunk], None]
      ] = None,
      api_base_url: Optional[str] = None,
      organization: Optional[str] = None,
      generation_kwargs: Optional[Dict[str, Any]] = None,
  ):
      warnings.warn(
          "GPTChatGenerator is deprecated and will be removed in the next beta release. "
          "Please use OpenAIChatGenerator instead.",
          UserWarning,
          stacklevel=2,
      )
      super().__init__(
          api_key=api_key,
          model=model,
          streaming_callback=streaming_callback,
          api_base_url=api_base_url,
          organization=organization,
          generation_kwargs=generation_kwargs,
      )
  
imports: import copy
  import dataclasses
  import json
  import logging
  import warnings
  from typing import Optional, List, Callable, Dict, Any, Union
  from openai import OpenAI, Stream
  from openai.types.chat import ChatCompletionChunk, ChatCompletion, ChatCompletionMessage
  from openai.types.chat.chat_completion import Choice
  from openai.types.chat.chat_completion_chunk import Choice
  from haystack import component, default_from_dict, default_to_dict
  from haystack.components.generators.utils import serialize_callback_handler, deserialize_callback_handler
  from haystack.dataclasses import StreamingChunk, ChatMessage
label_desc: Use image node_id 1 to create a new GPTChatGenerator object from inherited base classes: OpenAIChatGenerator with example: obj = GPTChatGenerator(api_key, model, streaming_callback, api_base_url, organization, generation_kwargs)