puppet function