Workflow Clinic
Workflow Clinic is a GSoC 2026 project focused on improving the portability, reproducibility, and cloud-readiness of scientific workflows.
The project aims to analyze workflow languages such as Nextflow and Snakemake, convert them into a common intermediate representation called WorkflowBundle, and identify workflow portability issues through automated validation and analysis.
By using a common workflow model inspired by the DAW (Data Analysis Workflow) metamodel, Workflow Clinic can reason about workflows independently of their original language and provide consistent diagnostics, recommendations, and future repair capabilities.
Why Workflow Clinic?
Scientific workflows are often tightly coupled to specific execution environments, storage systems, schedulers, or local infrastructure.
This can make workflows difficult to:
- Share
- Reproduce
- Port across platforms
- Execute in cloud environments
- Integrate with GA4GH-compliant services
Workflow Clinic aims to help workflow authors identify and resolve these issues before deployment.
Planned Features
Workflow Parsing
- Nextflow support
- Snakemake support
- Common WorkflowBundle representation
Workflow Analysis
- Portability diagnostics
- Storage validation
- Resource validation
- Metadata validation
- Workflow structure validation
AI-Assisted Review
- Rule-based workflow checks
- AI-assisted diagnostics
- Confidence-based recommendations
Workflow Repair
- Suggested fixes
- Automated transformations
- Validation of generated fixes
Installation
Clone the Repository
git clone https://github.com/revaarathore11/ga4gh_workflow_clinic_gsoc_2026-.git
cd ga4gh_workflow_clinic_gsoc_2026-
Create a Virtual Environment
python -m venv .venv
source .venv/bin/activate
Install Dependencies
pip install -e ".[dev]"
Development
Run Tests
pytest
Run Linting
ruff check .
Run Formatting
ruff format .
AI Critic & Remediation Guidance (AI-Assisted Review)
Workflow Clinic includes an AI Critic Agent to enrich diagnostic findings with AI-powered, cloud-readiness remediation advice.
Enabling the AI Critic
To enable the AI to perform a high-level review of your workflow (discovering complex logic bugs, implicit dependencies, or anti-patterns) AND generate detailed remediation advice for all findings, run the examine command with the --enhance (-e) flag:
workflow-clinic examine main.nf --enhance
Note: If no API key is provided, --enhance will fall back to using a local knowledge base for basic remediation and will skip the high-level audit discovery phase.
Deduplication & Anti-Hallucination
The AI Critic is engineered with strict system prompts that feed it all previously discovered static issues (e.g., W001, W002). This prevents the LLM from duplicating existing findings, forcing it to focus exclusively on discovering complex bugs, shell scripting anti-patterns, and implicit dependencies that static rules miss. It is also strictly instructed not to hallucinate issues just to fill quotas.
🔑 Bring Your Own Key & Model (BYOK & BYOM)
You can configure any supported LiteLLM model (e.g., OpenAI, Gemini, Anthropic, Groq, Mistral) by setting the respective environment variable.
Configuration via .env file (Recommended)
Create a .env file in your working directory to permanently save configuration details:
OPENAI_API_KEY="sk-proj-..."
# CLINIC_MODEL="gpt-4o" # Optional: Overrides the auto-detected default model
Model Auto-Detection: The AI Critic automatically resolves the appropriate default model based on which API key is present in your environment (e.g., OPENAI_API_KEY defaults to gpt-4o-mini).
To view all supported providers and their default models, run:
workflow-clinic list-models
CLI Options
You can temporarily override the default model directly on the command line:
workflow-clinic examine main.nf --enhance --model gpt-4o --api-key sk-proj-...
[!WARNING] Security Notice: Avoid passing explicit
--api-keyarguments in shared or public environments as they can leak into your shell history (history) or process listings (ps aux). Using environment variables or a.envfile is the highly recommended security practice.
Supported Workflow Languages
Current target languages:
- Nextflow
- Snakemake
Potential future support:
- CWL
- WDL
Architecture Overview
Workflow Files
↓
Parser
↓
WorkflowBundle
↓
Rule Engine
↓
AI Critic
↓
Doctor
Standards Alignment
Workflow Clinic is being designed with future compatibility in mind for:
- GA4GH TES
- GA4GH WES
- GA4GH TRS
- Workflow Run RO-Crate
License
This project is licensed under the Apache License 2.0.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file workflow_clinic-0.22.0.tar.gz.
File metadata
- Download URL: workflow_clinic-0.22.0.tar.gz
- Upload date:
- Size: 80.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
70def48f3d9bb963efd90d12f6dae20dd269da1b17341f7b09cc5aaadcbbe312
|
|
| MD5 |
835164f6f57a6fec2eafd28e1fc5a57e
|
|
| BLAKE2b-256 |
a213559cbeecf78e86ace729e283b27d0e5cb7277a2a209f62a93449fc26a05a
|
Provenance
The following attestation bundles were made for workflow_clinic-0.22.0.tar.gz:
Publisher:
release.yml on ga4gh/ga4gh_workflow_clinic_gsoc_2026
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
workflow_clinic-0.22.0.tar.gz -
Subject digest:
70def48f3d9bb963efd90d12f6dae20dd269da1b17341f7b09cc5aaadcbbe312 - Sigstore transparency entry: 2517113493
- Sigstore integration time:
-
Permalink:
ga4gh/ga4gh_workflow_clinic_gsoc_2026@ab7e07e8c9e29f6c458e6bc4a41c2e7ea29c0a87 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/ga4gh
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@ab7e07e8c9e29f6c458e6bc4a41c2e7ea29c0a87 -
Trigger Event:
push
-
Statement type:
File details
Details for the file workflow_clinic-0.22.0-py3-none-any.whl.
File metadata
- Download URL: workflow_clinic-0.22.0-py3-none-any.whl
- Upload date:
- Size: 62.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a926ff45ece1232a09c3b50356bb987411196ee107a2ab19e0198a7f32fb9d4a
|
|
| MD5 |
7605e31368c18d0b5b74bdd5da8d9776
|
|
| BLAKE2b-256 |
f3fe6018dbc9c539e0ba4981c185b99ee2fb70afd0ffb1360b5bf55083a5b1cb
|
Provenance
The following attestation bundles were made for workflow_clinic-0.22.0-py3-none-any.whl:
Publisher:
release.yml on ga4gh/ga4gh_workflow_clinic_gsoc_2026
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
workflow_clinic-0.22.0-py3-none-any.whl -
Subject digest:
a926ff45ece1232a09c3b50356bb987411196ee107a2ab19e0198a7f32fb9d4a - Sigstore transparency entry: 2517113800
- Sigstore integration time:
-
Permalink:
ga4gh/ga4gh_workflow_clinic_gsoc_2026@ab7e07e8c9e29f6c458e6bc4a41c2e7ea29c0a87 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/ga4gh
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@ab7e07e8c9e29f6c458e6bc4a41c2e7ea29c0a87 -
Trigger Event:
push
-
Statement type: