Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Schema revision v2 for BCDC project inventory #35

Draft
wants to merge 7 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
319 changes: 319 additions & 0 deletions design/schema/bcdc.puml
Original file line number Diff line number Diff line change
@@ -0,0 +1,319 @@
@startuml

hide empty members
'hide circle


'Enums
enum WebResourceType {
Download
Information
Explore
View
}

enum AccessControl {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the omics data management meeting last week, scientists asked to have the listing of the conditions for accessing controlled access data available before they go to NDA. We don't have a field for this yet, would be good to add. There are codes for this, but also need free text fields to describe, such as "For the study of the Brain in Health and Disease" which is the requirement for data from one of our tissue providers.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added an 'accessControlCode' class linked to data collections, and a free text field 'accessControlDescription' to data collection.

Open
Embargoed
Controlled
}

enum CompletionState {
Complete
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are additional states for triple store ingest and validation, do we want yto incorporate them here as well?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Triple store ingest/validation states apply to individual uploads, and we can have multiple uploads per data collection/multiple data collections per upload. We do have an association table for uploads/data collections, but that is outside of this schema.

InProgress
}

enum AgentType {
Person
Organization
}


'Entity-like
class Agent {
* id: String!
agent_id: String!
agentType: AgentType
organization: Organization
person: Person
type: AgentType!
}

class Modality {
* id: String!
name: String!
handle: String
}

class SpecimenType {
* id: String!
name: String!
handle: String
}


class WebResource {
* id: String!
handle: String!
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what is handle? This doesn't seem like a typical field name. Should be webresource "name" maybe?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed handle to name

title: String!
shortTitle: String!
url: String!
rrid: String
}

class Project {
* id: String!
doi: String
handle: String!
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

change handle to name?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed handle to name

title: String!
shortTitle: String!
description: String!
bkpWebResource: WebResource!
informationWebResource: WebResource
subprogram: [Subprogram]!
technique: [Technique]!
collection: [Collection]!
specimenType: [SpecimenType]!
contact: Contact
creator: [Agent]!
fundingSource: [Award]!
contributor: [Agent]
highlightedWebResource: [WebResource]
protocol: [Protocol]
dataArchive: [Organization]
externalId: String
species: [Species]!
modality: [Modality]!
publication: [Publication]
dateModified: Date
dateCreated: Date!
}

class Collection {
* id: String!
handle: String!
title: String!
shortTitle: String!
description: String!
doi: String
rrid: String
citation: String
externalId: String
dataArchive: Organization
bkpWebResource: [WebResource]!
dataArchive: [Organization]!

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

repetition, see l.102

species: [Species]!
specimenCount: [SpecimenCount]!
license: License!
accessControl: AccessControl!
completionState: CompletionState!
modality: [Modality]!
technique: [Technique]!
webResource: [WebResource]
dateModified: Date
dateCreated: Date!
}

class Subprogram {
* id: String!
doi: String
handle: String!
title: String!
shortTitle: String!
description: String!
bkpWebResource: WebResource
program: Program!
informationWebResource: WebResource
}

class Program {
* id: String!
doi: String
handle: String!
title: String!
shortTitle: String!
description: String!
bkpWebResource: WebResource
informationWebResource: WebResource
}

class Protocol {
* id: String!
handle: String
title: String!
shortTitle: String!
webResource: WebResource!
}

class Person {
* id: String!
name: String!
givenName: String!
familyName: String!
handle: String
orcid: String
}

class Organization {
* id: String
name: String!
handle: String!
ror: String
webResource: WebResource
contact: Contact
}

class License {
* id: String!
handle: String
name: String!
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what is the name vs the handle here?

title: String!
shortTitle: String!
webResource: WebResource!
}

class Award {
* id: String
name: String!
title: String!
identifier: String!
reportSymbol: String
funder: Agent!
awardee: [Agent]!
}

class Technique {
* id: String!
handle: String
name: String!
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

would like to begin adding on a field to link to ontology

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added ontology id field to technique, modality and specimenType

}

class Species {
* id: String!
name: String!
common_name: String!
scientific_name: String
ncbi_taxonomy_id: String!
rrid: String
}

class SpecimenCount {
* id: String!
count: Int
specimenType: SpecimenType!
}

class Contact {
* id: String!
name: String!
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how does this interact with person?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was polymorphic, with contact being either an organization or person. Updated to be a direct link to Person, with a circle for contact for readability.

email: String
}

class Publication {
* id: String!
TBD
}

circle webResource
webResource --> WebResource

circle bkpWebResource
bkpWebResource --> WebResource

circle informationWebResource
informationWebResource --> WebResource

circle highlightedWebResource
highlightedWebResource --> WebResource

circle contact
contact --> Contact

circle dataArchive
dataArchive --> Organization

circle specimenType
specimenType --> SpecimenType

circle species
species --> Species

circle technique
technique --> Technique

circle modality
modality --> Modality

'Organization --o| Contact : contact
Organization --o| contact
Organization --o| webResource

'Relationships
Agent --o| Person : person
Agent --o| Organization : organization
Agent --|| AgentType : type

'SpecimenCount --|| SpecimenType : specimenType
SpecimenCount --|| specimenType

WebResource --|| WebResourceType : type

'Technique --o{ Protocol : protocol

Collection --|{ modality
Collection --|{ species
Collection --|{ SpecimenCount : specimenCount
Collection --|{ technique
Collection --|| AccessControl : accessControl
Collection --|| CompletionState : completionState
Collection --|| License : license
Collection --|{ bkpWebResource
'Collection --|{ Organization : dataArchive
Collection --|{ dataArchive
Collection --o{ webResource

Award --|| Agent : funder
Award --|{ Agent : awardee

Contact --o| Agent: agent

Project --|{ Collection : collection
Project --|{ Award : fundingSource
'Project --o{ WebResource : highlightedWebResource
Project ---o{ highlightedWebResource
Project --|{ Agent : creator
Project --o{ Agent : contributor
'Project --o{ Contact : contact
Project --o{ contact
'Project --|{ SpecimenType : specimenType
Project --|{ specimenType
Project --|{ technique
Project --|{ Subprogram : subprogram
'Project --o| webResource
Project --|| bkpWebResource
Project --o| informationWebResource
'Project --|| webResource : bkpWebResource
'Project --|> Program
Project --o{ Protocol : protocol
Project --|{ dataArchive
Project --|{ species
Project --|{ modality
Project --o{ Publication : publication

Program --o| informationWebResource
Program --o| bkpWebResource
'Program --o| webResource : bkpWebResource
'Program --|| webResource : informationWebResource

Subprogram --o| informationWebResource
Subprogram --|| Program : program
Subprogram --o| bkpWebResource
'Subprogram --|> Program: program
'Subprogram --o| webResource : bkpWebResource
'Subprogram --|| webResource: informationWebResource

Protocol --|| webResource

License --|| webResource

@enduml
Loading