- In a workflow, an MGM that uses SFs needs to have one SMGM outputting to each of its SF input, the input data type is specific to the MGM.
- The SMGM (with tool_id supplement) has 4 input parameters and 1 output file:
- param supplement_name: must be predefined (text) as default in workflow or dynamically supplied upon submission
- param supplement_type: must be predefined (select from dropdown list of Collection, Item, Primaryfile) as default in workflow or dynamically supplied upon submission
- param supplement_format: must be predefined (select from dropdown list of txt, csv, pdf, zip) as default in workflow, and the value must match the input supplement file type in the depending MGM. For ex, if this SMGM outputs to FR training photo, then the format should be zip.
- param supplement_path: inferred and populated by AMP upon submission, based on supplement_name, supplement_type and the associated primaryfile; any value provided by user will be ignored and overwritten.
- output supplement_file: a soft link generated by SMGM based on supplement_path populated by AMP. The format (data type) of this output is decided by the supplement_format defined above, and is updated when Galaxy job runner generates the output.
- SMGM parameter values can be populated as below:
- At this point, a workflow with SMGMs needs to have predefined default values as specified in 2.1/2.2
- Once we have UI to allow users to provide parameters upon submission, the values can be obtained by user searching/selecting SFs by type/name, and AMP obtaining their filepaths and populating the supplement_path (replacing step 4 below).
- When a user submits multiple primaryfiles (PF) to a workflow with SFs, each SF need to bare the same name/type. For ex,
- For FR workflow using WellsPhotos as collection SF, the PFs may come from different collections, as long as all these collections have a SF named WellsPhotos.
- For Word Tagging workflow using SampleWords, the PFs may come from different items, as long as all these items have a SF named SampleWords.
- AMP's backend workflow submission will handle workflows that use SMGMs:
- scan the whole workflow for steps matching SMGM tool ID
- For each such step found, AMP obtains the supplement type and name parameters (first, the dynamic ones, if not found, go to the workflow default), then retrieves the SF entity based on its type, name, and the associated parent of the PF (primaryfile), then overwrites the supplement path with SF filepath.
- The SMGM in Galaxy will use the updated supplement_path parameter to create the soft link as the output, which can be used as a regular input file by the depending MGM.
Tool configuration: galaxy/tool/amp_file/supplement.xml