Oddbean new post about | logout
 how do those reply bots manage to reply to every post in the first place? how do they know?

can they get a feed of every single post, even on the busy relays? 
 I think it has to do with EOSE:
https://github.com/nostr-protocol/nips/blob/master/01.md#from-relay-to-client-sending-events-and-notices 
 sure, but i'm just surprised relays allow such blanket queries

it's so fast it must be a response to a real-time notification, so the bot must have a persistent websocket open 
 good point, I think they do keep a persistent websocket open 
 Mostr uses a persistent connection and listens to kind 1 (and other) events from anyone too. 
 They just subscribe event with filter kind: 1. Relay will publish any match nostr event to those subscriber (any clients) connected to relay websocket. 
 interesting
if i had one on my relay i'd play around with that a bit 
 My bot nostr:nprofile1qqsv2kx8e35mhk3uyutc9dekh27xftxjmgjck98n2mdu49nvkzmm38spyemhxue69uhkvars9e5xzmrfveshstnjwa6xsttpv93ksetw9ejx2tmwdaehguspzamhxue69uhhyetvv9ujuurjd9kkzmpwdejhgtcpypmhxue69uhkummnw3ezuetfde6kuer6wasku7nfvuh8xurpvdjj7r7gm4u also has open subscriptions for kind 1 to a couple relays and parses every single received event. Can keep up fine and doesn't even need much resources. 
 interestingly i get reply guy spam on the primal relay even though i don't write my messages there
either some relay i write to is immediately cross-posting there (?)
or, the bot doesn't send their replies to the same relay that it reads the notifications from 
 Can't rely on the bots relay list. It can read from, and write to, any relay it wants. It probably subscribes to new kind 1 events from most of the popular free relays and automatically replies to that event on all relays. Maybe the relay it mentions in it's post is the first it reads the note from? 
 i think the relay it mentions in the message is the one the note *goes to*
at least, in this case: i see it coming from primal.net in my client, and it mentions primal.net

what i wonder is where it reads the original note from, because i don't write to primal.net
i suspect damus.io or nos.lol even though they don't have the spam themselves 😀  
 Yeah, it's probably like this:
1. Bot subscribes to kind 1 events from a big set of relays
2. Bot receives a new event from any relay
3. For each relay it wants to write to, it signs a reply event (mentioning the relay url).
4. Send all the signed reply events to all relays