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

Follow permission and social links during discovery #702

Open
tegefaulkes opened this issue Apr 19, 2024 · 2 comments
Open

Follow permission and social links during discovery #702

tegefaulkes opened this issue Apr 19, 2024 · 2 comments
Assignees
Labels
development Standard development r&d:polykey:core activity 3 Peer to Peer Federated Hierarchy

Comments

@tegefaulkes
Copy link
Contributor

tegefaulkes commented Apr 19, 2024

Specification

(copied from #692 (comment))

Here is a general diagram of what a social network would look like.

Untitled-2024-01-23-1145 excalidraw

This is the kind of network we need to preform discovery on. The network is esentially made up of a graph, containing verticies made up of identities and polykey nodes, and edges forming links between them.

There are 3 tiers of edges.

  1. Cryptolinks, These are the most concrete form of a link. You can think of a gestalt as a fully formed distinct sub-graph made up of JUST cryptolinks. Cryptolinks are depicted as black arrow edges above. The circles grouping them are the gestalts.
  2. Trust and permission links, depicted as the blue arrows above. These are the main relationships between nodes. There are gestalt level permissions such as trusting that gestalt. And node-node level permissions such as sharing a vault. These edges form a relationship between gestalts such that we want to know more about them since we're directly interacting with them.
  3. There are weak relationships between identities. Depending on the kind of identity they could be friends, followers, part of the same group, whatever. It just implies a social relation between two identities. These exist outside of the Polykey ecosystem and don't really affect the interaction within Polykey. But it's useful to know about for inviting friends into the polykey ecosystem, for finding friends already using polykey.

Currently Polykey discovery only operates on the first tier of edges. So only whole gestalts are discovered and the user needs to manually trigger discovery on each gestalt to discover them.

To address task 4 in the above issue description, Quality of life and streamline features such as automatic friend discovery for identities we need to make some upgrades to the discovery system. We need the ability to do the following

  1. Follow permission links between gestalts to discover them in the background. We only really need to follow our own permissions.
  2. Allow the ability to trust or set permissions between gestalts or nodes without having to discover them first.
  3. Trusting or sharing should trigger background discovery.
  4. Starting up Polykey should trigger initial discovery on our own node moving outwards.
  5. We should check social level (tier 3) edges to enable the following.
    1. Compile a list of friends/followers to invite to use Polykey.
    2. Find friend/followers that already use Polykey.
  6. We'd need to have a priority system for processing tier 2-3 edges. Social edges alone could crowd out all other forms of discovery and grind useful discovery to a halt.

The first 2 tiers of links can be fully explored. But to limit the exploration space during discovery we only want to explore first order social links. That is, only the people we follow and their tier 1 links. That makes the full exploration space to be our gestalt, gestalts of anyone with permissions and the full gestalts of people we follow.

Additional context

Related: #692 (comment)

Tasks

  1. Identities have an optional implementation for listing all friends or social links. THis would be an generator that yields each link with associated metadata such as PK claims, usernames, possible emails etc etc.
  2. Need an generator for listing out all trust links and an generator for all permission links
  3. Implement the ability to trust and share without discovering a node or identity first.
  4. Discovery should be seeded by known claims, social links, trust and permissions. It should be seeded when an agent starts.
  5. We need to categorise each type of link into a priority level and preferentially process them. The tasks domain allows priority but this is a global level.
@tegefaulkes tegefaulkes added the development Standard development label Apr 19, 2024
Copy link

linear bot commented Apr 19, 2024

@CMCDragonkai
Copy link
Member

#736 although is closed, I don't think our focus has entirely shifted from this. This is still a necessary, but I'll expand more on this on review of R&D 2023 - 2024.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
development Standard development r&d:polykey:core activity 3 Peer to Peer Federated Hierarchy
Development

No branches or pull requests

2 participants