Skip to content


Repository files navigation

Woodshed Records

A toy jazz music generator


Jazz music is pretty easy right? The piano player just plays chords, the bass player goes up and down, and the sax player just plays random notes. Trust me, I took a music appreciation class in high school. Since we've already produced computer-generated vaporwave, procedurally generated jazz is the next logical step.


My good dude Ralph Patt set up a website with a bunch of chords for jazz standards. I harvested all of these html files using multi download tool for firefox and put them in charts_html/.

The HTMLs have a format that looks like this:

<TITLE>One Note Samba </TITLE>
<BODY bgcolor="#FFFFFF">


Key of Bb      4/4                                                                                                                                  

[   Dm7      |   Db7       |   Cm7        |  B7b5        |
|   Dm7      |   Db7       |   Cm7        |  B7b5        |
|   Fm7      |   Bb7       |   Eb         |  Ebm         | 

|   Dm7      |   Db7       |   Cm7  B7b5  |  Bb          | 
||  Ebm7     |   Ab7       |   Db         |  Db          | 

|   Dbm7     |   Gb7       |   Cb         |  Cm7b5  B7b5 | 	
|   Dm7      |   Db7       |   Cm7        |  B7b5        |
|   Dm7      |   Db7       |   Cm7        |  B7b5        |
|   Fm7      |   Bb7       |   Eb         |  Ebm         |

|   Db       |   C7        |   B          |  Bb          | 



I have a ruby script that reformats these HTMLs into jsons like this:

{"song_name":"ONE NOTE SAMBA","key":"Bb","time":"4/4","song_data":[[["Dm7"],["Db7"],["Cm7"],["B7b5"],["Dm7"],["Db7"],["Cm7"],["B7b5"],["Fm7"],["Bb7"],["Eb"],["Ebm"],["Dm7"],["Db7"],["Cm7","B7b5"],["Bb"]],[["Ebm7"],["Ab7"],["Db"],["Db"],["Dbm7"],["Gb7"],["Cb"],["Cm7b5","B7b5"],["Dm7"],["Db7"],["Cm7"],["B7b5"],["Dm7"],["Db7"],["Cm7"],["B7b5"],["Fm7"],["Bb7"],["Eb"],["Ebm"],["Db"],["C7"],["B"],["Bb"]]]}

From here, we transpose all the songs to C using song_trasponse.rb (This actually takes a pretty big shortcut. It just rejects songs that aren't in C).

After that, generate_song.rb makes a big markov hash out of the transposed songs that is used generate chord progressions. An A section and a B section is created, and the chord sheet is put in generated_songs/

Here's one that it generated:


Got some ii V I, some secondary dominant changes, and it's not just one chord to a bar. Nice.

I made a (really crappy) lead, piano, drum, and bass generator. Here's how this song, and many others, sound like when realized

Other cool links

This guy did something similar, but with neural nets and using band in a box, which is cheating, kind of? Also his progressions are a lot richer

This guy does some pretty cool stuff with neural nets, but no walking bass

This could help with melody generation


No releases published


No packages published