code: def calculate_first_sets(
      self, grammar_source: str
  ) -> Dict[str, Set[str]]:
      grammar: Grammar = parse_string(grammar_source, GrammarParser)
      return FirstSetCalculator(grammar.rules).calculate()
  
imports: import unittest
  from test import test_tools
  from typing import Dict, Set
label_desc: Use image node_id 1 for calling the TestFirstSets obj's underlying member method code with example usage: obj.calculate_first_sets(grammar_source) and returns: FirstSetCalculator