enhanced content models - connecting repositories · enhanced content models state and university...
TRANSCRIPT
![Page 1: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/1.jpg)
Enhanced Content Models
State and University Library, Denmark
Open Repositories 2010Duraspace user group
Asger Askov BlekingeKåre Fiedler Christiansen
![Page 2: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/2.jpg)
Program● Introduction
– Fedora Objects and Content Models
● Enhanced Content Models– Optional Datastreams
– Datastream Schemas
– Extensibility
![Page 3: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/3.jpg)
Program– Object Ontology
– Datastream Ontology
● Content Model Driven Software– Validator
![Page 4: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/4.jpg)
A look at Fedora Objects
● Interrelated objects● Datastreams in objects● Content Models
![Page 5: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/5.jpg)
PreECM Content Models
● Content Models declare the classes of data objects
● Content Models declare the existince of datastreams in data objects
![Page 6: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/6.jpg)
PreECM Content Models
● Content Models associate disseminators with data objects
● This is sufficient for many usecases!
![Page 7: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/7.jpg)
Enhanced Content Models
● Extra information in Content Models. Backwards compatible.
● Optional datastreams● ECMs declare the schemas for xml
datastreams
![Page 8: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/8.jpg)
Enhanced Content Models
● ECMs declare cardinality and range for object relations
● ECMs declare cardinality and range for datastream relations
![Page 9: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/9.jpg)
Optional Datastreams
<dsCompositeModel> <dsTypeModel ID="RELS-INT" optional="true"/></dsCompositeModel>
Optional datastreams will be validated if present, but it is not an error to leave them out.
![Page 10: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/10.jpg)
Fedora Object reserved datastreams
● DC (magic, required)● RELS-EXT (optional)● RELS-INT (optional)● POLICY (optional)● AUDIT (magic, optional)
![Page 11: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/11.jpg)
Content Model datastreams
● RELS-EXT (required)● DS-COMPOSITE-MODEL (optional)● ONTOLOGY (new, optional)
– More on this one later
![Page 12: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/12.jpg)
Description Languages - Datastreams
● XMLSchema:– There are schemas for most xml metadata
formats
– XMLSchema is reversible.
– Excellent tool support
– Fedora is based on XML anyhow
![Page 13: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/13.jpg)
Description Languages - Datastreams
<dsCompositeModel> <dsTypeModel ID="DC"> <form MIME="text/xml"/> </dsTypeModel></dsCompositeModel>
![Page 14: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/14.jpg)
Description Languages - Datastreams
<dsCompositeModel> <dsTypeModel ID="DC"> <form MIME="text/xml"/>
</dsTypeModel></dsCompositeModel>
![Page 15: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/15.jpg)
Description Languages - Datastreams
<dsCompositeModel> <dsTypeModel ID="DC"> <form MIME="text/xml"/> <extension name="SCHEMA">
</extension> </dsTypeModel></dsCompositeModel>
![Page 16: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/16.jpg)
Description Languages - Datastreams
<dsCompositeModel> <dsTypeModel ID="DC"> <form MIME="text/xml"/> <extension name="SCHEMA"> <reference type=”xsd” datastream=”OAI_DC-SCHEMA”/> </extension> </dsTypeModel></dsCompositeModel>
![Page 17: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/17.jpg)
Description Languages - Datastreams
<foxml:datastream ID="OAI_DC-SCHEMA" CONTROL_GROUP="E" STATE="A" VERSIONABLE="false">
![Page 18: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/18.jpg)
Description Languages - Datastreams
<foxml:datastreamVersion ID="OAI_DC-SCHEMA1.0" LABEL="OAI DC xml schema" MIMETYPE="text/xml"> <foxml:contentLocation TYPE="URL" REF="http://www.openarchives.org/OAI/2.0/oai_dc.xsd"/> </foxml:datastreamVersion>
</foxml:datastream>
![Page 19: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/19.jpg)
Extensibility
<dsCompositeModel> <dsTypeModel ID="DC"> <form MIME="text/xml"/> <extensions name="MY_EXTENSION"> <demoXml> <withStuff/> </demoXml> </extensions> </dsTypeModel></dsCompositeModel>
![Page 20: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/20.jpg)
Description Languages - RDF
● OWL Lite:– Fedora use RDF.
– Restrictions on RDF should be in OWL.
– Lite means that we can still reason about it
![Page 21: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/21.jpg)
Ontology datastream
<rdf:RDF> <owl:Class rdf:about="info:fedora/fedora-system:FedoraObject-3.0_class"/></rdf:RDF>
![Page 22: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/22.jpg)
Ontology datastream
<rdf:RDF> <owl:Class rdf:about="info:fedora/fedora-system:FedoraObject-3.0_class"> </owl:Class></rdf:RDF>
![Page 23: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/23.jpg)
Ontology datastream
<rdf:RDF> <owl:Class rdf:about="info:fedora/fedora-system:FedoraObject-3.0_class"> <rdfs:subClassOf> <owl:Restriction> <owl:onProperty rdf:resource="info:fedora/fedora-system:def/model#hasModel"/> <owl:allValuesFrom rdf:resource="info:fedora/fedora-system:ContentModel-3.0_class"/> </owl:Restriction> </rdfs:subClassOf> </owl:Class></rdf:RDF>
![Page 24: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/24.jpg)
Ontology datastream
<rdf:RDF> <owl:Class rdf:about="info:fedora/fedora-system:FedoraObject-3.0_class"> <rdfs:subClassOf> <owl:Restriction> <owl:onProperty rdf:resource="info:fedora/fedora-system:def/model#hasModel"/> <owl:allValuesFrom rdf:resource="info:fedora/fedora-system:ContentModel-3.0_class"/> </owl:Restriction> </rdfs:subClassOf> </owl:Class> <owl:ObjectProperty rdf:about="info:fedora/fedora-system:def/model#hasModel"/></rdf:RDF>
![Page 25: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/25.jpg)
Ontology datastream
<rdf:RDF> <owl:Class rdf:about="info:fedora/fedora-system:FedoraObject-3.0_class"> <rdfs:subClassOf> <owl:Restriction> <owl:onProperty rdf:resource="info:fedora/fedora-system:def/model#hasModel"/> <owl:allValuesFrom rdf:resource="info:fedora/fedora-system:ContentModel-3.0_class"/> </owl:Restriction> </rdfs:subClassOf> </owl:Class> <owl:ObjectProperty rdf:about="info:fedora/fedora-system:def/model#hasModel"/></rdf:RDF>
![Page 26: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/26.jpg)
Ontology datastream
<rdf:RDF> <owl:Class rdf:about="info:fedora/fedora-system:FedoraObject-3.0_class"> <rdfs:subClassOf> <owl:Restriction> <owl:onProperty rdf:resource="info:fedora/fedora-system:def/model#hasModel"/> <owl:allValuesFrom rdf:resource="info:fedora/fedora-system:ContentModel-3.0_class"/> </owl:Restriction> </rdfs:subClassOf> </owl:Class> <owl:ObjectProperty rdf:about="info:fedora/fedora-system:def/model#hasModel"/></rdf:RDF>
![Page 27: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/27.jpg)
Ontology datastream
<rdf:RDF> <owl:Class rdf:about="info:fedora/fedora-system:FedoraObject-3.0_class"> <rdfs:subClassOf> <owl:Restriction> ..... </owl:Restriction> </rdfs:subClassOf> <rdfs:subClassOf> <owl:Restriction> <owl:onProperty rdf:resource="info:fedora/fedora-system:def/model#hasModel"/> <owl:minCardinality>1</owl:minCardinality> </owl:Restriction> </rdfs:subClassOf> </owl:Class> <owl:ObjectProperty rdf:about="info:fedora/fedora-system:def/model#hasModel"/></rdf:RDF>
![Page 28: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/28.jpg)
Ontology datastream
There are 5 kinds of Restrictions supported at the moment● MinCardinality● MaxCardinality● Cardinality
![Page 29: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/29.jpg)
Ontology datastream
● AllValuesFrom● SomeValuesFrom
The ontology is Open, ie. Dataobjects can have more relations than the ones declared in the content model
![Page 30: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/30.jpg)
Datastream Relations
● Datastream relations declared in RELS-INT● Always have the datastream as the subject● The ontology is part of the ONTOLOGY
datastream, just like the ontology for the RELS-EXT relations.
![Page 31: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/31.jpg)
ONTOLOGY Datastream
<rdf:RDF> <owl:Class rdf:about="info:fedora/fedora-system:FedoraObject-3.0_class"> ..... </owl:Class> <owl:Class rdf:about="info:fedora/fedora-system:FedoraObject-3.0/DC_class"/></rdf:RDF>
![Page 32: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/32.jpg)
Rounding up
● Optional datastreams● Datastream xsd schemas● Object Relations ontology● Datastream Relations ontology● Extensibility● The 4 basic content models have been
enhanced
![Page 33: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/33.jpg)
Why enhancing the content models
● Precise descriptions of the data objects allow software to reflect upon this ie. Content Model Driven Software
● Encoding of the data model in the content models, not in the surrounding software
![Page 34: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/34.jpg)
Why enhancing the content models
● Enhanced Content Models are now “complete”● We would like to know about how they are
used, and their shortcomings● What is needed is a Best Practise for content
models
![Page 35: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/35.jpg)
Validate method
● A precise description is much more useful, if you can ensure that the object adheres to the description
● Will validate against each of the content models in turn
● validate(pid, asOfDateTime)● Do not use the Resource Index
![Page 36: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/36.jpg)
Validate Result
● Object PID● Valid boolean● AsOfDateTime● Content Models
![Page 37: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/37.jpg)
Validate Result
● Object Problems– List of problems concerning RELS-EXT
● Datastream Problems– List of problems for each datastream
![Page 38: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/38.jpg)
Validate Result<validation pid="demo:testObject" valid="false"> <asOfDateTime>2007-10-26T08:36:28</asOfDateTime> <contentModels> <model>info:fedora/demo:ContentModelTest</model> <model>info:fedora/fedora-system:FedoraObject-3.0</model> </contentModels>
![Page 39: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/39.jpg)
Validate Result <problems> <problem>Relation 'http://demoRelations/next' refers to resource 'demo:dataObject2' which, by content model 'demo:ContentModelTest' should be of the type 'demo:ContentModelTest' </problem> </problems>
![Page 40: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/40.jpg)
Validate Result <datastreamProblems> <datastream datastreamID="DC"> <problem>Datastream 'DC' is required by the content model 'fedora-system:FedoraObject-3.0' </problem> </datastream> </datastreamProblems></validation>
![Page 41: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/41.jpg)
Validate Result
● Stuff still to do– Errorcodes or something like this for machine
parsable error handling. We need feedback
– 3.4 RC 1 validator does not do RELS-INT validation. This will be fixed in 3.4 Final
![Page 42: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/42.jpg)
Building a better CMA
● Basic CMA was the first step● These enhancements are the second step.● We do not know how many steps are needed● For software to be content model driven, we
need a general language for content models, a Best Practise.
● Give us feedback on how you use them, and especially how they are insufficient.
![Page 43: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/43.jpg)
Rounding up
● Websites– https://wiki.duraspace.org/display/FCREPO/Enh
anced+Content+Models
– http://tinyurl.com/2d537ka
– Will be moved to the proper location in the Fedora wiki, but this location will forward
– Email: [email protected]
![Page 44: Enhanced Content Models - COnnecting REpositories · Enhanced Content Models State and University Library, Denmark Open Repositories 2010 ... Content Models declare the classes of](https://reader034.vdocuments.mx/reader034/viewer/2022042109/5e88f978a3623c25284ecfa6/html5/thumbnails/44.jpg)
Rounding up
● This work has been funded by– DEFF, Denmark's Electronic Research Library
– State and University Library, Denmark