code: def _cwl_workflow_template(inputs, top_level=False):
      
      ready_inputs = []
      for inp in inputs:
          cur_inp = copy.deepcopy(inp)
          for attr in ["source", "valueFrom", "wf_duplicate"]:
              cur_inp.pop(attr, None)
          if top_level:
              cur_inp = workflow._flatten_nested_input(cur_inp)
          cur_inp = _clean_record(cur_inp)
          ready_inputs.append(cur_inp)
      return {"class": "Workflow",
              "cwlVersion": "v1.0",
              "hints": [],
              "requirements": [{"class": "EnvVarRequirement",
                                "envDef": [{"envName": "MPLCONFIGDIR", "envValue": "."}]},
                               {"class": "ScatterFeatureRequirement"},
                               {"class": "SubworkflowFeatureRequirement"}],
              "inputs": ready_inputs,
              "outputs": [],
              "steps": []}
docs: Retrieve CWL inputs shared amongst different workflows.