Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NIP frosty frost: NUDs #1214

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

NIP frosty frost: NUDs #1214

wants to merge 2 commits into from

Conversation

fiatjaf
Copy link
Member

@fiatjaf fiatjaf commented May 2, 2024

Formalizing the existence of external or proprietary specs that are still within the Nostr ecosystem.

https://github.com/nostr-protocol/nips/blob/nuds/ff.md

@alexgleason
Copy link
Member

I think it's a good idea.

I wish relays could indicate support. supported_nuds ?

@vitorpamplona
Copy link
Collaborator

vitorpamplona commented May 2, 2024

I am not sure if we need to change the name from NIP to NUD (to me they are the same thing), but great idea.

We could migrate all NIPs to NUDs with a random key out there.

Then we just need a way for Clients to declare compliance to each one and a website to rank them by compliance and boom, no need for this repo anymore.

Copy link
Member

@staab staab left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm with Vitor, we should just call these NIPs to avoid confusion, but NIP 54 is a great fit.

@alexgleason
Copy link
Member

alexgleason commented May 2, 2024

I like NUDs because NIPs have numerical IDs, eg supported_nips is a number[]. supported_nuds is a string[]

@alexgleason
Copy link
Member

Plus my wife will not roll her eyes every time I say NUDs.

@vitorpamplona
Copy link
Collaborator

Plus my wife will not roll her eyes every time I say NUDs.

That's a stronger point than the original.

@staab
Copy link
Member

staab commented May 2, 2024

Plus my wife will not roll her eyes every time I say NUDs.

You know this is going to be pronounced "nudes" right? The joke can't not be made, especially alongside "nips".

@staab
Copy link
Member

staab commented May 2, 2024

SNED NUDS

@vitorpamplona
Copy link
Collaborator

vitorpamplona commented May 2, 2024

SNED NUDS

At this point, I think @fiatjaf does these things on purpose. It's all about marketing.

-- Says the owner of "SheetStr"

@alexgleason
Copy link
Member

Alright, you ruined it. Thanks. 😃

@staab
Copy link
Member

staab commented May 2, 2024

At this point, I think @fiatjaf does these things on purpose

100%

@mleku
Copy link

mleku commented May 2, 2024

i want to see the abolition of this repository in favor of a wikifreedia subject/entry and associated tree of linked articles (with human readable labels instead of stupid numbers)

@arthurfranca
Copy link
Contributor

ACK!

@mleku i want to see the abolition of this repository in favor of a wikifreedia subject/entry and associated tree of linked articles (with human readable labels instead of stupid numbers)

It may be worth testing the idea of decentralizing NIPsNUDs by making this repo stop accepting new NIPs.
The repo's README.md could be converted to a explanation of what are NIPs (explain it isn't adding new entries) what are NUDs, with a link to a wikifreedia "NIP" (I guess singular title instead of plural as wikipedia does?) article authored by fiatjaf/official-nostr-npub with what is currently the README.md content (also the article would need to link to nip-01, 02, .. etc articles also authored by fiatjaf/official-nostr-npub) and a link to a "NUD" article (but this time not from a specific author).

Does wikifreedia have article comments? If not, meanwhile this repo could continue being used for new NUD discussions.

@alexgleason
Copy link
Member

The NIPs repo is one of the main things holding Nostr together. To abolish it would be brave but retarded. How about we see how well this new thing works first. Has anybody published a NUD yet? What is the best client for doing so?

@staab
Copy link
Member

staab commented May 2, 2024

The NIPs repo is one of the main things holding Nostr together. To abolish it would be brave but retarded. How about we see how well this new thing works first. Has anybody published a NUD yet? What is the best client for doing so?

Yeah, seconded. We need the tools to publish and read nostr-native NIPs before it can become a useful source of information. Maybe wikifreedia can be co-opted to support them. But that has to be built first.

@arthurfranca
Copy link
Contributor

I may be wrong but I think NUDs won't become a thing if this repo keeps accepting new NIPs. The current repo maintainers may curate NUDs by writing a "NUD" article with a shared key.

@mikedilger
Copy link
Contributor

I'm not fond of the kind-specific d-tag parsing.

@fiatjaf
Copy link
Member Author

fiatjaf commented May 3, 2024

I may be wrong but I think NUDs won't become a thing if this repo keeps accepting new NIPs.

NIP numbers are scarce and they're about to end.

@arthurfranca
Copy link
Contributor

NIP numbers are scarce and they're about to end.

Alright the 01 to 99 range I suppose. I guess niche specs such as #1094 don't deserve a rare NIP slot but are free to become NUDs.

@mleku
Copy link

mleku commented May 6, 2024

i like it, now we just need to get the wikifreedia polished up a bit more so this kind of thing can become normal

i did a lot of work making a more human-readable way of mapping out the structure of the protocol, and it is a lot easier to navigate and learn

i think the key thing to understand about this is that NIPs tend to be too narrow, with the exception of the first one, that you end up with this giant index in your memory "now what is 42? what is 59? what is 3?" instead of a mnemonic word or phrase that makes it patently obvious what it relates to, that can be stacked under subections like how i did with envelope types and the top level envelope parsing flow logic in my nostr library ( https://github.com/Hubmakerlabs/replicatr/pkg/nostr )

@arthurfranca arthurfranca mentioned this pull request May 23, 2024
71.md Outdated
Comment on lines 27 to 30
["d", "nud:ordinals-comments"]
["title", "NUD: Ordinals Comments"]
],
"content": "# NUD: Ordinals Comments\n\nThis NUD defines how to comment on Bitcoin Ordinals using Nostr events.\n\nEvents should be of kind 10773 and include a tag in the format [\"o\", \"1928604426675219\"] in which 1928604426675219 is the satoshi number given by `ord`. Aside from that these events follow the rules of kind 1.",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Like wikipedia that has a "Beer" article instead of "Beers"

Suggested change
["d", "nud:ordinals-comments"]
["title", "NUD: Ordinals Comments"]
],
"content": "# NUD: Ordinals Comments\n\nThis NUD defines how to comment on Bitcoin Ordinals using Nostr events.\n\nEvents should be of kind 10773 and include a tag in the format [\"o\", \"1928604426675219\"] in which 1928604426675219 is the satoshi number given by `ord`. Aside from that these events follow the rules of kind 1.",
["d", "nud:ordinal-comment"]
["title", "NUD: Ordinal Comment"]
],
"content": "# NUD: Ordinal Comment\n\nThis NUD defines how to comment on Bitcoin Ordinals using Nostr events.\n\nEvents should be of kind 10773 and include a tag in the format [\"o\", \"1928604426675219\"] in which 1928604426675219 is the satoshi number given by `ord`. Aside from that these events follow the rules of kind 1.",

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know, doesn't Wikipedia have any articles about plural things?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What I said isn't strictly right. If it's a movie name like "Gremlins", the article name won't be in the singular. So yeah if you say the NUD name is Ordinals Comments, it won't be wrong.

Though imo trying to name things in singular could help preventing articles about the same thing with different d tags like ordinals-comments, ordinals-comment, ordinal-comments, ordinal-comment.

Another suggestion to help lowering d tag variation: while the title could keep being "NUD: Ordinal Comment", the d tag could have a convention that one or more non-word characters become a dash, so ["d", "nud-ordinal-comment"].

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2024-05-24-215536_275x154_scrot

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was unexpected but I guess the article from the screenshot isn't related to the movie. https://en.wikipedia.org/wiki/Gremlin_(disambiguation)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm sorry, I was going to write that it was a joke, but I forgot to do that.

@AsaiToshiya
Copy link
Collaborator

We can't fetch only NUDs, right? For example, do we need ["l", "nud"]?

@pablof7z
Copy link
Member

We can't fetch only NUDs, right? For example, do we need ["l", "nud"]?

You can fetch by #c: ["Nostr"] to get all the nostr-specific things

@fiatjaf
Copy link
Member Author

fiatjaf commented May 30, 2024

You can fetch by #c: ["Nostr"] to get all the nostr-specific things

Can you? What is this c tag about? I've never heard of that.

@AsaiToshiya
Copy link
Collaborator

Can you? What is this c tag about? I've never heard of that.

Probably the c tag is a category. I opened #1270.

71.md Outdated

NUDs are defined as [NIP-54](54.md) **kind:30818** events.

They should have a `d` tag starting with `"nud:"` followed by a succinct and identifiable name so they can be referred to in other contexts.
Copy link
Member

@staab staab May 30, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is a mistake. Having drafted a nud, I find myself at a loss of how to refer to it. NUD: custom feeds is unwieldy and potentially ambiguous. What if the d tag was a random 256-bit hex number? We could then refer to NUDs by the first n digits of the hex, for example NUD f38. This gives us 4096 3-digit short hand identifiers, which of course could be further disambiguated by including more digits. This would also accommodate situations where the name changes, which happens pretty commonly with NIPs.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is what FEPs do, but I don't know where the hex comes from. https://codeberg.org/fediverse/fep

Copy link
Member

@alexgleason alexgleason May 30, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

However, don't wiki's already use plain English d-tags?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, but the purpose of a wiki is to define a term. The only term involved in a NUD is the NUD itself, since the articulation of the purpose of the NUD may change. This is the same thing going on as with kind numbers and NIP numbers, which is a genius aspect of the protocol.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@alexgleason Apparently it's the hash of the title, which does not solve the problem. Why not just pick a random 4 digit hex string? I guess 65536 are enough NUDs no? Also by restricting it to be outside the 1-99 range, we could keep calling them NIPs (I'm also with @vitorpamplona and @staab on this).

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For context, wikipedia also deals with name changes like https://en.wikipedia.org/wiki/Internet_celebrity that people want to change to https://en.wikipedia.org/wiki/Influencer (for now, Influencer redirects to Internet_celebrity).

If you ask me, I'd change d-tag from nud:orange-cars to orange-car and point the article to the nud article using something like these r tags. See, what makes it a NUD, is the reference to the NUD article.

Heheh everyone wants to do it differently

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@staab

NIPs get renamed all the time, it would be nice to be able to rename a NUD but keep references intact.

What @arthurfranca said.

You'll also have collisions if there end up being two distinct NUDs that are named the same thing (e.g. "NUD: Read Receipt").

That's why NUDs are tied to a unique owner. So we'll have Bob's Read Receipt and Carol's Read Receipt.

That would make it impossible to fork both NUDs under the same pubkey.

Yes, but it makes no sense to fork your own NUD. You can just edit it, or make a new thing with a slightly different name, be creative.

Hence my suggestion to use more randomness

Someone can just pretend to be generating random numbers and collide with all your NUDs on purpose, now what?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, but it makes no sense to fork your own NUD.

There might be a collision between two NUDs belonging to other people that you want to fork.

Someone can just pretend to be generating random numbers and collide with all your NUDs on purpose, now what?

Replaceable events were a mistake, we should just use e tags and build a tree.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can't build a tree, you can only plant a tree.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can't build a tree, you can only plant a tree.

you grow trees by attaching limbs to them at nodes, which you indirectly do by watering real trees, but data structure trees you grow by attaching limbs at nodes

@melvincarvalho

This comment was marked as spam.

@SilberWitch SilberWitch mentioned this pull request Sep 2, 2024
@fiatjaf fiatjaf changed the title NIP-71: NUDs NIP frosty frost: NUDs Nov 12, 2024
@fiatjaf fiatjaf marked this pull request as ready for review November 12, 2024 00:49
@arthurfranca
Copy link
Contributor

agree the wiki article requirement was holding nuds back
🚀

@pablof7z
Copy link
Member

what if we include a suggestion to publish (yes, where to publish is an unsolved problem but there would be an incentive to publish in places where this info can be found) a simple event of some kind (e.g. kind:9876) pointing the event kind to something that has more information about how the kind is being used.

E.g. nostrocket could indicate it's using kind:1971 and some pointers (e.g. an a and/or a url tag) pointing to where more info about this can be found.

{
    "pubkey": "fa984bd7dbb282f07e16e7ae87b26a2a7b9b90b7246a44771f0cf5ae58018f52",
    "content": "Problem Tracker",
    "kind": 9876,
    "tags": [
        [ "k", "1971" ],
        [ "a", "30818:fa984bd7dbb282f07e16e7ae87b26a2a7b9b90b7246a44771f0cf5ae58018f52:nostrocket-nud" ],
        [ "url", "https://some-url/nostrocket"]
    ]
}

This is completely unnecessary but would be kinda cool to be able to REQ for information of who and for what some kind is being used.

REQ, ..., '{ "kinds": [9876], "#k": ["1971"] }'

Maybe this is dumb, just sounds cool

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.