add pipeline mode implementation