InvasionBiologyHypotheses / enKORE-corpus-processor

enKORE corpus processor to produce records for use in OAI-PMH endpoint
GNU General Public License v3.0
0 stars 1 forks source link

Add experimental custom tags to description field to test transmission through BASE #15

Open bootsa opened 2 years ago

bootsa commented 2 years ago

Add experimental custom tags to description field to test transmission through BASE.

Use namespaced identifiers and an outer "test" wrapper to be able to ignore test usage in the future.

<enkore:test label="test item">
  <enkore:geographic>
    <enkore:continent>Europe</enkore:continent>
    <enkore:continent>Oceania</enkore:continent>
    <enkore:geolocation>56.23324,12.12654</enkore:geolocation>
  </enkore:geographic>
  <enkore:subject>
    <enkore:taxa>
       <enkore:species>European Song Thrush</enkore:species>
    </enkore:taxa>
  </enkore:subject>
  <enkore:hypothesis id="inas:r12345">
    <enkore:supports>true</enkore:supports>
  </enkore:hypothesis>
  <enkore:hypothesis id="inas:r9876">
    <enkore:supports>partial</enkore:supports>
  </enkore:hypothesis>
</enkore:test>
bootsa commented 2 years ago

Could use prefixes for identifiers:

<enkore:test label="test item">
  <enkore:prefix id="wdt" uri="http://www.wikidata.org/prop/direct/" />
  <enkore:prefix id="wd" uri="http://www.wikidata.org/entity/" />
  <enkore:geographic>
    <enkore:continent type="wdt:P30" id="wd:Q46">Europe</enkore:continent>
    <enkore:continent id="wd:Q55643">Oceania</enkore:continent>
    <enkore:geolocation>56.23324,12.12654</enkore:geolocation>
  </enkore:geographic>
  ...
</enkore:test>

RDF associations could be inferred from the tag name (e.g. enkore:continent could be mapped to http://www.wikidata.org/prop/direct/P30 or even multiple entities from different ontologies according to the live enkore ontology) - using a type attribute could define an alternate / specific association.

    <enkore:continent type="wdt:P30">Europe</enkore:continent>
    <enkore:continent>Oceania</enkore:continent>

Similarly the tags enclosed content would normally be the main identifier of the entry. An id attribute would allow more specific definition with the tags content becoming an easy to read alternative / label. Thus the tag would need content, an id attribute or both.

    <enkore:continent>Europe</enkore:continent>
    <enkore:continent id="wd:Q55643">Oceania</enkore:continent>
bootsa commented 2 years ago

Prefixes could possibly be use more directly as part of the main namespaced tags:

<enkore:test label="test item">
  <enkore:prefix id="wdt" uri="http://www.wikidata.org/prop/direct/" />
  <enkore:prefix id="wd" uri="http://www.wikidata.org/entity/" />
  <enkore:geographic>
    <wdt:P30 id="wd:Q46">Europe</wdt:P30>
    <wdt:P30 id="wd:Q55643">Oceania</wdt:P30>
    <wdt:P625>56.23324,12.12654</wdt:P625>
  </enkore:geographic>
  ...
</enkore:test>
Daniel-Mietchen commented 2 years ago

Prefixes could possibly be use more directly as part of the main namespaced tags:

This would be my favourite amongst these options — if we can get it to work.