Metadata about IPLD links, particularly link importance

IPLD is fantastic for linking stored objects together, but it seems like there’s no way to assign metadata to those links that might be useful at the protocol level.

I’m thinking particularly of social network “feed” situation; I’d model a “profile” object, which would reference the hash of the head of my linked list of posts, and I’d also link to the other accounts I follow. Using CIDs for these links makes sense; I’m referring to other hashes in IPFS.

However, if I recursive pin such a profile, I’m going to retrieve the entire social network (or at least, the entire network of profiles connected to my own).

What would be convenient here would be to be able to use:

  • stanard IPLD links; CIDs that point to something that should be (recursive) retrieved with the current node
  • archival IPLD links; CIDs that should be retrieved with a lower priority, and only when archival retrival is what’s intended.

The same kind of approach would be very valuable for, say, Wikipedia articles (if modelled with IPLD, instead of just with HTML). I could specify to retrieve a given article, and up to depth=2 of archival links, knowing I’ll definitely get whole articles, and get relevant linked articles too.

This might be achievable by extending the DAG-CBOR spec to allow an additional Type 6 tag, say 170 (0xaa), so that:

  • Tag 42 means a CID link (which is what’s used today)
  • Tag 170 means an “archival CID link”, which would (initially) be ignored by old clients.

Is this something our community would find useful?