Classic Note Entries

URI Patterns for Linked Data

Right Hand Patterns

Note that the example URI in the table below are for illustrative purposes. Most of the "Version 1.0" examples do access live linked-data with the particular exception of URI ending in a “#fragment”. At the time of writing all the “ With {/collection}*” examples are illustrative only.


Pattern Example URI
URI Set URI {prefix}/id/{concept}  or 
{prefix}/{concept}#id
Version 1.0 examples
http://education.data.gov.uk/id/school
http://transport.data.gov.uk/id/road
http://transport.data.gov.uk/road#id

With {/collection}*
http://environment.data.gov.uk/bathing-water-quality/id/bathing-water
http://environment.data.gov.uk/catchment-management/id/river-basin-district
http://environment.data.gov.uk/catchment-management/id/waterbody
Identifier URI
(for reference items)
{prefix}/id[/{concept}/{key}]*  or
{prefix}[/{concept}/{key}]*#id
Version 1.0 examples
http://transport.data.gov.uk/id/station/BPW
http://transport.data.gov.uk/station/BPW#id

http://transport.data.gov.uk/road/M5#id
http://transport.data.gov.uk/road/M5/junction/24#id

With {/collection}*
http://environment.data.gov.uk/catchment-management/id/river-basin-district/8
http://environment.data.gov.uk/catchment-management/id/waterbody/GB108050014050
Document URI
(for reference data)
reference data for single reference items:
{prefix}/doc[/{concept}/{key}]*  or 
{prefix}[/{concept}/{key}]*

optionally, reference data for lists of reference items
{prefix}/doc/{concept}/{key}]*/{concept} or 
{prefix}[/{concept}/{key}]*/{concept}
Version 1.0 examples
http://transport.data.gov.uk/doc/station/BPW
http://transport.data.gov.uk/station/BPW

http://transport.data.gov.uk/road/M5
http://transport.data.gov.uk/road/M5/junction/24

With {/collection}*
http://environment.data.gov.uk/catchment-management/doc/river-basin-district/8
http://environment.data.gov.uk/catchment-management/doc/waterbody/GB108050014050
Vocabulary URI
(for vocabularies, ontologies, concept schemes, codelists and schema)
{prefix}/def{/vocabulary*} Version 1.0 examples
http://transport.data.gov.uk/def/traffic
http://environment.data.gov.uk/def/bathing-water
http://transport.data.gov.uk/def/vehicle

With {/collection}*
http://environment.data.gov.uk/bathing-water-quality/def/bathing-water
http://environment.data.gov.uk/bathing-water-quality/def/assessment
http://environment.data.gov.uk/catchment-management/def/waterbody-classification
Vocabulary Term URI
(for term definitions within a vocabularies, ontologies, concept schemes, codelists and schema)
{prefix}/def{/vocabulary*}/{term} Version 1.0 examples
http://transport.data.gov.uk/def/traffic/Road
http://environment.data.gov.uk/def/bathing-water/CoastalBathingWater
http://transport.data.gov.uk/def/vehicle#hgv

With {/collection}*
http://environment.data.gov.uk/bathing-water-quality/def/bathing-water/CoastalBathingWater
http://environment.data.gov.uk/bathing-water-quality/def/assessment/ComplianceAssessment
http://environment.data.gov.uk/catchment-management/def/classification/classifcationYear
Dataset URI
(for datasets)
{prefix}/data{/dataset*} Version 1.0 examples
http://environment.data.gov.uk/data/bathing-water-quality
http://environment.data.gov.uk/data/bathing-water-quality/compliance
http://environment.data.gov.uk/data/waterbody/classification

With {/collection}*
http://environment.data.gov.uk/bathing-water-quality/data/compliance-assessment
http://environment.data.gov.uk/bathing-water-quality/data/sample-assessment
http://environment.data.gov.uk/catchment-management/data/classification-predicted-outcome
http://environment.data.gov.uk/catchment-management/data/classification-objective-outcome
Data Item URI
(for data items within datasets)
{prefix}/data{/dataset*}[/{concept}/{key}]* Version 1.0 examples
http://environment.data.gov.uk/data/bathing-water-quality/compliance/point/03600/year/2012
http://environment.data.gov.uk/data/waterbody/classification/waterbody/GB109055042060/year/2009/item/wbc_55

With {/collection}*
http://environment.data.gov.uk/bathing-water-quality/data/compliance-assessment/point/03600/year/2012
http://environment.data.gov.uk/catchment-management/data/classification/waterbody/GB109055042060/year/2009/item/wbc_55

where

  • {prefix}
    substitutes for the left-hand side patterns presented in the  preceding section.

  • {type}
    is an optional  discriminator  used to discriminate between reference items, reference data and vocabularies that share a common {concept} within a URI set. It may also serves as a weak ‘hint’ (NOTE: It is helpful if the values used in URI path segments can appeal to human intuitions. However, strictly URI are opaque in the sense that humans (and machines) should not expect to make accurate guesses about what a given URI identifies solely from its spelling. It is better to rely on explicit statements in content (whether narrative or in some formalism). Nevertheless, URI that giving correct intuitions to developers and end-users of the data are useful.) of the kind of thing the URI might refer to. Such ‘hint’s can be helpful to human consumers of the URI in terms of appealing to intuitions established by consistent usage. Typical token values used in the  {type}  field are:


**`def`** for vocabularies and terms;
**`id`** for URI sets and reference items;
**`doc`** for reference documents (and documents in general?);
**`data`** for datasets and data items;
**`so`** for spatial objects
  • {concept}
    provides a human readable ‘hint’ indicating some primary concept associated with a vocabulary or a URI set or an indicative name for a dataset or subset eg. school, station, road, local-authority, bathing-water, uksi, traffic-count.

  • {key}
    is a field that discriminates one item from another within a URI set, vocabulary or dataset. Typical  {key}  values are directly derived from a natural key or coded value within the data being published.

  • {/vocabulary*}
    is a short multi-segment (typically single segment) component used to gather term definitions that are organised and managed together as a vocabulary (schema, codelist, concept scheme or ontology). For URI Sets, it is common for the  {/vocabulary*}  component(s) to be aligned with the  {concept}  component(s) in Identifier and Document URI associated with reference items.

  • {concept}/{key}
    repeating field pairs that together identify some entity and related subordinate entities eg. a road junction and exit as subordinates of a road:
    ../road/M5
    ../road/M5/junction/24
    ../road/M5/junction/24/exit-slip/southbound

Source of this document