add function flowpath