We present an application of reduction and higher-order functions in a recent computer-aided composition project. Our objective is the generation of control data for the Chant sound synthesizer using OpenMusic (OM), a domain-specific visual programming environment based on Common Lisp. The system we present allows to compose sounds by combining synthesis events in sequences. After the definition of the compositional primitives determining these events, we handle their sequencing, transitions and possible overlapping/fusion using a special fold operator. The artistic context of this project is the production of the opera Re Orso, premiered in 2012 at the Opera Comique, Paris.