code: def generate_sbi_config(num_pbs: int = 3, project: str = 'sip',
                          programme_block: str = 'sip_demos',
                          pb_config: Union[dict, List[dict]] = None,
                          workflow_config:
                          Union[dict, List[dict]] = None,
                          register_workflows=False) -> dict:
      
      if isinstance(workflow_config, dict):
          workflow_config = [workflow_config]
      if isinstance(pb_config, dict):
          pb_config = [pb_config]
      utc_now = datetime.datetime.utcnow()
      pb_list = []
      for i in range(num_pbs):
          pb_id = ProcessingBlock.get_id(utc_now)
          if workflow_config is not None:
              _workflow_config = workflow_config[i]
          else:
              _workflow_config = None
          if pb_config is not None:
              _pb_config = pb_config[i]
          else:
              _pb_config = None
          pb_dict = generate_pb_config(pb_id, _pb_config, _workflow_config)
          pb_list.append(pb_dict)
      sbi_config = dict(
          id=SchedulingBlockInstance.get_id(utc_now, project),
          version=__sbi_version__,
          scheduling_block=generate_sb(utc_now, project, programme_block),
          processing_blocks=pb_list
      )
      if register_workflows:
          add_workflow_definitions(sbi_config)
      return sbi_config
docs: Generate a SBI configuration dictionary.
  
      Args:
          num_pbs (int, optional): Number of Processing Blocks (default = 3)
          project (str, optional): Project to associate the SBI with.
          programme_block (str, optional): SBI programme block
          pb_config (dict, List[dict], optional): PB configuration
          workflow_config (dict, List[dict], optional): Workflow configuration
          register_workflows (bool, optional): If true also register workflows.
  
      Returns:
          dict, SBI configuration dictionary