class_docstr: This class subclasses redis-py's `Redis` and implements RedisTimeSeries's
  commands (prefixed with "ts").
  The client allows to interact with RedisTimeSeries and use all of it's
  functionality.
docstr: Create a new RedisTimeSeries client.
docstr_tok: ["Create","a","new","RedisTimeSeries","client","."]
code: def __init__(self, client=None, **kwargs):
      """Create a new RedisTimeSeries client."""
      # Set the module commands' callbacks
      self._MODULE_CALLBACKS = {
          ALTER_CMD: bool_ok,
          CREATE_CMD: bool_ok,
          CREATERULE_CMD: bool_ok,
          DELETERULE_CMD: bool_ok,
      }
  
      _RESP2_MODULE_CALLBACKS = {
          DEL_CMD: int,
          GET_CMD: parse_get,
          INFO_CMD: TSInfo,
          MGET_CMD: parse_m_get,
          MRANGE_CMD: parse_m_range,
          MREVRANGE_CMD: parse_m_range,
          RANGE_CMD: parse_range,
          REVRANGE_CMD: parse_range,
          QUERYINDEX_CMD: parse_to_list,
      }
      _RESP3_MODULE_CALLBACKS = {}
  
      self.client = client
      self.execute_command = client.execute_command
  
      if get_protocol_version(self.client) in ["3", 3]:
          self._MODULE_CALLBACKS.update(_RESP3_MODULE_CALLBACKS)
      else:
          self._MODULE_CALLBACKS.update(_RESP2_MODULE_CALLBACKS)
  
      for k, v in self._MODULE_CALLBACKS.items():
          self.client.set_response_callback(k, v)
  
file_path: redis-py/redis/commands/timeseries/__init__.py
imports: import redis
  from redis._parsers.helpers import bool_ok
  from ..helpers import get_protocol_version, parse_to_list
  from .commands import ALTER_CMD, CREATE_CMD, CREATERULE_CMD, DEL_CMD, DELETERULE_CMD, GET_CMD, INFO_CMD, MGET_CMD, MRANGE_CMD, MREVRANGE_CMD, QUERYINDEX_CMD, RANGE_CMD, REVRANGE_CMD, TimeSeriesCommands
  from .info import TSInfo
  from .utils import parse_get, parse_m_get, parse_m_range, parse_range
label_desc: Use image node_id 1 to create a new TimeSeries object from inherited base classes: TimeSeriesCommands with example: obj = TimeSeries(client)