# -*- coding, utf-8 -*-

from collections import OrderedDict

QUALITY_DICT = OrderedDict((
    # chords consist of 2 notes
    ('5', (0, 7)),
    ('sus', (0, 7)),
    # 3 notes
    ('', (0, 4, 7)),
    ('maj', (0, 4, 7)),
    ('-', (0, 3, 7)),
    ('m', (0, 3, 7)),
    ('min', (0, 3, 7)),
    ('dim', (0, 3, 6)),
    ('aug', (0, 4, 8)),
    ('sus2', (0, 2, 7)),
    ('sus4', (0, 5, 7)),
    # 4 notes
    ('6', (0, 4, 7, 9)),
    ('7', (0, 4, 7, 10)),
    ('7-5', (0, 4, 6, 10)),
    ('7b5', (0, 4, 6, 10)),
    ('7+5', (0, 4, 8, 10)),
    ('7#5', (0, 4, 8, 10)),
    ('7sus4', (0, 5, 7, 10)),
    ('m6', (0, 3, 7, 9)),
    ('m7', (0, 3, 7, 10)),
    ('m7b5', (0, 3, 5, 10)),
    ('m7-5', (0, 3, 6, 10)),
    ('dim6', (0, 3, 6, 9)),
    ('M7', (0, 4, 7, 11)),
    ('maj7', (0, 4, 7, 11)),
    ('M7+5', (0, 4, 8, 11)),
    ('mM7', (0, 3, 7, 11)),
    ('add9', (0, 4, 7, 14)),
    ('madd9', (0, 3, 7, 14)),
    ('2', (0, 4, 7, 14)),
    ('add11', (0, 4, 7, 17)),
    ('4', (0, 4, 7, 17)),
    # 5 notes
    ('m69', (0, 3, 7, 9, 14)),
    ('69', (0, 4, 7, 9, 14)),
    ('9', (0, 4, 7, 10, 14)),
    ('m9', (0, 3, 7, 10, 14)),
    ('M9', (0, 4, 7, 11, 14)),
    ('maj9', (0, 4, 7, 11, 14)),
    ('9sus4', (0, 5, 7, 10, 14)),
    ('7-9', (0, 4, 7, 10, 13)),
    ('7b9', (0, 4, 7, 10, 13)),
    ('7+9', (0, 4, 7, 10, 15)),
    ('7#9', (0, 4, 7, 10, 15)),
    ('9-5', (0, 4, 6, 10, 14)),
    ('9b5', (0, 4, 6, 10, 14)),
    ('9+5', (0, 4, 8, 10, 14)),
    ('9#5', (0, 4, 8, 10, 14)),
    ('7#9b5', (0, 4, 6, 10, 15)),
    ('7#9#5', (0, 4, 8, 10, 15)),
    ('7b9b5', (0, 4, 6, 10, 13)),
    ('7b9#5', (0, 4, 8, 10, 13)),
    ('11', (0, 7, 10, 14, 17)),
    ('7+11', (0, 4, 7, 10, 18)),
    ('7#11', (0, 4, 7, 10, 18)),
    ('7b9#9', (0, 4, 7, 10, 13, 15)),
    ('7b9#11', (0, 4, 7, 10, 13, 18)),
    ('7#9#11', (0, 4, 7, 10, 15, 18)),
    ('7-13', (0, 4, 7, 10, 20)),
    ('7b13', (0, 4, 7, 10, 20)),
    # 6 notes
    ('7b9b13', (0, 4, 7, 10, 13, 17, 20)),
    ('9+11', (0, 4, 7, 10, 14, 18)),
    ('9#11', (0, 4, 7, 10, 14, 18)),
    ('13', (0, 4, 7, 10, 14, 21)),
    ('13-9', (0, 4, 7, 10, 13, 21)),
    ('13b9', (0, 4, 7, 10, 13, 21)),
    ('13+9', (0, 4, 7, 10, 15, 21)),
    ('13#9', (0, 4, 7, 10, 15, 21)),
    ('13+11', (0, 4, 7, 10, 18, 21)),
    ('13#11', (0, 4, 7, 10, 18, 21)),
))

@@ -219,30 +219,8 @@
 )),%0A
-    ('-', (0, 3, 7)),%0A
     
@@ -257,24 +257,46 @@
 (0, 3, 7)),%0A
+    ('-', (0, 3, 7)),%0A
     ('dim', 
@@ -661,17 +661,17 @@
  (0, 3, 
-5
+6
 , 10)),%0A

move - notation down & fix chord values for m7b5