You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
When working with large Snakemake workflows (100+ rules), it becomes challenging
to manage and understand the relationships between rules. Currently, we use rules.foo.input and rules.foo.output to reference file dependencies, but
this approach focuses on individual rules rather than logical groupings of
related steps. For example, using groups.database_annotation.output would be
more semantically meaningful than rules.step3_postprocess.output when
referring to the final output of a database annotation process.
Describe the solution you'd like
I propose introducing a group keyword(or similar) to define logical groups of
related rules. This grouping would be purely organizational and wouldn't affect
workflow execution. Example:
rulestep1_preprocess:
"""Preprocess input data"""input: "a.txt"output: "b.txt"shell: "echo {input} > {output}"rulestep2_database_annotation:
"""Perform database annotation"""input: "b.txt"output: "c.txt"shell: "echo {input} > {output}"rulestep3_postprocess:
"""Post-process annotation results"""input: "c.txt"output: "d.txt"shell: "echo {input} > {output}"# Define a logical group of related rulesgroupdatabase_annotation:
input: rules.step1_preprocess.inputoutput: rules.step3_postprocess.output# Reference the group instead of individual rulesrulestep4:
input: groups.database_annotation.outputoutput: "e.txt"shell: "echo {input} > {output}"
Some potential benefits of this feature:
Simplified DAG Visualization: Groups can collapse related rules in the
DAG visualization, making it easier to understand the high-level workflow
structure.
Improved Readability: Groups provide semantic meaning to collections of
rules, making the workflow more self-documenting.
Alternative Modularization: Complements the existing include keyword by
providing another way to organize workflow components.
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
When working with large Snakemake workflows (100+ rules), it becomes challenging
to manage and understand the relationships between rules. Currently, we use
rules.foo.input
andrules.foo.output
to reference file dependencies, butthis approach focuses on individual rules rather than logical groupings of
related steps. For example, using
groups.database_annotation.output
would bemore semantically meaningful than
rules.step3_postprocess.output
whenreferring to the final output of a database annotation process.
Describe the solution you'd like
I propose introducing a
group
keyword(or similar) to define logical groups ofrelated rules. This grouping would be purely organizational and wouldn't affect
workflow execution. Example:
Some potential benefits of this feature:
DAG visualization, making it easier to understand the high-level workflow
structure.
rules, making the workflow more self-documenting.
include
keyword byproviding another way to organize workflow components.
The text was updated successfully, but these errors were encountered: