getSpotlightFocus method

Concept? getSpotlightFocus()

Returns the concept with the highest salience — the "spotlight" focus.

Implementation

Concept? getSpotlightFocus() {
  if (_buffer.isEmpty) return null;
  return _buffer.reduce(
    (a, b) => a.calculateSalience() >= b.calculateSalience() ? a : b,
  );
}