 (def shruthi :c)
 (def tempo 80)
 (def jathi 4)
+(def kalams {:lower  1
+             :middle 2
+             :higher 3})
 
 (defn default-durations [num-swarams]
   (take num-swarams (repeatedly (constantly jathi))))


  (play-phrase (phrase [:s :r2 :g3 :p :m1 :g3 :r2 :s]
                       [ 1   1  1  1   1   1   2   4]
                       1))

  (play-phrase
   (phrase (:mechakalyani r/ragams)
           [:m :d :n :g :m :d :r :g :m  :g :m :d :n :s.]
           [ 1  1  2  1  1  2  1  1  4   1  1  1  1  4]
           2))

  (play-string (:bilahari r/ragams)
               "s,,r g,p, d,s., n,d, p,dp mgrs rs .n .d s,,,

        split-seq (re-seq (re-pattern swaram-with-duration) s)
        swarams (map #(keyword (re-find (re-pattern swaram) %)) split-seq)
        durations (map #(count (s/replace % #"\." "")) split-seq)]
    (phrase ragam swarams durations (:middle kalams))))

(defn play-string [raga string]
  (play-phrase
