Surfacing discussions
Welcome back to the Ghost Lab, where pull requests multiply faster than gremlins in the rain, and the phrase “just one more edge case, I swear” has been officially banned by HR (hi Beccy).
Last week, we swapped war stories about shipping ActivityPub; this week we’re diving into the true sport of the social web: keeping conversations readable once they start breeding like decentralized rabbits. Buckle up, because reply chains are a subject you're about to wish you didn't know so much about.
What's new with ActivityPub?
Discussions on the social web are surprisingly complex things, and recently we spent some time wrapping our paws around some of the finer details. The joy of this newsletter is that whenever we suffer, you get to share in that experience.
On the face of it, a discussion is just a chain of replies. You make a post, and someone else responds. You get a notification about the response, and that response shows up somewhere in the app, below the post you made.
All pretty straightforward. We know about your post, because it was made in Ghost, and we know about the replies, because they got sent directly into Ghost and they reference the post you made as what they're in response to.
So, a simple discussion is easy to render:
- 📍 Your original post
- Reply to OP
- Reply to OP
Discussions are rarely one-layer deep, though. When two people go back and forth with each other, each one of those responses is a new reply to a previous post.
Something you may have noticed in Ghost for the past few months, though, is that it took a lot of clicking to follow a discussion between two people. We'd only fetch the immediate replies to the post you're viewing, so for a long reply chain, you'd only see 1 level of replies below the current post. To see replies to the next level, you'd constantly need to click deeper into the discussion
- 📍 Your original post
post you're viewing
- Reply to OP
you can see this
- Reply to reply
you can't see this, or below
- Reply to reply-guy
- Reply to that reply
- Ok this is becoming a debate
- No, you
- Actually
- No, you
- Ok this is becoming a debate
- Reply to that reply
- Reply to reply-guy
- Reply to reply
- Reply to OP
As well as multiple layers of depth to a discussion, there might be multiple threads of discussion happening under your post. And this is where it starts to get interesting. You post from Ghost, someone replies to that post on Mastodon, someone else replies to the reply from Mastodon, on Mastodon. Now we're in a place where we (Ghost) aren't necessarily aware of all the replies taking place, because they're happening elsewhere.
- 📍 Your original post
- Reply to OP
- Reply to reply
- Reply to reply-guy
- Reply to reply
- Reply to reply
- Reply to OP
- Reply to reply
It doesn't stop there, though. Your original post might actually, itself, be a reply to a post that came before it. So when you view that post, you probably also want to see what it's in-reply-to, otherwise the context of the discussion is going to be hard to figure out.
If the first post is "That's the craziest thing I've ever heard" and the replies are all "I've heard crazier" – you're likely to have questions about the topic at hand.
- Parent post
- 📍 Your original post
- Reply to OP
- Reply to reply
- Reply to reply-guy
- Reply to reply
- Reply to reply
- Reply to OP
- Reply to reply
- Reply to OP
- 📍 Your original post
And (you can probably see where this is going) that post you're replying to may, itself, be a reply to some other post. The discussion tree has infinite levels in both directions. Your post and its replies may be a tiny branch on the end of a far larger tree of conversation.
- Great-grandparent post
- Grandparent post
- Parent post
- Someone else's original post
- Reply to OP
- Reply to reply
- Reply to OP
- Someone else's original post
- Parent post
- Parent post
- Grandparent post
- Parent post
- 📍 Your original post
- Reply to OP
- Reply to reply
- Reply to reply-guy
- Reply to reply-guy
- Reply to reply
- Reply to reply guy
- Reply to reply
- Reply to OP
- Reply to OP
- 📍 Your original post
- Parent post
- Grandparent post
All this to say, we've done a bunch of work in Ghost to crawl our way up and down the branches of a discussion, pull the most relevant posts around yours, and make them visible inline on the post you're viewing.
Now, rather than just seeing the immediate replies to a single post, you'll start to see larger chains of replies that have been surfaced to make it easier for you to follow a discussion.
Replies-to-replies are connected with a line:
And when the discussion has even more levels available to explore, we show a link to allow you to expand that particular thread:
The same is true when you click on a notification, where we'll load the post you clicked on and the 'parents' of that post, so you can scroll up to see the context of what came before.
It's not perfect, of course, but it's now much easier to get a feel for the conversation(s) happening in and around the posts you're viewing.
That’s the tour for this week’s code safari. Hit publish, poke the new threads, and let us know where the discussion tree still gets tangled.
Coming up next week (and you may have already seen some hints of this):
Better notifications!
wakest ⁂ reshared this.
Strypey
in reply to Building ActivityPub • • •> If someone replies to a reply, and nobody is around to see it. Did it really happen?
I remember a recent discussion of work to make AP threads more complete. Might be there's an FEP being drafted for it?
Building ActivityPub likes this.