   (om/transact! component `[(ui/set-props ~props)]))
 
 (defn check-answer [c]
-  (let [{:keys [ui/ex-answer ::correct-answer ui/correct-count]} (om/props c)]
+  (let [{:keys [daveconservatoire.site.ui.exercices/ex-answer ::correct-answer daveconservatoire.site.ui.exercices/streak-count]} (om/props c)]
     (if (= ex-answer correct-answer)
       (do
         (merge-props! c
-          (merge {:ui/correct-count (inc correct-count)
-                  :ui/ex-answer nil})))
-      (um/set-value! c :ui/correct-count 0))))
+          (merge {::streak-count (inc streak-count)
+                  ::ex-answer    nil})))
+      (um/set-value! c ::streak-count 0))))
 
 (defn render-ex [c]
-  (let [{:keys [::description ::options :ui/ex-answer
-                :ui/ex-total-questions :ui/correct-count] :as props} (om/props c)]
-    (assert (s/valid? ::ex-props props))
+  (let [{:keys [::description ::options ::ex-answer
+                ::ex-total-questions ::streak-count] :as props} (om/props c)]
+    (assert (s/valid? ::ex-props props) (s/explain-str ::ex-props props))
     (dom/div #js {:className "lesson-content"}
       (dom/div #js {:className "single-exercise visited-no-recolor"
                     :style     #js {:overflow "hidden" :visibility "visible"}}


(om/defui ^:once Exercice
  static uc/InitialAppState
  (initial-state [_ _] {:ui/ex-answer nil
                        :ui/ex-total-questions 10
                        :ui/correct-count 0})

  static om/IQuery
  (query [_] [::description ::options ::notes ::correct-answer :parent
              :ui/ex-answer :ui/ex-total-questions :ui/correct-count])

  static om/Ident
  (ident [_ props] (om/ident (:parent props) props))

  Object
  (render [this]

  :args (s/cat :props (s/keys :opt [::progress-total ::progress-value])
               :children (s/* ::react-component)))

(defn play-notes [notes]
  (let [nodes (->> notes
                   (into [] (map (fn [s]
                                   {::audio/node-gen (->> s audio/semitone->note (get @audio/*sound-library*))}))))]
    (audio/play-regular-sequence nodes {::audio/time     (audio/current-time)
                                        ::audio/interval 2})))

(defn play-sound [c] (play-notes (-> (om/props c) ::notes)))
