upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/32.md
diff options
context:
space:
mode:
authorJonathan Staab <shtaab@gmail.com>2023-05-17 12:50:29 -0700
committerJonathan Staab <shtaab@gmail.com>2023-06-13 09:31:15 -0700
commit95f537e90d568ff23e485f336d251b5d415e1191 (patch)
tree877687aad27ed63a7d906e96573133f964c64c62 /32.md
parent34910c8674917a687ed7a71bb4968d6a54ee3f55 (diff)
Add relay hints, replaceable events, and clarification about content to NIP 32
Diffstat (limited to '32.md')
-rw-r--r--32.md29
1 files changed, 20 insertions, 9 deletions
diff --git a/32.md b/32.md
index 0180a23..b84fc64 100644
--- a/32.md
+++ b/32.md
@@ -6,7 +6,7 @@ Labeling
6 6
7`draft` `optional` `author:staab` `author:gruruya` `author:s3x-jay` 7`draft` `optional` `author:staab` `author:gruruya` `author:s3x-jay`
8 8
9A label is a `kind 1985` note that is used to label other entities. This supports a number of use cases: 9A label is a `kind 1985` (regular) event or `kind 32144` (replaceable) event that is used to label other entities. This supports a number of use cases:
10 10
11- Distributed moderation and content recommendations 11- Distributed moderation and content recommendations
12- Reviews and ratings 12- Reviews and ratings
@@ -22,7 +22,12 @@ Label Target
22 22
23The label event MUST include one or more tags representing the object or objects being 23The label event MUST include one or more tags representing the object or objects being
24labeled: `e`, `p`, `r`, or `t` tags. This allows for labeling of events, people, relays, 24labeled: `e`, `p`, `r`, or `t` tags. This allows for labeling of events, people, relays,
25or topics respectively. 25or topics respectively. As with NIP-01, a relay hint SHOULD be included when using `e` and
26`p` tags.
27
28Any number of targets may be included when using a kind `1985` non-replaceable event. If kind
29`32144` is preferred, the event MUST have a single target tag, and its value MUST also be the
30value of the `d` tag.
26 31
27Label Tag 32Label Tag
28---- 33----
@@ -51,6 +56,12 @@ absolute, granular scale that can be represented in any way (5 stars, color scal
51 56
52The label event MAY include a `confidence` tag with a value of 0 to 1. This indicates the certainty which the author has about their rating. 57The label event MAY include a `confidence` tag with a value of 0 to 1. This indicates the certainty which the author has about their rating.
53 58
59Content
60-------
61
62`l` tags should be short, meaningful strings. Longer discussions, such as for a review, or an
63explanation of why something was labeled the way it was should go in the event's `content` field.
64
54Example events 65Example events
55-------------- 66--------------
56 67
@@ -64,7 +75,7 @@ cases.
64 "tags": [ 75 "tags": [
65 ["L", "report"], 76 ["L", "report"],
66 ["l", "nudity", "report"], 77 ["l", "nudity", "report"],
67 ["e", <id>] 78 ["e", <id>, <relay_url>]
68 ], 79 ],
69 "content": "", 80 "content": "",
70 ... 81 ...
@@ -78,8 +89,8 @@ namespaces may be used at the same time.
78{ 89{
79 "kind": 1985, 90 "kind": 1985,
80 "tags": [ 91 "tags": [
81 ["e", <id>], 92 ["e", <id>, <relay_url>],
82 ["p", <id>], 93 ["p", <id>, <relay_url>],
83 ["t", "chickens"], 94 ["t", "chickens"],
84 ["L", "#t"] 95 ["L", "#t"]
85 ["L", "ugc"] 96 ["L", "ugc"]
@@ -103,8 +114,8 @@ A suggestion that multiple pubkeys be associated with the `permies` topic.
103 "tags": [ 114 "tags": [
104 ["L", "#t"], 115 ["L", "#t"],
105 ["l", "permies", "#t"], 116 ["l", "permies", "#t"],
106 ["p", <pubkey1>], 117 ["p", <pubkey1>, <relay_url>],
107 ["p", <pubkey2>] 118 ["p", <pubkey2>, <relay_url>]
108 ], 119 ],
109 "content": "", 120 "content": "",
110 ... 121 ...
@@ -156,8 +167,8 @@ this spec provides for overlaying structured metadata on top of nostr.
156 "tags": [ 167 "tags": [
157 ["L", "my-lightning-nomenclature"], 168 ["L", "my-lightning-nomenclature"],
158 ["l", "channel", "my-lightning-nomenclature"], 169 ["l", "channel", "my-lightning-nomenclature"],
159 ["p", <pubkey1>], 170 ["p", <pubkey1>, <relay_url>],
160 ["p", <pubkey2>] 171 ["p", <pubkey2>, <relay_url>]
161 ], 172 ],
162 "content": "<channel_id>", 173 "content": "<channel_id>",
163 ... 174 ...