-
Notifications
You must be signed in to change notification settings - Fork 0
Algorithms
The Nostr protocol provides a rich ground for developing a variety of algorithms that can enhance the user experience by customizing the content delivery based on specific user preferences, temporal relevance, or trending topics. This article provides a brief overview of some hypothetical and abstract algorithms that could be implemented in the Nostr ecosystem.
Note: The algorithms mentioned here are not exhaustive, and they do not constitute a recommendation for implementation. Their purpose is merely illustrative, to demonstrate the potential of the Nostr platform. Any algorithm should go through the approval process detailed in the Nostr Improvement Proposal.
These algorithms provide basic sorting and filtering capabilities based on a single dimension:
- Created_at in descending order - "I want to see the newest events"
- Created_at in ascending order - "I want to see the oldest events"
- Sum(zap amount) in descending order - "I want to see the events earning the most money"
- Sum(reactions) in descending order - "I want to see events with the most reactions"
- Sum(comments) in descending order - "I want to see events with the most comments"
- Sum(followers) in descending order - "I want to see people with the most followers"
- Content_contains("some string") - "I want to see events with this string in this field"
These algorithms provide more complex sorting capabilities, allowing for combinations of the basic algorithms and incorporating a time decay factor:
- Arbitrary combinations of the naive algorithms - e.g., sum(zap amount)+sum(reactions)+sum(comments)
- Any naive algorithm (or combination) with a time decay - e.g., "I want the most zapped events with a bias toward the most recent"
These algorithms introduce personalized weighting based on a user's following graph or the use of a TrustRank like algorithm:
- The advanced algorithms weighted by my following graph
- The advanced algorithms but weighted by a TrustRank-like algorithm
These are algorithms that are commonly found in major social media applications. They aim to deliver the most relevant and important content to the user:
- Algorithmic feed - This aims to distill subjective and recent signal.
- Trending topics/events/stories - This delivers what's happening now that the user might be interested in.
- Who/What to follow - This provides recommendations for things the user might want to see more of.
Several centralized services already provide algorithmic sorting and recommendation capabilities within the Nostr network:
- Nostr.band - Provides trending and discovery features.
- Primal.net - Provides trending and discovery features.
- Zaplife.lol - Provides a unique and somewhat mysterious algorithmic experience.
As Nostr continues to grow and evolve, the implementation of algorithms can greatly enhance the user experience by providing customized, relevant, and engaging content. Even in a Nostr world with topic-based relays, the implementation of basic algorithms can empower users and democratize the content delivery process.
For more details about the Nostr algorithms, please refer to the source here.
Thank you for visiting our project's wiki! We hope you found the information useful. If you have any questions or suggestions, please feel free to open an issue or submit a pull request. We appreciate your contribution and support!