evan,
@evan@cosocial.ca avatar

I'm interested in hearing from developers who've successfully mapped properties from <meta> tags in Web pages onto the Page type and its properties in AS2.

box464,
@box464@mastodon.social avatar

@evan Don’t forget about oEmbed data as well (embedded players for all kinds of things - peertube, funkwhale, etc). It’s currently pulled as part of the link preview generator logic. Many times coming through from the Twitter:player meta tag if no oEmbed exists.

https://box464.com/posts/mastodon-preview-cards/

renchap,
@renchap@oisaur.com avatar

@evan 👀 interested in the replies, as we are thinking about how to federate link previews to avoid having each instance fetch it (and DDOS the link’s server)

evan,
@evan@cosocial.ca avatar

@renchap I'll definitely write up a proposal for it.

benpate,
@benpate@mastodon.social avatar

@evan Here’s my take, hope it helps?

https://github.com/benpate/sherlock

Sherlock is a library that assembles any data/metadata it can find on a URL (including , , , and ) and returns an back to its caller. There’s composable add-ons for caching and other custom rules.

Overall, mapping to ActivityStreams was pretty easy. Sherlock is the key component in that helps it participate in many different social webs.

evan,
@evan@cosocial.ca avatar

@benpate nice!

smallcircles,
@smallcircles@social.coop avatar

@evan @benpate @trwnh

There's a on this topic that you might add comments / new insights to:

https://codeberg.org/fediverse/fediverse-ideas/issues/26

trwnh,
@trwnh@mastodon.social avatar

@evan hot take, why not just use the opengraph namespace/iris directly?

if the goal is to reduce duplication of data, i'd probably recommend the following

  • og:title = as:name
  • og:type = og:type (no way to map this one)
  • og:url = as:url
  • og:image = as:image

for optional ones:

  • og:description = as:summary

all the other ones i'd just use ogp.me iris directly

evan,
@evan@cosocial.ca avatar

@trwnh that's about what I'd expect as a mapping. Have you seen it used to create Page objects, for link previews?

trwnh,
@trwnh@mastodon.social avatar

@evan i have only ever seen link previews implemented out-of-band due to trust issues :/

evan,
@evan@cosocial.ca avatar

@trwnh you mean, on the receiving servers?

trwnh,
@trwnh@mastodon.social avatar

@evan yes, and it creates a sort of "thundering herd" unintentional ddos for web sites on underpowered providers. there have been ideas on how to solve the trust issue, like randomly verifying some small subset and tracking reputation, or like deferring to a semi-centralized pre-trusted "link preview provider" that is shared between several instances, or even simply ignoring the issue and depending on people to report misleading links. (i prefer the provider approach)

evan,
@evan@cosocial.ca avatar

@trwnh another option is accepting the sender-provided metadata to start, and then verifying on a schedule that recognizes that thundering herd problem -- say, a randomized delay between 1 and 300 seconds, with an exponential backoff. And I definitely think having a trusted shared caching server can help immensely.

thisismissem,
@thisismissem@hachyderm.io avatar

@evan @trwnh I'm in favour of third-party providers that give a standardised API for going from link URL to Page or similar representation & provides hashes of the returned object allowing easy verification with the provider

evan,
@evan@cosocial.ca avatar

@thisismissem @trwnh doesn't have to be either-or. Can be also-and. Use sender-provided metadata, and possibly re-verify with a trusted API.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • fediverse
  • Durango
  • DreamBathrooms
  • thenastyranch
  • magazineikmin
  • khanakhh
  • InstantRegret
  • Youngstown
  • ngwrru68w68
  • slotface
  • rosin
  • tacticalgear
  • mdbf
  • kavyap
  • modclub
  • JUstTest
  • osvaldo12
  • ethstaker
  • cubers
  • normalnudes
  • everett
  • tester
  • GTA5RPClips
  • Leos
  • cisconetworking
  • provamag3
  • anitta
  • megavids
  • lostlight
  • All magazines