input: def sentiment_analyzer(text: str) -> dict:
      """ Analyzes the sentiment of a given text using the SentimentIntensityAnalyzer from
      the nltk library.
      The text is tokenized, stemmed, cleaned of punctuation, and stopwords before
      the sentiment analysis is performed.
  
      >>> sentiment_analyzer("I love this product! It's amazing.")
      {'neg': 0.0, 'neu': 0.167, 'pos': 0.833, 'compound': 0.7579}
  
      >>> sentiment_analyzer("This is terrible. I hate it.")
      {'neg': 0.625, 'neu': 0.375, 'pos': 0.0, 'compound': -0.5423}
      """
      pass
output:     
      from nltk.sentiment import SentimentIntensityAnalyzer
      from nltk.tokenize import word_tokenize
      from nltk.stem import PorterStemmer
      from nltk.corpus import stopwords
      import string
  
      sia = SentimentIntensityAnalyzer()
      stemmer = PorterStemmer()
      stop_words = set(stopwords.words('english'))
  
      # Tokenize the text
      tokens = word_tokenize(text.lower())
  
      # Remove punctuation and stopwords, and stem the tokens
      cleaned_tokens = [stemmer.stem(token) for token in tokens if token.isalnum() and token not in stop_words]
  
      # Join the cleaned tokens back into a single string
      cleaned_text = ' '.join(cleaned_tokens)
  
      # Perform sentiment analysis
      sentiment_scores = sia.polarity_scores(cleaned_text)
  
      return sentiment_scores
  