Any interest in a music project?

Place to post guides, observations, things related to modding that are not mods themselves.
Eketek
Long Handed Inserter
Long Handed Inserter
Posts: 68
Joined: Mon Oct 19, 2015 9:04 pm
Contact:

Any interest in a music project?

Post by Eketek »

I have a music project in a relatively complete state of development: A scriptable text-based music production system with a tight synthesizer integration. Informally, it's a programmer art setup for music.

It allows music to be composed with simple text-based notations (like ABC notation or various oldschool computer music schemes). Instead of it being an abstract representation of music, it has a strong synthesizer integration, allows synth instruments to be fully defined (an interface-like specification covering all parameters defined for a synth program), allows arbitrary synth parameters to be bound to arbitrary text symbols and applied on a per-note basis (custom articulations), as well as arbitrary scripted code to be run as a composition is evaluated (procedural articulations, dynamic configuration changes).

The current implementation is written in LUA, scriptable in LUA, and uses csound as the synthesizer.

The project has thus far been a success - Without any significant experience either with direct music composition or with performance (only study of various aspects of music theory), I am able to get interesting results out of it.

I am not sure what to do with it, but there does appear to be two directions I could take the project: I could keep it as a private project, focus solely on composition (and perhaps produce a soundtrack for someone's planet or overhaul mod), or do an open-source release and focus on collaboration.

EDIT: Example outputs:
ekmusic_examples.zip
(2.68 MiB) Downloaded 17 times
The example data is the basic tutorials, as well as the main theme for an unnamed composition. The basic tutorials cover what is intended as the builtin or baseline configuration (should give a decent sense of what my project is, but does not get into the custom/procedural articulations) It is all rendered with randomly parameterized instruments.
Last edited by Eketek on Tue Oct 21, 2025 4:23 pm, edited 1 time in total.
mmmPI
Smart Inserter
Smart Inserter
Posts: 4797
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Any interest in a music project?

Post by mmmPI »

Eketek wrote: Tue Oct 21, 2025 2:55 pm P.S. I'd like to post a few short examples, but the forum doesn't appear to permit audio uploads, and I have an allergy to "free" online services which demand rights to feed data to LLMs.
you can post the audio in a .zip on the forum if it's not too big like 30 MB or you can post a mp4 if you want it displayed on the forum but in both case if it's public there will be a LLM that crawl thru it and feed from it without even asking for any kind of rights

project sound interesting :) but it's hard to see without hearing :P
Check out my latest mod ! It's noisy !
Eketek
Long Handed Inserter
Long Handed Inserter
Posts: 68
Joined: Mon Oct 19, 2015 9:04 pm
Contact:

Re: Any interest in a music project?

Post by Eketek »

mmmPI wrote: Tue Oct 21, 2025 3:31 pm
Eketek wrote: Tue Oct 21, 2025 2:55 pm P.S. I'd like to post a few short examples, but the forum doesn't appear to permit audio uploads, and I have an allergy to "free" online services which demand rights to feed data to LLMs.
you can post the audio in a .zip on the forum if it's not too big like 30 MB or you can post a mp4 if you want it displayed on the forum but in both case if it's public there will be a LLM that crawl thru it and feed from it without even asking for any kind of rights

project sound interesting :) but it's hard to see without hearing :P
Thanks! Examples are posted through a post edit.

(As far as opposition to LLMs, I am quite aware that they'll grab the data anyway. I'd prefer to keep it at least expressly prohibited.)
mmmPI
Smart Inserter
Smart Inserter
Posts: 4797
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Any interest in a music project?

Post by mmmPI »

Eketek wrote: Tue Oct 21, 2025 4:26 pm Thanks! Examples are posted through a post edit.
Got it !

Made me curious about what are in those files : "ekm_basic_notation.ekm3" , "ekm_instruments.ekm3" , i'm imagining code to simulate the oscillators ? or is this handled by csound ? i don't know much in these field, i like toying around for fun, i've seen a theremin coded in javascript i was expecting to see something that had similarities, (if i could understand anything ) , but it appears to me now that you dealt with the notation for melody, it's like a MIDI system ? or a MIDI system AND a player for it ?

There isn't enough in the .zip to try and make any noise myself right ? It's demo of how it sound when you did what is described in each file, which contain both the code and a little example to hear it from i understood.

When hearing i thought you'll need more than 1 instrument to try and make a full song :) or an integration maybe with like a drum machine , which could be used not for "notes" ABCD... but rather "sound effect" like 'kick', "snare" , hi hat , that don't necessarily have a pitch but could use a symbol or notation to be played alongside the synth.

Also when talking about notes, i'm only self-taught from like a couple year , which could explain my confusion, when i'm not seeing the # notes like F# or G#, that would be all the black keys on a keyboard , is it where one is supposed to use lower case ?
Eketek wrote: Tue Oct 21, 2025 4:26 pm (As far as opposition to LLMs, I am quite aware that they'll grab the data anyway. I'd prefer to keep it at least expressly prohibited.)
you do well to mention it :) the text-based nature of the input makes it very tempting to use LLMs for the purpose of generating melodies.

Sounds interesting as a project, but the result are too raw in this stage i believe to try and make a full song, but as an instrument, it could be used to make loops for an AI to make continuation ( sorry), or to export just a sample to enhance some part of another song in the making :)

Music on overhaul mods are from what i've seen commonly credited out of website with many songs,( sometimes attempting to avoid AI music); they can have quite a lot of traffic so songs amongst the "favourite" are sort of a "safe bet", it can be a discouraging process to try and make a song for an overhaul mod because some authors won't answer at all, some not positively, and even if you find a nice person that wants to hear the song before saying "no", they can still say "sorry i'd prefered something more like this" so you'd try to make another song, maybe couple times, and well , it can be a discouraging process, so you can think of a plan B, a place where you'd put those songs if you like them like your own mod , or something else maybe you have a better idea than me there :lol:
Check out my latest mod ! It's noisy !
Eketek
Long Handed Inserter
Long Handed Inserter
Posts: 68
Joined: Mon Oct 19, 2015 9:04 pm
Contact:

Re: Any interest in a music project?

Post by Eketek »

mmmPI wrote: Wed Oct 22, 2025 6:27 am
Got it !

Made me curious about what are in those files : "ekm_basic_notation.ekm3" , "ekm_instruments.ekm3" , i'm imagining code to simulate the oscillators ? or is this handled by csound ? i don't know much in these field, i like toying around for fun, i've seen a theremin coded in javascript i was expecting to see something that had similarities, (if i could understand anything ) , but it appears to me now that you dealt with the notation for melody, it's like a MIDI system ? or a MIDI system AND a player for it ?

There isn't enough in the .zip to try and make any noise myself right ? It's demo of how it sound when you did what is described in each file, which contain both the code and a little example to hear it from i understood.

When hearing i thought you'll need more than 1 instrument to try and make a full song :) or an integration maybe with like a drum machine , which could be used not for "notes" ABCD... but rather "sound effect" like 'kick', "snare" , hi hat , that don't necessarily have a pitch but could use a symbol or notation to be played alongside the synth.

Also when talking about notes, i'm only self-taught from like a couple year , which could explain my confusion, when i'm not seeing the # notes like F# or G#, that would be all the black keys on a keyboard , is it where one is supposed to use lower case ?

you do well to mention it :) the text-based nature of the input makes it very tempting to use LLMs for the purpose of generating melodies.

Sounds interesting as a project, but the result are too raw in this stage i believe to try and make a full song, but as an instrument, it could be used to make loops for an AI to make continuation ( sorry), or to export just a sample to enhance some part of another song in the making :)
but two of the issues you questioned me on do kind of .
Music on overhaul mods are from what i've seen commonly credited out of website with many songs,( sometimes attempting to avoid AI music); they can have quite a lot of traffic so songs amongst the "favourite" are sort of a "safe bet", it can be a discouraging process to try and make a song for an overhaul mod because some authors won't answer at all, some not positively, and even if you find a nice person that wants to hear the song before saying "no", they can still say "sorry i'd prefered something more like this" so you'd try to make another song, maybe couple times, and well , it can be a discouraging process, so you can think of a plan B, a place where you'd put those songs if you like them like your own mod , or something else maybe you have a better idea than me there :lol:
ekm_instruments.ekm3 imports the csound code which I used to implement the instrument used for the demos and provides a specification (to "ekmusic") for it. The specification defines all the parameters to pass to csound (LUA variable names, default values, optional getters, and optional randomization specifications). Additionally, the instrument specification includes a set of LUA functions to help set up and control/adjust the notation system while the instrument is active. I mostly ignored csound's high-level generators and coded my stuff directly (I do not personally need csound, but I wanted it for interoperability).

ekm_basic_notation.ekm3 defines the all the symbols used in the demo compositions. Operation specification is a symbol (string literal to use directly in compositions), a validity check, a priority value, and LUA code which applies the operation.

As far as actually divulging the contents of those files, that would basically require a decision to actually publish the project. That decision has not been made.

There's nothing wrong with music which avoids percussion and is composed solely for tonal instruments. The examples are meant to be simple and simply don't cover articulation or percussion due to that requiring more advanced usage (and I haven't written the tutorials for that yet). The general approach: Csound is quite capable of doing percussion (and even sample-based playback), so that would only be a matter of importing the right instrument (and adding a percussion handling to "basic notation"). The more particular approach: My synth code is quite capable of doing tonal percussion (listen carefully, as some of the randomly generated instruments do make it evident) - all that's needed is a strong attack magnitude and a weak sustain magnitude and/or a duration reduction parameter (It uses a very computationally expensive operation to allow more extreme magnitude/volume envelopes than the conventional approach generally permits).

Lack of sharps is basically a side-effect of the dynamic tuning system - they aren't needed (and would tend to be a serious constraint and/or nuisance if implemented)... It doesn't use absolute pitch, so there is no notion of having musical keys based on particular notes. Instead, it defines only semi-abstract "major" and "minor" scales (major scale is "ABCDEFG", minor scale is "abcdefg"), and has a set of operators which can dynamically raise or lower the pitch either of the entire orchestra or of individual instruments (see "09-dynamic-tuning"). For compositional purposes, these pitch shift operators are very similar to key changes. (Also, it can function as a more traditional western system by defining a 12-tone scale using any symbols and values you like and ignoring the pitch shift operators [or using them solely for octaves])

----

Using LLMs for composition is, in my estimation, a very wasteful approach: A few simple pitch patterns (either randomly selected from a pentatonic scale, or rule-based random selection from a more complex scale), repeated [with variations] using multiple voices with independent [but coordinated] beat patterns can get you some rather striking results (especially if you just want the ambience and don't need it to ever reach a conclusion).

As far as willingness of mod authors to accept music, that's entirely up to them. When I was considering the possibility of doing music for an overhaul mod, I kind of assumed that I'd need to successfully get beyond theory first, then somehow noticed doing it, and end up getting asked by the mod author for it (not the other way around).
mmmPI
Smart Inserter
Smart Inserter
Posts: 4797
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Any interest in a music project?

Post by mmmPI »

Eketek wrote: Wed Oct 22, 2025 10:10 am ekm_instruments.ekm3 imports the csound code which I used to implement the instrument used for the demos and provides a specification (to "ekmusic") for it. The specification defines all the parameters to pass to csound (LUA variable names, default values, optional getters, and optional randomization specifications). Additionally, the instrument specification includes a set of LUA functions to help set up and control/adjust the notation system while the instrument is active. I mostly ignored csound's high-level generators and coded my stuff directly (I do not personally need csound, but I wanted it for interoperability).

ekm_basic_notation.ekm3 defines the all the symbols used in the demo compositions. Operation specification is a symbol (string literal to use directly in compositions), a validity check, a priority value, and LUA code which applies the operation.

As far as actually divulging the contents of those files, that would basically require a decision to actually publish the project. That decision has not been made.
Ok so it's not just not me who didn't understand what to do with the pieces, the core isn't published yet, it was mainly for audio i'm thinking now :) all good !
Eketek wrote: Wed Oct 22, 2025 10:10 am There's nothing wrong with music which avoids percussion and is composed solely for tonal instruments. The examples are meant to be simple and simply don't cover articulation or percussion due to that requiring more advanced usage (and I haven't written the tutorials for that yet). The general approach: Csound is quite capable of doing percussion (and even sample-based playback), so that would only be a matter of importing the right instrument (and adding a percussion handling to "basic notation"). The more particular approach: My synth code is quite capable of doing tonal percussion (listen carefully, as some of the randomly generated instruments do make it evident) - all that's needed is a strong attack magnitude and a weak sustain magnitude and/or a duration reduction parameter (It uses a very computationally expensive operation to allow more extreme magnitude/volume envelopes than the conventional approach generally permits).
Sorry i forgot for a moment that music isn't only the kind i'm listening to x) I remember now, i heard church music and it was only an organ and voices, no percussion, but that's probably not what you had in mind, it sounded pretty electronic to me :)
I understand what you mean i think on tonal percussion, i followed tutorial on how to make kicks in synth like serum, with the attack and sustain you can draw as a curve for oscillators, that's what i start with when i try to make music, and when it's tonal, it's often a F# or G# that i go for, or a E, depending on what is available in the scale of note that i choose before, for a song. I have to render some audio as .wav sometimes, because my computer can't render all instrument in real time when they use computationnally expensive effect, i have learned a little to avoid the worst offenders by now :) So i think this part i understand, unlike the following :
Eketek wrote: Wed Oct 22, 2025 10:10 am Lack of sharps is basically a side-effect of the dynamic tuning system - they aren't needed (and would tend to be a serious constraint and/or nuisance if implemented)... It doesn't use absolute pitch, so there is no notion of having musical keys based on particular notes. Instead, it defines only semi-abstract "major" and "minor" scales (major scale is "ABCDEFG", minor scale is "abcdefg"), and has a set of operators which can dynamically raise or lower the pitch either of the entire orchestra or of individual instruments (see "09-dynamic-tuning"). For compositional purposes, these pitch shift operators are very similar to key changes. (Also, it can function as a more traditional western system by defining a 12-tone scale using any symbols and values you like and ignoring the pitch shift operators [or using them solely for octaves])
This i never heard of, i heard of micro tonal music or how in India it can differ from western music in the number of notes 20 vs 12 and how some frequencies thus differ, but that's about it x) Do you have anywhere recommended for me to document ?

Eketek wrote: Wed Oct 22, 2025 10:10 am Using LLMs for composition is, in my estimation, a very wasteful approach: A few simple pitch patterns (either randomly selected from a pentatonic scale, or rule-based random selection from a more complex scale), repeated [with variations] using multiple voices with independent [but coordinated] beat patterns can get you some rather striking results (especially if you just want the ambience and don't need it to ever reach a conclusion).
Yeah this isn't much "work" for a human to do, but that's also the kind of 'simple' arrangement that LLMs are doing i noticed x) when talking about AI that generate "music", for audio continuation. I understand the general dislike for AIs, but i can also just ask chatgpt for reference or indication, i have very limited knowledge on music theory, so i ask what are the scale of note used in this song or that one, or which ones are more commonly used in this genre, and for which emotion. It's somewhat using LLMs for composition, but there's different degree of lazyness i believe x).
Eketek wrote: Wed Oct 22, 2025 10:10 am As far as willingness of mod authors to accept music, that's entirely up to them. When I was considering the possibility of doing music for an overhaul mod, I kind of assumed that I'd need to successfully get beyond theory first, then somehow noticed doing it, and end up getting asked by the mod author for it (not the other way around).
It's good you make it know i believe for the noticing part, and i wish you the best of luck :) and you can also make your own mod with the music :lol:
Check out my latest mod ! It's noisy !
Eketek
Long Handed Inserter
Long Handed Inserter
Posts: 68
Joined: Mon Oct 19, 2015 9:04 pm
Contact:

Re: Any interest in a music project?

Post by Eketek »

mmmPI wrote: Wed Oct 22, 2025 2:35 pm
This i never heard of, i heard of micro tonal music or how in India it can differ from western music in the number of notes 20 vs 12 and how some frequencies thus differ, but that's about it x) Do you have anywhere recommended for me to document ?
It is a just intonation system (https://en.wikipedia.org/wiki/Just_intonation), but extended to include pitch shifts as an alternative to key changes (if your music software allows you to experiment with custom scales, you can simulate it by taking one of the diatonic scales from the article and multiplying or dividing the ratios with each other and writing a tune which starts in the original 7-tone scale and moves to or through one or more derived scales). There aren't a lot of unique ratios to derive within a single step, so you can probably fit the results of a single jump into a 12-tone scale. If you want to make a lot of jumps, you're better off using csound or something which allows you to specify note frequencies directly.

example: [*1/1 *9/8 5/4 4/3 *3/2 5/3 *15/8] x3/2 -> [*3/2 27/16 *15/8 *12/6 *9/4 15/6 45/16], tones which are common to both the original scale and the derived scale (equal or differing only by an octave) are marked with an asterisk, and thus are excellent candidates to use for transitional notes or chords
mmmPI
Smart Inserter
Smart Inserter
Posts: 4797
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Any interest in a music project?

Post by mmmPI »

Eketek wrote: Wed Oct 22, 2025 3:53 pm It is a just intonation system (https://en.wikipedia.org/wiki/Just_intonation), but extended to include pitch shifts as an alternative to key changes (if your music software allows you to experiment with custom scales, you can simulate it by taking one of the diatonic scales from the article and multiplying or dividing the ratios with each other and writing a tune which starts in the original 7-tone scale and moves to or through one or more derived scales). There aren't a lot of unique ratios to derive within a single step, so you can probably fit the results of a single jump into a 12-tone scale. If you want to make a lot of jumps, you're better off using csound or something which allows you to specify note frequencies directly.
I had heard of the name once , that's about my level, i'm far from understanding all of what you mean, even after reading the wikipage, because most of it i didn't understand either. ( which should probably gives some clues as to the fact that i'm most likely not fit for a collaboration.). I understand i think the "end result" in the math relation between the frequency of the notes, i suppose it's a bit of magic "why" it works as appreciable for the human ear. I can't easily tune FL studio to use just intonation to try, it's not amongst the proposed default scale, but it allows to use VST plugins and that opens up a range of method with trade-off tedious-to-set-up / easy-to-use-when-set-up to have the proper frequencies when pressing button or when the software plays. I would be following tutorial for a specific plugins, i've seen couple but it's a lenghy process, i'm not proficient enough to understand or make use of your example.

Method include remapping each note to a custom filter to slow/accelerate it if needed to change the pitch to match the new tuning, or generating individual audio files with the proper frequency and remapping them to custom keyboard, the later would be similar to how i would make it in factorio, to have the speaker playing notes with pre-calculated frequencies of that particular tuning.

Can you provide examples of music genre or song that you like / you wish your system could be use to play ?

Also to refocus on your original post, it's interesting, but also complex and requiring a lot of knowledge, you do what you want with it, but if you're asking for opinion, mine is that it would remain somewhat semi-private even if you were to make it public because that's the case for all music related mod in factorio, though you should make it public, because there's nothing like that already AFAIK.
Check out my latest mod ! It's noisy !
Post Reply

Return to “Modding discussion”