code: def __init__(self):
      super().__init__()
  
      self.model = None
      self.tokenizer = None
      self.context = None
      self.prefill = prefill
      self.decode_one_token = decode_one_token
      self.initialized = False
      self.device = torch.device("cpu")
      self.prompt_length = 0
      self.local_rank = 0
      self.stream = False
      self.is_speculative = False
      self.draft_model = None
      self.speculate_k = 0
  
file_path: serve/examples/large_models/gpt_fast/handler.py
imports: import json
  import logging
  import time
  from pathlib import Path
  import torch
  from generate import Transformer, _load_model, decode_one_token, encode_tokens, logits_to_probs, maybe_init_dist, model_forward, multinomial_sample_one_no_sync, prefill
  from sentencepiece import SentencePieceProcessor
  from ts.handler_utils.timer import timed
  from ts.handler_utils.utils import send_intermediate_predict_response
  from ts.torch_handler.base_handler import BaseHandler
label_desc: Use image node_id 1 to create a new GptHandler object from inherited base classes: BaseHandler with example: obj = GptHandler()