Giter Club home page Giter Club logo

pcdcmlite's Introduction

pcdcm-lite

Portland Common Data Model Lite - very very simple repository-agnostic class compatible with the PCDM.

Should work with either Python2 or 3, but go for 3 if you can.

This is designed to work with repository specific code, such as this test code for creating PCDM-compatible collections and objects in Fedora 4.

Status

This is pre-alpha, under-documented, experimental code. It may work for you and we're happy to help out if you are interested in getting it running but it is not production quality, yet. Raise an issue here if you have a question.

This is also embarassingly simple.

Install

  1. Get yourself into a Python Virtual environment for your project. TODO - how (Really, you are going to be messing with non-production code here)
  2. Check out this repository, eg by: git clone https://github.com/ptsefton/pcdcmlite
  3. Install it (in your Virtual Environment!):
     python setup.py install```
    
    

There are some rudimentary tests.

There are two classes: pcdmlite: this is a essentially just a simple data structure (even simpler than PCDM)

Load repository data via a CSV file

Quick notes for CSV format.

  • Use commas as separators
  • Put one item or collection per row.
  • Use these columns:
Column Header Description
dc:identifier : Required, an ID unique to (at least) your data. TODO: code should assign an ID to the whole spreadsheet to create a unique namespace for these IDs
dc:type What kind of resource this is. You could use a string or a URI. If this row describes a collection put pdcdm:Collection
pdcm:Collection Optional, the ID collection that contains this object or collection, this should appear in the dcterms:identifier column elsewhere in the data file
dc:meta Any other Dublin Core Metatada
FILE: Path for a file to upload
REL:predicate Create an RDF relationship between this item or collection (the subject) and another using (prediate could be a dublin core element like dc:subject, or a full URI), the row would contain the ID or URI of the object.

To make relationships between existing items using a separate sheet you can use:

Column Header Description
subject Subject ID (matches a dcterms:identifier)
predicate An RDF predicate - either a URI or something with dc: frbr: or foaf: namespace (for now)
object Object ID (matching a dcterms:identifier)

pcdcmlite's People

Contributors

ptsefton avatar

Stargazers

Ross Spencer avatar

Watchers

 avatar Ross Spencer avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.