Updates to Active Filters

The Lasair filter system has been updated. A key idea of Lasair is the “active” filter, meaning that the filter is run in real time as the alerts come in from Rubin. In the past, this meant that the attributes of the SELECT part of the filter are produced for the owner of the filter, and sent out by Kafka or by email. A few months ago, the output choices were expanded to also include a “lite” version of the lightcurve, or the full (very large) lightcurve. More detail is in the post Fat Kafka Streams.

The latest update is not just about what data is output, but also the trigger mechanism to make that output happen. Now the Kafka/email output can be triggered by the arrival of an alert and/or the arrival of an annotation. Let us first summarise how Lasair users can add value and share with others using annotations:

  • User Alice builds feeder filter and consumes its Kafka
  • Alice’s code analyses lightcurve and creates added value eg classification
  • Alice’s code pushes annotation back to Lasair
  • Bob’s filter (that uses Alice’s annotator) runs
  • Bob’s code gets Kafka results

In the old scheme, Bob’s filter, and ever other filter, is triggered by the arrival of an alert; even if Alice’s annotator has added information to Lasair 5 minutes after the alert that made it run, Bob will not know about this until there is another detection of the same object, which may be many days later.

In the new scheme, Bob can choose to have his filter triggered by the arrival of the annotation of the object, rather than by the arrival of a detection of that object. However, note that this affects only filters that incorporate an annotator; if that is not the case, the only option for an active filter is to trigger on alert.

What does this mean for the user, when creating, saving, or duplicating an active filter?

  • If the filter doesn’t include an annotator, the only Trigger choice is “On new alert”.
  • If it does include an annotation, choose “On new alert” or “On new annotation”, or both.

For more information and screenshots see Alert Streams in the documentation.