I made an important addition to the MainBlock data structure today: a composition serial string variable. It's a very minor addition, but it will provide important functionality in the future. The serial string is really just a unique ID by which a composition can be identified. The string is alphanumeric, weighted in favor of characters so as to make the strings easier to type and remember. Currently, strings are 10 characters long. Here are some examples:


And now the question: so what? Well, here's the idea behind serial strings:

Many plugins make random decisions at runtime, such as weighting probability distributions. These decisions change between each composition, so the same plugin will act differently even if the configuration stays the same. In this way, each composition has a unique "personality." Using the serial string, plugins can create detailed databases that catalogue the settings that were used to generate a certain composition. It's easier to understand the practicality of this by example.

Let's say the user has a future version of mGen, which includes some kind of "wrapper" module that renders many compositions repeatedly and then, after accumulating about an hour of music, burns them to a disc, so that the user has a full CD of random music. Now, suppose the user is listening to the CD in his or her car and stumbles upon a really nice composition. Obviously, he or she will want to go back and figure out what was running through the program's "mind" when the composition was made. What generative modules were used and with what confgurations? More importantly, what unique decisions were made by each plugin at runtime that made the composition so great? By taking the serial string (which could be part of the composition's file name on the CD) and asking individual plugins or the general framework to pull up history files, the user could then see exactly how the composition was generated and, perhaps, discover the settings that produced such a piece.

User feedback-based evolutionary modules constitute an even more exciting application of serial strings. If the user likes a composition, he/she can simply enter the serial string into some kind of feedback system (which may be part of mGen as a whole or of individual plugins) to let the computer know that it did a good job with that composition. The computer can then try to figure out what settings result in good feedback, ideally creating an evolutionary system that gets better with time.

So many possibilities are centered around a single string! But the serial string is more than just an array of characters. It is the only precise key by which compositions can be remembered and identified - the only unique trait, other than sound waves, that separates a composition from thousands of others.