On the plane I came up with an algorithm that does the following:
given a set of filters, find all filters that are redundant. It pretty simple, you just determine if a filter is a subset of any other filter in the set, and then you prune those.
Example: everything is a subset of {}, the filter that matches everything, so this algorithm could take a list of 100 filters, and if {} was present it would only return that 1 filter.
This is useful for notedeck, as you would only need to open the minimal number of subscriptions remotely, while still having granular local filters active on nostrdb.
Will write up this algo soon, i have some of the code done already.
gm nostr
👏 Good morning. Check DM.
you might have to email me because I don’t have a good email client for nostr dms yet jb55@jb55.com
Agree. In the future, determining what goes in each filter and in each sub and to which relay can be fully automated. The UI just subscribes to an extended definition of the current filter spec (more like the Custom Feeds from nostr:nprofile1qqsf03c2gsmx5ef4c9zmxvlew04gdh7u94afnknp33qvv3c94kvwxgspr3mhxue69uhksmmyd33x7epwvdhhyctrd3jjuar0dak8xtcppemhxue69uhkummn9ekx7mp0qy2hwumn8ghj7un9d3shjtnyv9kh2uewd9hj7208x3z) and the merging algo can figure everything out.
Yeah, this idea is basically the flipside of subscription merging
hopefully a nice snatch(0_o) .from the mind, mfrs!