Wiki NIP
NIP-XX ======
Wiki ––
draft optional
This NIP defines kind:30818 (a parameterized replaceable event) for long-form text content similar to NIP-23, but with one important difference: articles are meant to be descriptions, or encyclopedia entries, of particular subjects, and it’s expected that multiple people will write articles about the exact same subjects, with either small variations or completely independent content.
Articles are identified by lowercase, normalized ascii d tags.
{
"content": "A wiki is a hypertext publication collaboratively edited and managed by its own audience.",
"tags": [
[ "d", "wiki" ],
[ "title", "Wiki" ],
]
}
[INSERT NORMALIZATION EXAMPLES]
The content should be Markdown, following the same rules as of NIP-23, although it only takes 2 extra (optional) metadata tags:
- title: for when the display title should be different from the d tag.
- summary: for display in lists.
One extra functionality is added: wikilinks. Unlike normal Markdown links []() that link to webpages, wikilinks [[]] link to other articles in the wiki. In this case, the wiki is the entirety of Nostr. Clicking on a wikilink should cause the client to ask relays for events with d tags equal to the target of that wikilink.
Event kind:30819 is also defined to stand for “wiki redirects”, i.e. if one thinks Shell structure should redirect to Thin-shell structure they can issue one of these events instead of replicating the content. These events can be used for automatically redirecting between articles on a client, but also for generating crowdsourced “disambiguation” pages (common in Wikipedia).
[INSERT EVENT EXAMPLE]
How to decide what article to display ———————————––
As there could be many articles for each given name, some kind of prioritization must be done by clients. Criteria for this should vary between users and clients, but some means that can be used are described below:
Reactions
NIP-25 reactions are very simple and can be used to create a simple web-of-trust between wiki article writers and their content. While just counting a raw number of “likes” is unproductive, reacting to any wiki article event with a + can be interpreted as a recommendation for that article specifically and a partial recommendation of the author of that article. When 2 or 3-level deep recommendations are followed, suddenly a big part of all the articles may have some form of tagging.
Relays
NIP-51 lists of relays can be created with the kind 10102 and then used by wiki clients in order to determine where to query articles first and to rank these differently in relation to other events fetched from other relays.
Contact lists
NIP-02 contact lists can form the basis of a recommendation system that is then expanded with relay lists and reaction lists through nested queries. These lists form a good starting point only because they are so widespread.
Appendix 1: Merge requests
Users can request other users to get their entries merged into someone else’s entry by creating a kind:818 event.
{
"content": "I added information about how to make hot ice-creams",
"kind": 818,
"tags": [
[ "a", "30818:<destination-pubkey>:hot-ice-creams", "<relay-url>" ],
[ "e", "<version-against-which-the-modification-was-made>", "<relay-url>' ],
[ "p", "<destination-pubkey>" ],
[ "e", "<version-to-be-merged>", "<relay-url>", "source" ]
]
}
.content: an optional explanation detailing why this merge is being requested.
a tag: tag of the article which should be modified (i.e. the target of this merge request).
e tag: optional version of the article in which this modifications is based
e tag with source marker: the ID of the event that should be merged. This event id MUST be of a kind:30818 as defined in this NIP.
The destination-pubkey (the pubkey being requested to merge something into their article can create NIP-25 reactions that tag the kind:818 event with + or -
Comments
Public conversation about this article.
No comments yet.
Article metadata
About this entry
Event Id
Raw event
Other authors
No one else has published this topic yet.
