fbpx
Wikipedia

TriG (syntax)

TriG is a serialization format for RDF (Resource Description Framework) graphs. It is a plain text format for serializing named graphs and RDF Datasets which offers a compact and readable alternative to the XML-based TriX syntax.

TriG
Filename extension
.trig
Internet media type
application/trig
Developed byFreie Universität Berlin
Type of formatsemantic web
Container forRDF data
Extended fromTurtle
StandardW3C Recommendation

Example edit

This example encodes three interlinked named graphs:

  • http://www.example.org/exampleDocument#G1
  • http://www.example.org/exampleDocument#G2
  • http://www.example.org/exampleDocument#G3
 @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . @prefix swp: <http://www.w3.org/2004/03/trix/swp-1/> . @prefix dc: <http://purl.org/dc/elements/1.1/> . @prefix ex: <http://www.example.org/vocabulary#> . @prefix : <http://www.example.org/exampleDocument#> . :G1 { :Monica ex:name "Monica Murphy" . :Monica ex:homepage <http://www.monicamurphy.org> . :Monica ex:email <mailto:monica@monicamurphy.org> . :Monica ex:hasSkill ex:Management } :G2 { :Monica rdf:type ex:Person . :Monica ex:hasSkill ex:Programming } :G3 { :G1 swp:assertedBy _:w1 . _:w1 swp:authority :Chris . _:w1 dc:date "2003-10-02"^^xsd:date . :G2 swp:quotedBy _:w2 . :G3 swp:assertedBy _:w2 . _:w2 dc:date "2003-09-03"^^xsd:date . _:w2 swp:authority :Chris . :Chris rdf:type ex:Person . :Chris ex:email <mailto:chris@bizer.de> } 

External links edit

  • RDF 1.1 TriG W3C Recommendation (2014)
  • Yacker TriG validator, which does not handle sub-graphs, and does not validate the above example.


trig, syntax, trig, serialization, format, resource, description, framework, graphs, plain, text, format, serializing, named, graphs, datasets, which, offers, compact, readable, alternative, based, trix, syntax, trigfilename, extension, triginternet, media, ty. TriG is a serialization format for RDF Resource Description Framework graphs It is a plain text format for serializing named graphs and RDF Datasets which offers a compact and readable alternative to the XML based TriX syntax TriGFilename extension trigInternet media typeapplication trigDeveloped byFreie Universitat BerlinType of formatsemantic webContainer forRDF dataExtended fromTurtleStandardW3C RecommendationExample editThis example encodes three interlinked named graphs http www example org exampleDocument G1 http www example org exampleDocument G2 http www example org exampleDocument G3 prefix rdf lt http www w3 org 1999 02 22 rdf syntax ns gt prefix xsd lt http www w3 org 2001 XMLSchema gt prefix swp lt http www w3 org 2004 03 trix swp 1 gt prefix dc lt http purl org dc elements 1 1 gt prefix ex lt http www example org vocabulary gt prefix lt http www example org exampleDocument gt G1 Monica ex name Monica Murphy Monica ex homepage lt http www monicamurphy org gt Monica ex email lt mailto monica monicamurphy org gt Monica ex hasSkill ex Management G2 Monica rdf type ex Person Monica ex hasSkill ex Programming G3 G1 swp assertedBy w1 w1 swp authority Chris w1 dc date 2003 10 02 xsd date G2 swp quotedBy w2 G3 swp assertedBy w2 w2 dc date 2003 09 03 xsd date w2 swp authority Chris Chris rdf type ex Person Chris ex email lt mailto chris bizer de gt External links editTriG Specification 2007 RDF 1 1 TriG W3C Recommendation 2014 Yacker TriG validator which does not handle sub graphs and does not validate the above example nbsp This World Wide Web related article is a stub You can help Wikipedia by expanding it vte Retrieved from https en wikipedia org w index php title TriG syntax amp oldid 958070478, wikipedia, wiki, book, books, library,

article

, read, download, free, free download, mp3, video, mp4, 3gp, jpg, jpeg, gif, png, picture, music, song, movie, book, game, games.