Relax Target Test for Bibliontology RDF

I am testing the Bibliontology RDF translator for saving metadata in the web to zotero. Sometimes it is not possible to import the metadata because the page/file is not named rdf. It might be that the page is named .xml oder uses some redirection. Nevertheless, it can include rdf and use the bibo vocabulary (which is tested in the detectImport routine).

How about relaxing the target-condition? For example something like this

target = rdf | [^\.]* | *\.[^h].*
(regular expression syntax, need to be transformed to JavaScript)

The expression should include everything which was included yet plus all url without the "." and everything not ending to .htm or html (or exclude a little more as my expression shows) as possible candidates.

[Example 1] http://someURL/isbn97811111111.rdf
[Example 2] http://anotherURL/isbn97822222222
[Example 3] http://someOtherURL/isbn97833333333.xml

What do you think?

Best,
Philipp
  • you're misunderstanding how this work - none of the import translators care about file extensions, but they're never called directly from the browser - only indirectly via a web translator or via "import" from Zotero [1].
    Do you have some specific examples of what you're trying to do?

    [1] Bibtex, RIS, and Refer, which are exclusively used as bibliographic formats can be intercepted by Zotero for Firefox when served with the right mime-type. That wouldn't make sense for such common formats as xml or rdf which are used for many purposes.
  • Here is an example where it does not work:

    http://d-nb.info/1022402080/about/rdf

    If you download the page and save it as .rdf and look at the local copy in firefox, then the Zotero-icon shows up with "Bibliontology RDF".

    Why wouldn't it make sense to allow rdf format in combination with the detectImport routine that checks for a type of bibo?
  • I think the fact that there is a URL bar icon when you open this in Firefox may actually a bug (and if you click it, it throws an error).
    Simon or Dan would have to confirm.
  • We run import translator detection on local files opened in Firefox. This seems to work for me regardless of file extension, although it might be of limited use since we run web detection first and so if there are DOIs we'll show the DOI translator instead.

    That particular file doesn't work, but that's because the Bibliontology RDF translator is throwing an error trying to import it.
  • any particular reason for just running detect import on local files?
  • Thank you for the answers. As far as I understand it you are saying, that the Bibontology RDF translator is an import translator and just happens to work on local files as well. It is not designed for a web translator. Right?
  • edited May 17, 2013
    Okay. I am creating an RDF export function on bibliographic data and I was hoping to do it in such a way that Zotero can also save it easily. This export is in "my sandbox" thus it is not yet live.

    My first idea was to use the Bibliography RDF translator, which is not working, because this is an import translator.

    My second idea was to try to use a XML transformation (xsl), but this seems also not to work.

    Any suggestions? I have rdf+xml of bibliographic data in the web. How can I make it possible for zotero to easily save it?

    Is it also unreasonable to think about a Bibliontology RDF web-translator besides the import-translator?
  • the best way would be to use unAPI which could serve the RDF to Zotero.
    http://unapi.info/
  • Thank you for the information. I will do something in this direction. Thus, the first step is just to provide Zotero-friendly RDF as an rdf-file. Then it will be possible to download it and import it into Zotero standalone. Maybe later on I will consider the link between the presentation page and the rdf page in a way, that Zotero can automatically follow (in the spirit of unapi).
Sign In or Register to comment.