Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 45 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@



APE is a command line tool and Java API for the automated exploration of possible computational pipelines (scientific workflows) from large collections of computational tools. Generated workflows can be exported in [CWL](https://www.commonwl.org/) format, as well as in graphical (PNG, SVG) formats.
APE is a command line tool and Java API for the automated exploration of possible computational pipelines (scientific workflows) from large collections of computational tools. Generated workflows can be exported in [CWL](https://www.commonwl.org/) or [Snakemake](https://snakemake.readthedocs.io/en/stable/) format, as well as in graphical (PNG, SVG) formats or plain shell scripts.

APE relies on a semantic domain model that includes tool and type taxonomies as controlled vocabularies for the description of computational tools, and functional tool annotations (inputs, outputs, operations performed) using terms from these taxonomies. Based on this domain model and a specification of the available workflow inputs, the intended workflow outputs and possibly additional constraints, APE then computes possible workflows.

Expand All @@ -28,9 +28,9 @@ For our paper at [ICCS 2020](https://www.iccs-meeting.org/iccs2020/) [[2]](#2) w

## Requirements

To [run](https://github.com/workflomics/ape#how-to-run-ape-from-the-command-line) APE locally you need to have [Java 1.8](https://www.oracle.com/java/technologies/javase/javase-jdk8-downloads.html) (or higher) installed on your system (use the command `$ java -version` to check your local version).
To [run](https://github.com/workflomics/ape#how-to-run-ape-from-the-command-line) APE locally you need to have [Java 17](https://www.oracle.com/java/technologies/downloads/#java17) (or higher) installed on your system (use the command `$ java -version` to check your local version).

To [build](https://github.com/workflomics/ape#build-ape-from-source-using-maven) APE from source, [Maven 3.3+](https://maven.apache.org/download.cgi) has to be installed as well (use the command `$ mvn -version` to check your local version).
To [build](https://github.com/workflomics/ape#build-ape-from-source-using-maven) APE from source, [Maven 3.8+](https://maven.apache.org/download.cgi) has to be installed as well (use the command `$ mvn -version` to check your local version).


> **_Note:_** Building APE from source is not required to run it, as the latest stable version is available at [maven repository](https://mvnrepository.com/artifact/org.workflomics/APE/latest).
Expand Down Expand Up @@ -73,6 +73,7 @@ For information regarding **Gradle**, **Ivy**, etc. we refer to the [APE mvn rep

| Date | Version | Download |
|------------|---------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| 10-02-2026 | 2.6.0 | [jar](https://repo1.maven.org/maven2/org/workflomics/APE/2.6.0/APE-2.6.0.jar), [executable](https://repo1.maven.org/maven2/org/workflomics/APE/2.6.0/APE-2.6.0-executable.jar), [javadoc](https://repo1.maven.org/maven2/org/workflomics/APE/2.6.0/APE-2.6.0-javadoc.jar), [sources](https://repo1.maven.org/maven2/org/workflomics/APE/2.6.0/APE-2.6.0-sources.jar) |
| 29-09-2025 | 2.5.3 | [jar](https://repo.maven.apache.org/maven2/io/github/sanctuuary/APE/2.5.3/APE-2.5.3.jar), [executable](https://repo.maven.apache.org/maven2/io/github/sanctuuary/APE/2.5.3/APE-2.5.3-executable.jar), [javadoc](https://repo.maven.apache.org/maven2/io/github/sanctuuary/APE/2.5.3/APE-2.5.3-javadoc.jar), [sources](https://repo.maven.apache.org/maven2/io/github/sanctuuary/APE/2.5.3/APE-2.5.3-sources.jar) |
| 10-06-2025 | 2.5.2 | [jar](https://repo.maven.apache.org/maven2/io/github/sanctuuary/APE/2.5.2/APE-2.5.2.jar), [executable](https://repo.maven.apache.org/maven2/io/github/sanctuuary/APE/2.5.2/APE-2.5.2-executable.jar), [javadoc](https://repo.maven.apache.org/maven2/io/github/sanctuuary/APE/2.5.2/APE-2.5.2-javadoc.jar), [sources](https://repo.maven.apache.org/maven2/io/github/sanctuuary/APE/2.5.2/APE-2.5.2-sources.jar) |
| 09-06-2025 | 2.5.0 | [jar](https://repo.maven.apache.org/maven2/io/github/sanctuuary/APE/2.5.0/APE-2.5.0.jar), [executable](https://repo.maven.apache.org/maven2/io/github/sanctuuary/APE/2.5.0/APE-2.5.0-executable.jar), [javadoc](https://repo.maven.apache.org/maven2/io/github/sanctuuary/APE/2.5.0/APE-2.5.0-javadoc.jar), [sources](https://repo.maven.apache.org/maven2/io/github/sanctuuary/APE/2.5.0/APE-2.5.0-sources.jar) |
Expand Down Expand Up @@ -110,10 +111,10 @@ When running APE-[latest]-executable.jar from the command line, it requires a JS
java -jar APE-[latest]-executable.jar [path-to-ape-configuration]
```

The configuration file (see [APE cofiguration example](https://github.com/sanctuuary/APE_UseCases/blob/master/ImageMagick/Example1/config.json) and [APE configuration documentation](https://github.com/sanctuuary/APE_UseCases#configuration-file)) provides references to all therefor required information:
The configuration file (see [APE cofiguration example](https://github.com/sanctuuary/APE_UseCases/blob/master/ImageMagick/Example1/config.json) and [APE configuration documentation](https://ape-framework.readthedocs.io/en/latest/docs/specifications/domain.html#configuration-file)) provides references to all therefor required information:
1. *Domain model* - classification of the types and operations in the domain in form of an **ontology** (see [ontology example](https://github.com/sanctuuary/APE_UseCases/blob/master/ImageMagick/imagemagick_taxonomy.owl) in OWL) and a **tool annotation file** (see [tool annotations example](https://github.com/sanctuuary/APE_UseCases/blob/master/ImageMagick/tool_annotations.json) in JSON).
2. *Workflow specification* - including a list of **workflow inputs/outputs** and template-based (see [constraint templates](https://github.com/sanctuuary/APE_UseCases/blob/master/ImageMagick/Example1/constraint_templates.json)) **workflow constraints** (see [workflow constraints example](https://github.com/sanctuuary/APE_UseCases/blob/master/ImageMagick/Example1/constraints.json))
3. *Parameters* for the synthesis execution, such as the number of desired solutions, output directory, system configurations, etc. (see [APE configuration documentation](https://github.com/sanctuuary/APE_UseCases#configuration-file)).
2. *Workflow specification* - including a list of **workflow inputs/outputs** and template-based (see [constraint templates](https://ape-framework.readthedocs.io/en/latest/docs/specifications/constraints.html#constraint-templates)) **workflow constraints** (see [workflow constraints example](https://github.com/sanctuuary/APE_UseCases/blob/master/ImageMagick/Example1/constraints.json))
3. *Parameters* for the synthesis execution, such as the number of desired solutions, output directory, system configurations, etc. (see [APE configuration documentation](https://ape-framework.readthedocs.io/en/latest/docs/specifications/domain.html#configuration-file)).

#### My first APE run

Expand Down Expand Up @@ -149,11 +150,16 @@ Like the CLI, the APE API relies on a configuration file that references the dom
APE ape = new APE("path/to/setup-configuration.json");

// run the synthesis
SATsolutionsList solutions = ape.runSynthesis("path/to/run-configuration.json");
SolutionsList solutions = ape.runSynthesis("path/to/run-configuration.json");
// Set that partial implementations shall be allowed (missing explicit CLI names of tools are then marked with placeholders).
bool createPartialImplementations = true;

// write the solutions for the file system
APE.writeSolutionToFile(solutions);
APE.writeDataFlowGraphs(solutions, RankDir.TOP_TO_BOTTOM);
APE.writeExecutableWorkflows(solutions);
APE.writeCWLWorkflows(solutions, createPartialImplementations);
APE.writeSnakemakeWorkflows(solutions, createPartialImplementations);
```

However, the API allows to generate and edit the configuration file programmatically:
Expand All @@ -167,11 +173,11 @@ APE ape = new APE(coreConfig);
APERunConfig runConfig = APERunConfig.builder().withSolutionMinLength(1).withSolutionMaxLength(10)
.withMaxNoSolutions(100).withApeDomainSetup(ape.getDomainSetup())
.build();
SATsolutionsList solutions1 = ape.runSynthesis(runConfig);
SolutionsList solutions1 = ape.runSynthesis(runConfig);

// run the synthesis again with altered parameters
runConfig.setUseWorkflowInput(ConfigEnum.ONE);
SATsolutionsList solutions2 = ape.runSynthesis(runConfig);
SolutionsList solutions2 = ape.runSynthesis(runConfig);
```

For more information see [APE javadoc.io](https://javadoc.io/doc/org.workflomics/APE/latest/nl/uu/cs/ape/sat/APE.html) or
Expand Down Expand Up @@ -216,11 +222,36 @@ APE is licensed under the [Apache 2.0](https://github.com/workflomics/ape/blob/m

### Maven dependencies

1. [**OWL API**](https://mvnrepository.com/artifact/net.sourceforge.owlapi/owlapi-distribution) - LGPL or Apache 2.0
2. [**SAT4J**](https://mvnrepository.com/artifact/org.apache.logging.log4j/log4j-core) - EPL or GNu LGPL
3. [**apache-common-lang**](https://mvnrepository.com/artifact/org.apache.commons/commons-lang3) - Apache 2.0
4. [**graphviz-java**](https://mvnrepository.com/artifact/guru.nidi/graphviz-java) - Apache 2.0
5. [**org.json**](https://mvnrepository.com/artifact/org.json/json) - [JSON license](https://www.json.org/license.html)

#### Apache dependencies

1. [**Commons Lang**](https://mvnrepository.com/artifact/org.apache.commons/commons-lang3) - Apache 2.0
2. [**Log4j Core**](https://mvnrepository.com/artifact/org.apache.logging.log4j/log4j-core) - Apache 2.0
3. [**Commons IO**](https://mvnrepository.com/artifact/commons-io/commons-io) - Apache 2.0

#### Logging dependencies

1. [**SLF4J API**](https://mvnrepository.com/artifact/org.slf4j/slf4j-api) - MIT
2. [**SLF4J Simple**](https://mvnrepository.com/artifact/org.slf4j/slf4j-simple) - MIT

#### Code Generation dependencies

1. [**Project Lombok**](https://mvnrepository.com/artifact/org.projectlombok/lombok) - MIT
2. [**ANTLR 4 Runtime**](https://mvnrepository.com/artifact/org.antlr/antlr4-runtime) - BSD 3-clause

#### Other dependencies

1. [**OkHttp**](https://mvnrepository.com/artifact/com.squareup.okhttp3/okhttp) - Apache 2.0
2. [**Graphviz Java**](https://mvnrepository.com/artifact/guru.nidi/graphviz-java) - Apache 2.0
3. [**OWL API**](https://mvnrepository.com/artifact/net.sourceforge.owlapi/owlapi-distribution) - LGPL 3.0 or Apache 2.0
4. [**CWL SDK**](https://mvnrepository.com/artifact/org.commonwl/cwlsdk) - Apache 2.0
5. [**JSON In Java**](https://mvnrepository.com/artifact/org.json/json) - Public Domain
6. [**SAT4J Core**](https://mvnrepository.com/artifact/org.sat4j/org.sat4j.core) - EPL 1.0 or LGPL 2.1

#### Test dependencies

1. [**JUnit Jupiter API**](https://mvnrepository.com/artifact/org.junit.jupiter/junit-jupiter-api) - EPL 2.0


## References
<a id="1">[1]</a>
Expand Down
156 changes: 87 additions & 69 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -158,86 +158,104 @@
</build>

<dependencies>
<!-- Apache packages -->
<!-- https://mvnrepository.com/artifact/org.apache.commons/commons-lang3 -->
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
<version>3.19.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.apache.logging.log4j/log4j-core -->
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
<version>2.25.3</version>
</dependency>
<!-- https://mvnrepository.com/artifact/commons-io/commons-io -->
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.15.1</version>
</dependency>

<!-- General Logging -->
<!-- https://mvnrepository.com/artifact/org.slf4j/slf4j-api -->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>2.0.12</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.slf4j/slf4j-simple -->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-simple</artifactId>
<version>2.0.12</version>
</dependency>

<!-- Code Generation -->
<!-- https://mvnrepository.com/artifact/org.projectlombok/lombok -->
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>1.18.30</version>
<scope>provided</scope>
</dependency>
<!-- https://mvnrepository.com/artifact/org.antlr/antlr4-runtime -->
<dependency>
<groupId>org.antlr</groupId>
<artifactId>antlr4-runtime</artifactId>
<version>4.13.1</version>
</dependency>

<!-- Other dependencies -->
<!-- https://mvnrepository.com/artifact/com.squareup.okhttp3/okhttp -->
<dependency>
<groupId>com.squareup.okhttp3</groupId>
<artifactId>okhttp</artifactId>
<version>5.0.0-alpha.11</version>
</dependency>
<!-- https://mvnrepository.com/artifact/guru.nidi/graphviz-java -->
<dependency>
<groupId>guru.nidi</groupId>
<artifactId>graphviz-java</artifactId>
<version>0.17.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/net.sourceforge.owlapi/owlapi-distribution -->
<dependency>
<groupId>net.sourceforge.owlapi</groupId>
<artifactId>owlapi-distribution</artifactId>
<version>5.5.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.commonwl/cwlsdk -->
<dependency>
<groupId>org.commonwl</groupId>
<artifactId>cwlsdk</artifactId>
<version>2.0.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.json/json -->
<dependency>
<groupId>org.json</groupId>
<artifactId>json</artifactId>
<version>20240205</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.sat4j/org.sat4j.core -->
<dependency>
<groupId>org.sat4j</groupId>
<artifactId>org.sat4j.core</artifactId>
<version>2.3.1</version>
</dependency>
<!-- <dependency> <groupId>org.logicng</groupId> <artifactId>logicng</artifactId>
<version>1.5.0</version> </dependency> <dependency> <groupId>com.opencsv</groupId>
<artifactId>opencsv</artifactId> <version>4.1</version> </dependency> -->
<dependency>
<groupId>net.sourceforge.owlapi</groupId>
<artifactId>owlapi-distribution</artifactId>
<version>5.5.0</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
<version>3.19.0</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
<version>2.25.3</version>
</dependency>
<dependency>
<groupId>guru.nidi</groupId>
<artifactId>graphviz-java</artifactId>
<version>0.17.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.json/json -->
<dependency>
<groupId>org.json</groupId>
<artifactId>json</artifactId>
<version>20240205</version>
</dependency>

<!-- Test dependencies -->
<!-- https://mvnrepository.com/artifact/org.junit.jupiter/junit-jupiter-api -->
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-api</artifactId>
<version>5.10.0</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>2.0.12</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-simple</artifactId>
<version>2.0.12</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.antlr/antlr4-runtime -->
<dependency>
<groupId>org.antlr</groupId>
<artifactId>antlr4-runtime</artifactId>
<version>4.13.1</version>
</dependency>
<!-- https://mvnrepository.com/artifact/commons-io/commons-io -->
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.15.1</version>
</dependency>
<!-- https://mvnrepository.com/artifact/com.squareup.okhttp3/okhttp -->
<dependency>
<groupId>com.squareup.okhttp3</groupId>
<artifactId>okhttp</artifactId>
<version>5.0.0-alpha.11</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.projectlombok/lombok -->
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>1.18.30</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.commonwl</groupId>
<artifactId>cwlsdk</artifactId>
<version>2.0.0</version>
</dependency>

<!-- <dependency> <groupId>org.logicng</groupId> <artifactId>logicng</artifactId>
<version>1.5.0</version> </dependency> <dependency> <groupId>com.opencsv</groupId>
<artifactId>opencsv</artifactId> <version>4.1</version> </dependency> -->
</dependencies>
</project>
Loading