template.rb: pipe -> chain