lCtx.setCurrentPhrase(p);
for (Note note : melody) {
p.addNote(note);
}
List<Note> modified = new ArrayList<>(Arrays.asList(melody));
generator.varyBaseStructure(lCtx, modified);
System.out.println(modified);
for (Note note : modified) {
p.addNote(note);
}