Update kfilter to return output in struct