YesWorkflow is a user-oriented, language-independent tool for recovering workflow information from scripts. The model is described in the following two publications; this repository contains the TypeScript implementation of the YesWorkflow extension for Visual Studio Code.
-
T. McPhillips, T. Song, T. Kolisnik, S. Aulenbach, K. Belhajjame, R.K. Bocinsky, Y. Cao, J. Cheney, F. Chirigati, S. Dey, J. Freire, C. Jones, J. Hanken, K.W. Kintigh, T.A. Kohler, D. Koop, J.A. Macklin, P. Missier, M. Schildhauer, C. Schwalm, Y. Wei, M. Bieda, B. Ludäscher (2015). YesWorkflow: A User-Oriented, Language-Independent Tool for Recovering Workflow Information from Scripts. International Journal of Digital Curation 10, 298-313. [PDF]
-
T. McPhillips, S. Bowers, K. Belhajjame, B. Ludäscher (2015). Retrospective Provenance Without a Runtime Provenance Recorder. 7th USENIX Workshop on the Theory and Practice of Provenance (TaPP'15). [PDF]
YesWorkflow aims to provide a number of the benefits of using a scientific workflow management system without having to rewrite scripts and other scientific software. Rather than reimplement code so that it can be executed and managed by a workflow engine, a YesWorkflow user simply adds special YesWorkflow (YW) comments to existing scripts. These comments declare how data is used and results produced, step by step, by the script. The YesWorkflow tools interpret the YW comments and produce graphical output that reveals the stages of computation and the flow of data in the script.
- Language support: Bash (.sh), C (.c, .h), C++ (.cpp), Java (.java), MATLAB (.m), Python (.py), R (.R), and SAS (.sas)
- Subworkflow support: Select and visualize nested workflows
- Interactive graph visualization: Display workflows as interactive graphs in a side-by-side webview panel
- Graph-to-code navigation: Click a graph node to highlight the corresponding lines in the script
- View controls: Toggle visibility of steps, data, parameters, ports, boxes, and titles
- Layout control: Switch graph layout direction between Down (top-to-bottom) and Across (left-to-right)
- Zoom controls: Zoom in, zoom out, and fit the graph to view
- Live reload: Automatically update the graph when the script is saved
- Multiple export formats: Export as HTML or SVG, or copy the DOT string (via right-click in the webview panel)
- Open a supported source file.
- Add YesWorkflow annotations in comments.
- Click the "YesWorkflow: Show Workflow Graph" button (workflow icon) in the editor title toolbar (top-right corner)
- The workflow graph appears in a webview panel beside your script.
- The graph automatically updates when you save changes.
# @begin EmphasizedHelloWorld @desc Display one or more greetings to the user.
# @in provided_greeting
# @in provided_emphasis
# @param emphasis_count
# @out displayed_greeting @desc Greeting displayed to user.
def greet_user(greeting, emphasis='!', count=1):
"""
# @begin emphasize_greeting @desc Add emphasis to the provided greeting
# @in greeting @as provided_greeting
# @in emphasis @as provided_emphasis @param count @as emphasis_count
# @out greeting @as emphasized_greeting
"""
if (count > 0):
for i in range(0, count):
greeting = greeting + emphasis
# @end emphasize_greeting
# @begin print_greeting @desc Greet the user with the emphasized message.
# @in greeting @as emphasized_greeting
# @out greeting @as displayed_greeting @file stream:stdout
print(greeting)
# @end print_greeting
# @end EmphasizedHelloWorld
if __name__ == '__main__':
first_greeting = 'Hello World'
greet_user(first_greeting)
second_greeting = 'Goodbye World'
greet_user(second_greeting, '?', 2)
third_emph_count = 3
greet_user("Back again", '?!', third_emph_count)npm installnpm run compilenpm testnpx vsce package
Initial release with interactive graph generation for script with YesWorkflow annotations.


