Skip to content

Instantly share code, notes, and snippets.

@tommorris
Last active June 16, 2022 09:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tommorris/7d39b2b2ec5346e4a3069026cc18ccc0 to your computer and use it in GitHub Desktop.
Save tommorris/7d39b2b2ec5346e4a3069026cc18ccc0 to your computer and use it in GitHub Desktop.
<i id="latin-text-1" lang="la" typeof="schema:CreativeWork" about="#latin-text-1" property="schema:text">veni vidi vici</i>
(<span typeof="schema:CreativeWork">
<data property="schema:translationOfWork" resource="#latin-text-1" />
<span property="schema:text" lang="en">I came, I saw, I conquered</span>
</span>)
@tommorris
Copy link
Author

tommorris commented Jun 16, 2022

This is a response to edent's tweet

The N3 output.

@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix schema: <http://schema.org/> .
@prefix xml: <http://www.w3.org/XML/1998/namespace> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .

<#latin-text-1> a schema:CreativeWork ;
    schema:text """veni vidi vici"""@la .

[] a schema:CreativeWork ;
    schema:text """I came, I saw, I conquered"""@en ;
    schema:translationOfWork <#latin-text-1> .

RDF/XML output (with a node ID added by the parser).

<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF
   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
   xmlns:schema="http://schema.org/"
>
  <rdf:Description rdf:nodeID="Na8c02f42a7d448c88655ad51adfab5bc">
    <schema:translationOfWork rdf:resource="#latin-text-1"/>
    <schema:text xml:lang="en">I came, I saw, I conquered</schema:text>
    <rdf:type rdf:resource="http://schema.org/CreativeWork"/>
  </rdf:Description>
  <rdf:Description rdf:about="#latin-text-1">
    <rdf:type rdf:resource="http://schema.org/CreativeWork"/>
    <schema:text xml:lang="la">veni vidi vici</schema:text>
  </rdf:Description>
</rdf:RDF>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment