Add WorkflowHub importer with per-tool workflow ID outputs#52
Add WorkflowHub importer with per-tool workflow ID outputs#52paulzierep wants to merge 7 commits into
Conversation
|
linter fails due to other scripts alread merged ! |
|
@rioualen @supernord just want to make sure you are aware of this, it would be great if you could consider reviewing |
|
Same as for tess: @mihai-sysbio imo this is ready for review, maybe @hmenager can check if the logic makes sense (ids in data folder, full metadata in dataset folder), or I can present in the next meeting, toimorrow :) @arash77 maybe you can check the code logic, worked for me locally - the question would be how to process it downstream for the atlas, so that we can see for each tool, which workflow is using it, the workflow should include at least the link, version and name I guess |
|
Thank you @mihai-sysbio for drawing my attention to this, I'll look into it! Talking about EDAM annotations and the Codex, it seems tools and workflows are annotated with EDAM labels rather than URIs, which is not ideal. I opened an issue to discuss this in the Codex repository. |
Checked the logic, works locally. On your question: link, version and name are all there. That's exactly the shape the Atlas frontend already expects for workflows, so Matches the repo conventions. CI is red from pre-existing lint/format issues on Minor: |
…WorkflowHub importer
|
@agnesbrnb can you check if there is some metadata missing that is created here https://github.com/research-software-ecosystem/micoreca/blob/main/bin/extract_workflowhub.py ? |
|
The extraction of the complete JSON file from workflowhub is what MiCoReCa needs for filtering. |
|
Thanks @paulzierep for this PR ! We have been working with FAIR-checker to extract JSON-LD semantic markup, following the Bioschemas Computational Workflow profile. I do not lanage to get references to EDAM terms, but I see that you manage to do it ? How do you proceed ? Would it be possible to document it for the workflowHub dev team so that they expose more complete Bioschemas markup on each web page ? |
Actually, the EDAM terms come directly form workflowHUB. The API response at /workflows/{id}.json includes them as topic_annotations and operation_annotations arrays with labels. |
|
@paulzierep For MiCoReCa (research-software-ecosystem/micoreca#49) I need the extraction of the workflow type (Galaxy, Nextflow, Snakemake..) under the attribute « type ». |
|
This PR looks good to me, maybe the final approval of @hmenager would be useful, provided he has some availability. As soon as it is merged, I'll work on a better RDF dump to incorporate into the SPARQL endpoint. |
Add WorkflowHub importer with per-tool workflow ID outputs
Creates a new
workflowhub-import/importer that fetches all workflows from the WorkflowHub API and produces per-tool workflow ID files for the RSEc content repo.What it does:
bio.toolsannotations and Galaxyinternals.stepsdescriptionsdata/{biotool_id}/directories usinggalaxy_codexSuite ID → bio.tool ID mapping, falling back to raw tool namedata/{biotool_id}/{biotool_id}.workflowhub.jsoncontaining only a list of workflow IDsimports/workflowhub/{id}.workflowhub.json--test [N]flag to limit workflows for testingUsage:
Format of per-tool files (e.g.
data/fastp/fastp.workflowhub.json):imports/workflowhub/1104.workflowhub.json(workflow entry withmapped_tools):{ "content_blobs": [], "create_time": "2026-07-08", "creators": [ "Amirhossein Naghsh Nilchi", "Pavankumar Videm", "Bj\u00f6rn Gr\u00fcning" ], "description": "A comprehensive Galaxy workflow for the end-to-end analysis of spatial data, featuring automated QC, clustering, spatial statistics, cell type annotation, and cell-cell communication.", "discussion_links": [], "doi": "10.48546/workflowhub.workflow.2174.5", "edam_operation": [ "Clustering", "Dimensionality reduction", "Expression correlation analysis" ], "edam_topic": [ "Single-cell sequencing" ], "id": "2174", "latest_version": "5", "license": "MIT", "link": "https://workflowhub.eu/workflows/2174?version=5", "mapped_tools": [ "anndata", "celltypist", "liana", "scanpy", "spatialdata", "squidpy" ], "name": "Galaxy EISTA spatialdata + updated squidpy", "number_of_steps": 80, "projects": [], "source": "WorkflowHub", "tags": [ "bioinformatics", "galaxy", "single cell clustering", "transcriptomics", "single-cell", "spatial transcriptomics" ], "tools": [ "scanpy_inspect", "param_value_from_file", "liana", "scanpy_filter", "addvalue", "add_a_column1", "liana+", "compose_text_param", "celltypist", "tp_replace_in_line", "spatialdata_operation", "pick_value", "collection_column_join", "anndata", "scanpy", "set the value to a text input\nparam_value_from_file", "split_file_to_collection", "select the resolution\ncut1", "tp_awk_tool", "tp_cut_tool", "anndata_inspect", "scanpy_cluster_reduce_dimension", "table_compute", "tp_sort_header_tool", "scanpy_remove_confounders", "scanpy_normalize", "tp_find_and_replace", "scanpy_plot", "datamash_transpose", "anndata_manipulate", "squidpy", "spatialdata", "squidpy_graph", "liana_methods", "map_param_value" ], "update_time": "2026-07-08", "versions": "5", "workflow_class": "Galaxy" }Unfortunatly most nextflow / snakemake workflows do not have tools available via workflowHUB api, I made some tests to get it via ro-crate or the associated github, but this is messy. I would opt to fix this rather on the workflow hub side.