## 2 Conceptual Framework
### Definitions and Analogies  
Although its target is not only genetic algorithms but a variety of machine learning techniques, our framework uses the evolutionary analogy, similarly to many other automatic composition systems [22; 23]. The Darwinian metaphor can be confusing, since each system has its particular application of the same terms, sometimes denoting even opposite concepts. In our functional approach, the key idea is considering any piece of music as the product of a program that encloses compositional procedures. Thereupon, the bioinspired terms in the context of the GenoMus framework are defined in the following glossary:  
**Genotype function:**: Minimal computable unit representing a musical procedure, designed in a modular way to enable taking other genotype functions as arguments. **Genotype:**: Computable tree of genotype functions. **Encoded genotype:**: Genotype coded as an array of floats \(\in[0,1]\). **Decoded genotype:**: Genotype coded as a human-readable evaluable string. **Leaf:**: Single numeric value or list of values at the end of a genotype branch. **Phenotype:**: Music generated by a genotype. **Encoded phenotype:**: Phenotype coded as an array of floats \(\in[0,1]\). **Decoded phenotype:**: Phenotype converted to a format suitable for third-party music software. The genotype, in its decoded format, is a computable expression. Consequently, the automatic writing and manipulation of genotypes can be seen as a metaprogramming process. This central idea of parsing languages (including musical language) to extract an essential abstract functional tree has been suggested by [PERSON] [24]. Additionally, the construction of genotypes requires two previous elements:  
**Germinal vector:**: An array of floats \(\in[0,1]\) used as an initial decision tree to build a genotype. **Germinal conditions:**: Minimal data required to deterministically construct a genotype, consisting of a germinal vector and several constraints to handle the generative process. The phenotype, as the product of the evaluation of the functional expression content in a genotype, is a sequence of music events declared in a format designed to encode music according to a hierarchical structure, made by combining three formal categories:  
**Event:**: Simplest musical element. An event is a wrapper for the parameters (leaves) that characterize it. **Voice:**: Line (or layer) of music. A voice is a wrapper for a sequence of one or more events, or a wrapper for one or more voices sequentially concatenated, without overlapping. **Score:**: Piece (or excerpt) of music. A score can be a wrapper for one or more voices, or a wrapper for one or more scores together. Scores can be concatenated sequentially (one after another) or simultaneously (sounding together). Depending on the final desired output of the generative process, different parametric structures will be expected for each event. Hence, to allow diverse formats for decoded phenotypes, two more concepts arise:  
**Species:**: A specific configuration of the internal parametric structure that constitutes an event. **Specimen:**: A genotype/phenotype pair belonging to a species, that produces a piece of music. Data characterizing a specimen are stored in a dictionary containing the germinal conditions, along with metadata and additional analytical information. Extending our biological analogy, a species can be alternatively defined as the group of specimens that share the same parameter structure of their musical events. The _piano_ species used in the examples requires four attributes for each event: duration, pitch, articulation, and intensity. A parameter required by an event can be a single value or an array of values (a multiparameter). For instance, in the piano species, an event can contain more than one pitch, to work with chords. Events built with many parameters can be set. For instance, a species for a very specific electroacoustic setup could need events defined by dozens of features.