(NB: this is off-topic for postfix-users; I've added procmail to the Cc list,
if anyone follows up this msg please drop postfix-users off).
Sieve doesn't have a way to invoke pipes. This is by design. See
<URL:http://www.ietf.org/rfc/rfc3028.txt>, where it says:
It is suitable for running on a mail server where users may
not be allowed to execute arbitrary programs, such as on black box
Internet Message Access Protocol (IMAP) servers, as it has no
variables, loops, or ability to shell out to external programs.
procmail mailing list