class_docstr: Salience map clustering.
class_docstr_tok: ["Salience","map","clustering","."]
code: def config_spec(self) -> types.Spec:
      return {
          SALIENCE_MAPPER_KEY: types.CategoryLabel(
              required=True, vocab=list(self.salience_mappers.keys())
          ),
          N_CLUSTERS_KEY: types.Scalar(
              min_val=2, max_val=100, default=10, step=1
          ),
          TOP_K_TOKENS_KEY: types.Scalar(
              min_val=1, max_val=20, default=5, step=1
          ),
          N_TOKENS_TO_DISPLAY_KEY: types.Scalar(
              min_val=5, max_val=50, default=10, step=1
          ),
          SEED_KEY: types.TextSegment(default="0"),
      }
  
file_path: lit/lit_nlp/components/salience_clustering.py
imports: from collections.abc import Sequence
  from typing import Optional
  from lit_nlp.api import components
  from lit_nlp.api import dataset
  from lit_nlp.api import model
  from lit_nlp.api import types
  import numpy
  from sklearn import cluster
label_desc: Use image node_id 7 for calling the SalienceClustering obj's underlying member method code with example usage: obj.config_spec() and returns: dict