From 1bbd87c42fe6ca6caa7582fdb89a355b6dfc70f4 Mon Sep 17 00:00:00 2001 From: fiatjaf Date: Wed, 15 Nov 2023 07:33:26 -0300 Subject: [PATCH] distinction between lists and sets. --- 51.md | 30 +++++++++++++++++++++--------- 1 file changed, 21 insertions(+), 9 deletions(-) diff --git a/51.md b/51.md index 3ac89959..b184f428 100644 --- a/51.md +++ b/51.md @@ -14,19 +14,31 @@ Public items in a list are specified in the event `tags` array, while private it The kinds `30000` and `30001` have been reserved for generic lists. These must be accompanied by a `d` tag identifying the list, but these are generally client-specific, except in the standard cases specified below. -## Standard lists +### Standard lists -| name | kind | "d" tag | description | expected tag items | -| --- | --- | --- | --- | --- | -| Mute list | 30000 | `"mute"` | things the user doesn't want to see in their feeds | `"p"` (pubkeys), `"t"` (hashtags) | -| Bookmarks list | 30001 | `"bookmark"` | things the user intends to save for the future | `"e"` (kind:1 notes), `"a"` (kind:30023 articles) | -| Pin list | 30001 | `"pin"` | events the user intends to showcase in their profile page | `"e"` (kind:1 notes) | -| Communities list | 30001 | `"communities"` | [NIP-72](72.md) communities the user belongs to | `"a"` (kind:34550 community definitions) | -| Relay sets | 30002 | (user-defined) | user-defined relay groups the user can easily pick and choose from during variadic operations | `"relay"` (relay URLs) | +These are some standards that emerged in the wild: + +| name | kind | "d" tag | description | expected tag items | +| --- | --- | --- | --- | --- | +| Mute list | 30000 | `"mute"` | things the user doesn't want to see in their feeds | `"p"` (pubkeys), `"t"` (hashtags) | +| Bookmarks list | 30001 | `"bookmark"` | things the user intends to save for the future | `"e"` (kind:1 notes), `"a"` (kind:30023 articles) | +| Pin list | 30001 | `"pin"` | events the user intends to showcase in their profile page | `"e"` (kind:1 notes) | +| Communities list | 30001 | `"communities"` | [NIP-72](72.md) communities the user belongs to | `"a"` (kind:34550 community definitions) | + +## Sets + +Sets are lists with well-defined meaning and purpose and user-assigned `d` tags meant to be displayed in the UI. For example, _relay sets_ can be displayed in a dropdown UI to give users the option to switch to which relays they will publish an event or from which relays they will read the replies to an event; or _curation sets_ can be used by apps to showcase curations made by others tagged to different topics. + +Aside from their main identifier, the `"d"` tag, sets can optionally have a `"title"`, an `"image"` and a `"description"` tag that can be used to enhance their UI. + +| name | kind | description | expected tag items | +| --- | --- | --- | --- | +| Relay sets | 30002 | user-defined relay groups the user can easily pick and choose from during variadic operations | `"relay"` (relay URLs) | +| Article Curation sets | 30003 | groups of articles picked by users as interesting and/or belonging to the same category | `"a"` (kind:30023 articles) | ## Examples -### A _Mute list_ with some public items and some encrypted items +### A _mute list_ with some public items and some encrypted items ```json {