code: def test_world_adds_numbers_from_question(self):
      question_tokens = [
          Token(x)
          for x in [
              "what",
              "2007",
              "2,107",
              "0.2",
              "1800s",
              "1950s",
              "?",
          ]
      ]
      table_kg = TableQuestionKnowledgeGraph.read_from_file(
          self.FIXTURES_ROOT
          / "data"
          / "wikitables"
          / "sample_table.tsv",
          question_tokens,
      )
      world = WikiTablesWorld(table_kg)
      valid_actions = world.get_valid_actions()
      assert "n -> 2007" in valid_actions["n"]
      assert "n -> 2107" in valid_actions["n"]
  
      # It appears that sempre normalizes floating point numbers.
      assert "n -> 0.200" in valid_actions["n"]
  
      # We want to add the end-points to things like "1800s": 1800 and 1900.
      assert "n -> 1800" in valid_actions["n"]
      assert "n -> 1900" in valid_actions["n"]
      assert "n -> 1950" in valid_actions["n"]
      assert "n -> 1960" in valid_actions["n"]
  
imports: from __future__ import with_statement
  from __future__ import division
  from __future__ import absolute_import
  from __future__ import print_function
  import pytest
  from allennlp.common.testing import AllenNlpTestCase
  from allennlp.data.tokenizers import Token
  from allennlp.semparse import ParsingError
  from allennlp.semparse.contexts import TableQuestionKnowledgeGraph
  from allennlp.semparse.worlds import WikiTablesWorld
label_desc: Use image node_id 9 for calling the TestWikiTablesWorld obj's underlying member method code with example usage: obj.test_world_adds_numbers_from_question() without return types