code: def generate(
      self,
      query_name: str,
      add_postprocessing_operations: bool = False,
      add_time_offsets: bool = False,
      table_id=1,
      table_type="table",
      form_data: Optional[dict[str, Any]] = None,
  ) -> dict[str, Any]:
      form_data = form_data or {}
      table_name = query_name.split(":")[0]
      table = self.get_table(table_name, table_id, table_type)
      return {
          "datasource": {"id": table.id, "type": table.type},
          "queries": [
              get_query_object(
                  query_name,
                  add_postprocessing_operations,
                  add_time_offsets,
              )
          ],
          "result_type": ChartDataResultType.FULL,
          "form_data": form_data,
      }
  
file_path: superset/tests/common/query_context_generator.py
imports: import copy
  import dataclasses
  from typing import Any, Optional
  from superset.common.chart_data import ChartDataResultType
  from superset.utils.core import AnnotationType, DTTM_ALIAS
label_desc: Use image node_id 1 for calling the QueryContextGenerator obj's underlying member method code with example usage: obj.generate(query_name, add_postprocessing_operations, add_time_offsets, table_id, table_type, form_data) and returns: dict