https://github.com/suecharo/agodashi
An API server for parsing workflows written in workflow languages.
https://github.com/suecharo/agodashi
common-workflow-language workflow
Last synced: 9 days ago
JSON representation
An API server for parsing workflows written in workflow languages.
- Host: GitHub
- URL: https://github.com/suecharo/agodashi
- Owner: suecharo
- License: apache-2.0
- Created: 2020-06-29T03:38:40.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2020-07-05T09:32:55.000Z (almost 6 years ago)
- Last Synced: 2025-12-25T21:44:32.028Z (5 months ago)
- Topics: common-workflow-language, workflow
- Language: Python
- Homepage:
- Size: 63.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Agodashi
[](https://github.com/suecharo/agodashi/actions?query=workflow%3Apytest)
[](https://github.com/suecharo/agodashi/actions?query=workflow%3Aflake8)
[](https://github.com/suecharo/agodashi/actions?query=workflow%3Aisort)
[](https://github.com/suecharo/agodashi/actions?query=workflow%3Amypy)
[](http://www.apache.org/licenses/LICENSE-2.0)
Agodashi is a simple REST API server.
It takes a workflow file written in workflow language as input and returns workflow type, workflow version and workflow parameters template.
Currently, supported workflow languages are as follows:
- [Common Workflow Language (CWL)](https://www.commonwl.org)
In the future, we plan to support the following languages.
- [Nextflow](https://www.nextflow.io)
- [Snakemake](https://snakemake.readthedocs.io/en/stable/)
- [Workflow Description Language (WDL)](https://openwdl.org)
## Install and Run
Agodashi supports Python 3.6 or newer.
```bash
$ pip3 install agodashi
$ agodashi
```
### Docker
We also expect to launch using Docker.
```bash
# Launch
$ docker-compose up -d
# Launch confirmation
$ docker-compose logs
```
## Usage
As API specifications, please check [SwaggerUI - Agodashi API Spec](https://suecharo.github.io/agodashi-swagger-ui/)
The help for the Agodashi startup command is as follows.
```bash
$ agodashi --help
usage: agodashi [-h] [--host] [-p] [--debug]
An API server for parsing workflows written in workflow languages
optional arguments:
-h, --help show this help message and exit
--host Host address of Flask. (default: 127.0.0.1)
-p , --port Port of Flask. (default: 8080)
--debug Enable debug mode of Flask.
```
As the simplest example of a REST API Request, here is the result of a `POST /inspect-workflow`.
```json
POST /inspect-workflow -F 'wf_url=https://raw.githubusercontent.com/suecharo/agodashi/master/tests/resources/cwl/trimming_and_qc_packed.cwl'
{
"wf_params": "nthreads: 2 # default value of type \"int\". (optional)\nfastq_2: # type \"File\"\n class: File\n path: a/file/path\nfastq_1: # type \"File\"\n class: File\n path: a/file/path\n",
"wf_type": "CWL",
"wf_version": "v1.0"
}
```
## Development
You can start the development environment as follows.
```bash
$ docker-compose -f docker-compose.dev.yml up -d --build
$ docker-compose -f docker-compose.dev.yml exec app bash
```
We use [flake8](https://pypi.org/project/flake8/), [isort](https://github.com/timothycrosley/isort), and [mypy](http://mypy-lang.org) as the Linter.
```bash
$ bash ./tests/lint_and_style_check/flake8.sh
$ bash ./tests/lint_and_style_check/isort.sh
$ bash ./tests/lint_and_style_check/mypy.sh
```
We use [pytest](https://docs.pytest.org/en/latest/) as a Test Tool.
```bash
$ pytest .
```
## License
[Apache-2.0](https://www.apache.org/licenses/LICENSE-2.0). See the [LICENSE](https://github.com/suecharo/agodashi/blob/master/LICENSE).