Alex Yoder Profile picture
composer/arranger, developer, tinkerer -- wrote OSTs for Crawl, Soviet Jump Game, PULSAR: Lost Colony, NecroBouncer -- Chrysalis (in dev) https://t.co/hcyFNzGgiF

Dec 2, 2022, 13 tweets

Trying to teach ChatGPT how to write music has been...interesting. In my first attempt, I gave it a simple notation format and a tiny example melody. It returned a melody with correct format, same rhythm, and nicely complemented my original fragment.

Notice that the previous melody ends on C5, so it changed octaves correctly even though my example was all within the 4th octave. Then, it gave me my original melody back, but transposed to begin on F4 (a very appropriate "musical response" if one is composing in C Major)

Next I tried adding rests and sixteenth notes. Again it followed my example's rhythmic division, but changed one of the sixteenth notes to a rest.

Here's how that sounds when it immediately follows my melody (in 4/4):

The next one was surprisingly original. It sounds melodic, uses a unique rhythm, and doesn't begin on tonic. It also adds a rest on the end which exactly fills out two 4/4 bars...is this just a fluke or did it assume an appropriate time signature?

Here's how that one sounds immediately following my example melody:

Then I introduced accidentals (# for sharp). It started using half notes on its own (I never used them in my examples), I told it the melody was too high and it correctly transposed down an octave, then I told it to change key and it correctly transposed the melody.

Now for something harder: implied modulation. Spoiler: it works! And it explains why it works. I give it some pointers to strengthen the sense of modulation, and it correctly incorporates the suggestion. However...

there's an awkward part where it introduced the F-sharp during the modulation. I tell it to rewrite that part to sound more natural. It does, and it explains why the new melody sounds smoother.

Here's what the melody with modulation sounds like:

Then I asked for an accompaniment to this melody with arpeggiated 8th notes. The first attempt was only 2 measures long, so I asked it for the full 4 measures of accompaniment.

After asking it to transpose the accompaniment down an octave so it could be performed by a pianist, this is the final result. Awkward in spots, and just repeats itself, but still kinda works.

I tried some additional prompts for more interesting harmony in the accompaniment, but nothing has really worked out yet. I'm planning to continue experimenting with different types of prompts, but for an initial attempt this was fairly impressive (and fun).

Share this Scrolly Tale with your friends.

A Scrolly Tale is a new way to read Twitter threads with a more visually immersive experience.
Discover more beautiful Scrolly Tales like this.

Keep scrolling