class_docstr: Tversky index
  
  https://en.wikipedia.org/wiki/Tversky_index
  https://github.com/Yomguithereal/talisman/blob/master/src/metrics/tversky.js
class_docstr_tok: ["Tversky","index","https",":","\/\/en.wikipedia.org\/wiki\/Tversky_index","https",":","\/\/github.com\/Yomguithereal\/talisman\/blob\/master\/src\/metrics\/tversky.js"]
code: def __call__(self, *sequences: Sequence) -> float:
      quick_result = self.quick_answer(*sequences)
      if quick_result is not None:
          return quick_result
  
      sequences = self._get_counters(*sequences)  # sets
      intersection = self._intersect_counters(*sequences)  # set
      intersection = self._count_counters(intersection)  # int
      sequences = [self._count_counters(s) for s in sequences]  # ints
      ks = list(islice(self.ks, len(sequences)))
  
      if len(sequences) != 2 or self.bias is None:
          result = intersection
          for k, s in zip(ks, sequences):
              result += k * (s - intersection)
          return intersection / result
  
      s1, s2 = sequences
      alpha, beta = ks
      a_val = min([s1, s2])
      b_val = max([s1, s2])
      c_val = intersection + self.bias
      result = alpha * beta * (a_val - b_val) + b_val * beta
      return c_val / (result + c_val)
  
imports: from __future__ import annotations
  from functools import reduce
  from itertools import islice, permutations, repeat
  from math import log
  from typing import Sequence
  from .base import Base, BaseSimilarity
  from .edit_based import DamerauLevenshtein
label_desc: Use image node_id 3 for calling the Tversky obj's underlying member method code with example usage: obj.__call__() and returns: unknown, quick_result, unknown