   (signal!
     [_]
     (reset! prev-val @value)
+    (swap! state assoc ::new-edges 0)
     ((::signal-fn @state) _)
     _)
   (signal!
     [_ handler]
     (reset! prev-val @value)
+    (swap! state assoc ::new-edges 0)
     (handler _)
     _)
   (receive-signal

   ::score-signal-fn  default-score-signal
   ::collect-fn       collect-into
   ::signal-fn        async-vertex-signal
   ::input-channel-fn chan})

(defrecord Vertex [id value state prev-val in outs]
  #?@(:clj

          (let [signal (f vertex opts)]
            (if-not (nil? signal)
              (>! (input-channel v) [id signal])
              (debug "signal fn for" (:id v) "returned nil, skipping...")))
          (recur (next outs)))))))

(defn sync-vertex-signal
