Arxiv onebox plugin

AI 生成的摘要

rhyolight requested a Onebox plugin for Arxiv links to display paper titles, authors, dates, and abstracts, noting that Arxiv does not support OpenGraph or oEmbed. codinghorror suggested checking these protocols first, while rhyolight confirmed Arxiv provides decent JSON via iframely but lacks proper meta tags. After whitelisting the domain, rhyolight reported that Onebox still failed to render, showing only a loading icon briefly. techAPJ clarified that Onebox requires OpenGraph or oEmbed tags to parse data and noted that rhyolight’s Standard plan does not support custom plugins, which are exclusive to the Enterprise plan. riking proposed adding Arxiv support directly to the core Onebox repository, as it is a widely used site. When rriemann asked if Arxiv was approached for meta tag support, rhyolight replied that Arxiv likely lacks the resources to implement such changes. rriemann then suggested using third-party search engines like Google Scholar as an alternative, though rhyolight noted these only provide search results linking back to Arxiv rather than dedicated Onebox-friendly pages.

Anyone know if there is a plugin for Arxiv links? Our community references a lot of scientific papers from this website. Here’s an example link:

The important data for the onebox would be the title, author, submission date, and abstract.

If there is not one yet, I’m thinking about creating one. If anyone else would use it, please :heart:.

4 个赞

Do they support opengraph or oembed? Check that first. Then you could simply whitelist the domain.

It doesn’t seem like it. At least I can’t find any details on their website about support. It looks like onebox plugins are not that difficult to put together. At least this one seems pretty simple:

2 个赞

What does Iframely URL Debugger - Open Graph, Twitter Cards, oEmbed say?

It doesn’t look awful. The JSON looks decent:

{
    "citation_title": "Encoding Data for HTM Systems",
    "citation_author": "Purdy, Scott",
    "citation_date": "2016/02/18",
    "citation_online_date": "2016/02/18",
    "citation_pdf_url": "http://arxiv.org/pdf/1602.05925",
    "citation_arxiv_id": 1602.05925,
    "html-title": "[1602.05925] Encoding Data for HTM Systems",
    "shortcut icon": {
        "href": "http://arxiv.org/favicon.ico",
        "type": "image/x-icon"
    },
    "charset": "UTF-8"
}

Not a good icon, but better than nothing.

1 个赞

I updated my onebox whitelist to include arxiv.org, but they still do not resolve to anything. Just the same URL I pasted.

They are cached very very heavily so be sure to use a new URL that you haven’t used in the last 48 hours.

1 个赞

No dice with a new URL. I see the little loading icon by the URL in the preview for a split second, then just the URL after the icon goes away.

The fact that the loading indicator icon comes up seems to indicate that the whitelist is working, but the onebox is not loading.

Sure @techapj can have a quick look now that we’ve done the basic due diligence.

1 个赞

Hi Matt,

I looks like [1602.05925] Encoding Data for HTM Systems does not have OpenGraph or oEmbed tags with content information. Onebox requires these meta tags to parse the data.

Yes, onebox support can be added via plugin, but since you are on Standard plan you will not be able to install custom plugin on your instance. Only Enterprise plan supports installation of custom plugins.

4 个赞

This means that the best course of action is to make it part of the onebox repo, as arxiv is a sufficiently general website that I think multiple Discourse websites would benefit from having it.

4 个赞

Hey @rhyolight,

have you tried already to convince Arxiv to support opengraph/oembed?

Yes I have, but I doubt they will support it. Arxiv is a very basic website without much funding for website administration or continuing development.

Than maybe a 3rd party website instead that allows to search in arXiv as well?
Something like Google Schoolar?

That’s a good idea. I can find arxiv papers via Google Scholar, but they do not have their own page, just search results. Each result links directly to the arxiv paper.