Can a Python program parse a .knwf file?

Hi everyone,

I have a question. I want to analyze many workflows. I need a program to automatically read/parse workflows. Can a python program read .knwf files? Is there any programing language that can do this?


@shuow16 welcome to the KNIME forum.

Question is what do you mean by analysing. Knwf files are ZIP files. So you could extract them with an external program.

I have set up an example how to inspect KNME’s underlying xml files for content. Maybe you can adapt that.

And recently there is this approach to analyze workflows. Maybe this also could help.

1 Like

Thank you a lot. The workflow about extracting content is very cool! If I want to inspect every node in a workflow to identify data dependency, is there any workflow or other methods to do it automatically? Because there are many workflows.

Not sure what you mean by data dependency. You could extract all your knwf files into a folder *1) (as subfolders) and then use the meta-search in xml files to search for certain terms within the folders. If you store the information about file and node where you found your term you would have an idea.

As an inspiration for copying and file handling there is an example workflow for that as well *2)

*1) ZIP and UNZIP with KNIME (you might have to rename your files first)

*2) copying and renaming