søren peter mørch

xuu (txt.sour.is)

I share I did write up an algorithm for it at some point I think it is lost in a git comment someplace. I'll put together a pseudo/go code this week.

Super simple:

Making a reply: 0. If yarn has one use that. (Maybe do collision check?)

  1. Make hash of twt raw no truncation.
  2. Check local cache for shortest without collision
    • in SQL: select len(subject) where head_full_hash like subject || '%'

Threading:

  1. Get full hash of head twt
  2. Search for twts
    • in SQL: head_full_hash like subject || '%' and created_on > head_timestamp

The assumption being replies will be for the most recent head. If replying to an older one it will use a longer hash.

In reply to: #yaicyiq 2 years ago
Reply via email