Changed pipeline handling to fix #4.
Updated README to match the changed API.