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

[Request] Add category or genre to NIP-28 Public Chat (Kind 41 metadata or new kind) #1417

Open
ShinoharaTa opened this issue Aug 9, 2024 · 1 comment

Comments

@ShinoharaTa
Copy link

Overview

This request proposes adding category or genre information to NIP-28 Public Chat. By implementing this, chats can be categorized based on their content, allowing users to quickly access topics of interest.

Proposal

I propose introducing a field for category or genre in the current NIP-28 Public Chat specification. This field can be added to the existing Kind 41 metadata or defined as a new Kind.

ex. Kind 41

{
  "content": "{\"name\": \"Updated Demo Channel\", \"about\": \"Updating a test channel.\", \"picture\": \"https://placekitten.com/201/201\", \"relays\": [\"wss://nos.lol\", \"wss://nostr.mom\"]}",
  "tags": [
    ["e", <channel_create_event_id>, <relay-url>],
    ["category", <category_name-1>, <category_name-2>, <category_name-3>],
  ],
  ...
}

ex. Kind xx

{
  "content": "[<category_name>, <category_name>, <category_name>, <category_name>... ]",
  "tags": [["e", <channel_create_event_id>, <relay-url>]],
  ...
}

Benefits

Enhanced User Experience: Categorizing chats by category or genre will make it easier for users to access relevant topics.
Organized Content: Providing chats in a more organized manner will improve the quality of information sharing within the community.

@nikolat
Copy link
Contributor

nikolat commented Aug 9, 2024

Wouldn't it be better to reuse t tags than to create new category tags?
Tag names that are not single characters cannot be searched by the query.

{
  "kind": 41,
  "content": "{\"name\": \"Updated Demo Channel\", \"about\": \"Updating a test channel.\", \"picture\": \"https://placekitten.com/201/201\"}",
  "tags": [
    ["e", <channel_create_event_id>, <relay-url>, "root"],
    ["t", <category_name-1>],
    ["t", <category_name-2>],
    ["t", <category_name-3>],
  ],
  ...other fields
}

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

No branches or pull requests

2 participants