commonmeta-py 0.107__py3-none-any.whl → 0.108__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- commonmeta/__init__.py +12 -15
- commonmeta/api_utils.py +3 -2
- commonmeta/base_utils.py +186 -3
- commonmeta/cli.py +114 -34
- commonmeta/constants.py +20 -0
- commonmeta/file_utils.py +112 -0
- commonmeta/metadata.py +102 -42
- commonmeta/readers/codemeta_reader.py +1 -1
- commonmeta/readers/crossref_reader.py +23 -10
- commonmeta/readers/crossref_xml_reader.py +1 -1
- commonmeta/readers/datacite_reader.py +6 -4
- commonmeta/readers/{json_feed_reader.py → jsonfeed_reader.py} +12 -12
- commonmeta/resources/crossref/common5.4.0.xsd +1264 -0
- commonmeta/resources/crossref/{crossref5.3.1.xsd → crossref5.4.0.xsd} +286 -88
- commonmeta/resources/crossref/doi_resources5.4.0.xsd +117 -0
- commonmeta/resources/crossref/fundingdata5.4.0.xsd +59 -0
- commonmeta/resources/crossref/fundref.xsd +29 -19
- commonmeta/resources/crossref/languages5.4.0.xsd +8119 -0
- commonmeta/resources/crossref/mediatypes5.4.0.xsd +2207 -0
- commonmeta/resources/crossref/module-ali.xsd +14 -6
- commonmeta/resources/crossref/standard-modules/mathml3/mathml3-common.xsd +101 -0
- commonmeta/resources/crossref/standard-modules/mathml3/mathml3-content.xsd +683 -0
- commonmeta/resources/crossref/standard-modules/mathml3/mathml3-presentation.xsd +2092 -0
- commonmeta/resources/crossref/standard-modules/mathml3/mathml3-strict-content.xsd +186 -0
- commonmeta/resources/crossref/standard-modules/mathml3/mathml3.xsd +9 -0
- commonmeta/resources/crossref/standard-modules/mathml3/module-ali.xsd +47 -0
- commonmeta/resources/crossref/standard-modules/module-ali.xsd +47 -0
- commonmeta/resources/crossref/standard-modules/xlink.xsd +100 -0
- commonmeta/resources/crossref/standard-modules/xml.xsd +287 -0
- commonmeta/resources/crossref/xml.xsd +287 -0
- commonmeta/schema_utils.py +25 -0
- commonmeta/utils.py +25 -9
- commonmeta/writers/bibtex_writer.py +5 -5
- commonmeta/writers/commonmeta_writer.py +4 -17
- commonmeta/writers/crossref_xml_writer.py +1031 -4
- commonmeta/writers/csl_writer.py +1 -2
- commonmeta/writers/datacite_writer.py +8 -4
- commonmeta/writers/inveniordm_writer.py +277 -2
- commonmeta/writers/ris_writer.py +3 -3
- commonmeta/writers/schema_org_writer.py +10 -5
- {commonmeta_py-0.107.dist-info → commonmeta_py-0.108.dist-info}/METADATA +4 -2
- {commonmeta_py-0.107.dist-info → commonmeta_py-0.108.dist-info}/RECORD +45 -31
- commonmeta/crossref_utils.py +0 -662
- commonmeta/resources/crossref/common5.3.1.xsd +0 -1538
- {commonmeta_py-0.107.dist-info → commonmeta_py-0.108.dist-info}/WHEEL +0 -0
- {commonmeta_py-0.107.dist-info → commonmeta_py-0.108.dist-info}/entry_points.txt +0 -0
- {commonmeta_py-0.107.dist-info → commonmeta_py-0.108.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,117 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
3
|
+
xmlns="http://www.crossref.org/doi_resources_schema/5.4.0"
|
4
|
+
targetNamespace="http://www.crossref.org/doi_resources_schema/5.4.0"
|
5
|
+
xmlns:fr5.4.0="http://www.crossref.org/fundingdata5.4.0.xsd"
|
6
|
+
xmlns:fr="http://www.crossref.org/fundref.xsd"
|
7
|
+
xmlns:ai="http://www.crossref.org/AccessIndicators.xsd"
|
8
|
+
xmlns:rel="http://www.crossref.org/relations.xsd"
|
9
|
+
xmlns:ct="http://www.crossref.org/clinicaltrials.xsd">
|
10
|
+
|
11
|
+
<!-- =============================================================
|
12
|
+
This is version 5.4.0 of the Crossref resource schema. It supports appending or updating select pieces of metadata to an existing DOI metadata record. Supported metadata includes:
|
13
|
+
|
14
|
+
- reference lists
|
15
|
+
- Crossmark metadata
|
16
|
+
- clinical trial data
|
17
|
+
- funding data
|
18
|
+
- multiple resolution URLs
|
19
|
+
- relationships
|
20
|
+
- license metadata
|
21
|
+
|
22
|
+
All changes are noted in the release notes for the schema repository in GitLab: https://gitlab.com/crossref/schema/-/releases
|
23
|
+
|
24
|
+
============================================================= -->
|
25
|
+
<xsd:include schemaLocation="common5.4.0.xsd"/>
|
26
|
+
<xsd:import namespace="http://www.crossref.org/fundingdata5.4.0.xsd" schemaLocation="fundingdata5.4.0.xsd"/>
|
27
|
+
<xsd:import namespace="http://www.crossref.org/fundref.xsd" schemaLocation="fundref.xsd"/>
|
28
|
+
<xsd:import namespace="http://www.crossref.org/AccessIndicators.xsd" schemaLocation="AccessIndicators.xsd"/>
|
29
|
+
<xsd:import namespace="http://www.crossref.org/relations.xsd" schemaLocation="relations.xsd"/>
|
30
|
+
<xsd:import namespace="http://www.crossref.org/clinicaltrials.xsd" schemaLocation="clinicaltrials.xsd"/>
|
31
|
+
<xsd:element name="doi_batch">
|
32
|
+
<xsd:complexType>
|
33
|
+
<xsd:sequence>
|
34
|
+
<xsd:element ref="head"/>
|
35
|
+
<xsd:element ref="body"/>
|
36
|
+
</xsd:sequence>
|
37
|
+
<xsd:attribute name="version" type="xsd:string" fixed="5.4.0"/>
|
38
|
+
</xsd:complexType>
|
39
|
+
</xsd:element>
|
40
|
+
<xsd:element name="head">
|
41
|
+
<xsd:complexType>
|
42
|
+
<xsd:sequence>
|
43
|
+
<xsd:element ref="doi_batch_id"/>
|
44
|
+
<xsd:element ref="depositor"/>
|
45
|
+
</xsd:sequence>
|
46
|
+
</xsd:complexType>
|
47
|
+
</xsd:element>
|
48
|
+
<xsd:element name="body">
|
49
|
+
<xsd:complexType>
|
50
|
+
<xsd:sequence>
|
51
|
+
<xsd:element ref="doi_citations" minOccurs="0" maxOccurs="unbounded"/>
|
52
|
+
<xsd:element ref="doi_resources" minOccurs="0" maxOccurs="unbounded"/>
|
53
|
+
<xsd:element ref="crossmark_data" minOccurs="0" maxOccurs="unbounded"/>
|
54
|
+
<xsd:element ref="fundref_data" minOccurs="0" maxOccurs="unbounded"/>
|
55
|
+
<xsd:element ref="lic_ref_data" minOccurs="0" maxOccurs="unbounded"/>
|
56
|
+
<xsd:element ref="doi_relations" minOccurs="0" maxOccurs="unbounded"/>
|
57
|
+
<xsd:element ref="clinicaltrial_data" minOccurs="0" maxOccurs="unbounded"/>
|
58
|
+
</xsd:sequence>
|
59
|
+
</xsd:complexType>
|
60
|
+
</xsd:element>
|
61
|
+
<xsd:element name="doi_citations">
|
62
|
+
<xsd:complexType>
|
63
|
+
<xsd:sequence>
|
64
|
+
<xsd:element ref="doi"/>
|
65
|
+
<xsd:element ref="citation_list"/>
|
66
|
+
</xsd:sequence>
|
67
|
+
</xsd:complexType>
|
68
|
+
</xsd:element>
|
69
|
+
<xsd:element name="doi_resources">
|
70
|
+
<xsd:complexType>
|
71
|
+
<xsd:sequence>
|
72
|
+
<xsd:element ref="doi"/>
|
73
|
+
<xsd:element ref="collection"/>
|
74
|
+
</xsd:sequence>
|
75
|
+
</xsd:complexType>
|
76
|
+
</xsd:element>
|
77
|
+
<xsd:element name="crossmark_data">
|
78
|
+
<xsd:complexType>
|
79
|
+
<xsd:sequence>
|
80
|
+
<xsd:element ref="doi"/>
|
81
|
+
<xsd:element ref="crossmark"/>
|
82
|
+
</xsd:sequence>
|
83
|
+
</xsd:complexType>
|
84
|
+
</xsd:element>
|
85
|
+
<xsd:element name="fundref_data">
|
86
|
+
<xsd:complexType>
|
87
|
+
<xsd:sequence>
|
88
|
+
<xsd:element ref="doi"/>
|
89
|
+
<xsd:element ref="fr:program"/>
|
90
|
+
</xsd:sequence>
|
91
|
+
</xsd:complexType>
|
92
|
+
</xsd:element>
|
93
|
+
<xsd:element name="lic_ref_data">
|
94
|
+
<xsd:complexType>
|
95
|
+
<xsd:sequence>
|
96
|
+
<xsd:element ref="doi"/>
|
97
|
+
<xsd:element ref="ai:program"/>
|
98
|
+
</xsd:sequence>
|
99
|
+
</xsd:complexType>
|
100
|
+
</xsd:element>
|
101
|
+
<xsd:element name="doi_relations">
|
102
|
+
<xsd:complexType>
|
103
|
+
<xsd:sequence>
|
104
|
+
<xsd:element ref="doi"/>
|
105
|
+
<xsd:element ref="rel:program"/>
|
106
|
+
</xsd:sequence>
|
107
|
+
</xsd:complexType>
|
108
|
+
</xsd:element>
|
109
|
+
<xsd:element name="clinicaltrial_data">
|
110
|
+
<xsd:complexType>
|
111
|
+
<xsd:sequence>
|
112
|
+
<xsd:element ref="doi"/>
|
113
|
+
<xsd:element ref="ct:program"/>
|
114
|
+
</xsd:sequence>
|
115
|
+
</xsd:complexType>
|
116
|
+
</xsd:element>
|
117
|
+
</xsd:schema>
|
@@ -0,0 +1,59 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
3
|
+
targetNamespace="http://www.crossref.org/fundingdata5.4.0.xsd"
|
4
|
+
xmlns="http://www.crossref.org/fundingdata5.4.0.xsd">
|
5
|
+
|
6
|
+
<!--=========Change History===========
|
7
|
+
10/9/24 (PDF) added ror identifier
|
8
|
+
5/2/13 (PDF) changed funding_identifier to award_number
|
9
|
+
04/10/24 (PDF) added ror and grant_doi
|
10
|
+
-->
|
11
|
+
|
12
|
+
<xsd:element name="program">
|
13
|
+
<xsd:annotation>
|
14
|
+
<xsd:documentation>Information about registering funding data is available in our documentation: https://www.crossref.org/documentation/funder-registry/funding-data-deposits/</xsd:documentation>
|
15
|
+
</xsd:annotation>
|
16
|
+
<xsd:complexType>
|
17
|
+
<xsd:sequence>
|
18
|
+
<xsd:element ref="assertion" minOccurs="0" maxOccurs="unbounded"/>
|
19
|
+
</xsd:sequence>
|
20
|
+
<xsd:attribute name="name" type="xsd:string" fixed="fundref"/>
|
21
|
+
</xsd:complexType>
|
22
|
+
</xsd:element>
|
23
|
+
<xsd:element name="assertion">
|
24
|
+
<xsd:annotation>
|
25
|
+
<xsd:documentation>Funding data attributes included in assertion are:
|
26
|
+
* fundgroup: used to group funding info for items with multiple funding sources. Required for items with multiple award_number assertions, optional for items with a single award_number
|
27
|
+
* funder_identifier: funding agency identifier, must be nested within the funder_name assertion
|
28
|
+
* ror: ROR ID of a funder
|
29
|
+
* funder_name: name of the funding agency (required)
|
30
|
+
* award_number: grant number or other fund identifier
|
31
|
+
</xsd:documentation>
|
32
|
+
</xsd:annotation>
|
33
|
+
<xsd:complexType mixed="true">
|
34
|
+
<xsd:sequence>
|
35
|
+
<xsd:element ref="assertion" minOccurs="0" maxOccurs="unbounded"/>
|
36
|
+
</xsd:sequence>
|
37
|
+
<xsd:attribute name="provider" default="publisher">
|
38
|
+
<xsd:simpleType>
|
39
|
+
<xsd:restriction base="xsd:NMTOKEN">
|
40
|
+
<xsd:enumeration value="publisher"/>
|
41
|
+
<xsd:enumeration value="crossref"/>
|
42
|
+
</xsd:restriction>
|
43
|
+
</xsd:simpleType>
|
44
|
+
</xsd:attribute>
|
45
|
+
<xsd:attribute name="name" use="required">
|
46
|
+
<xsd:simpleType>
|
47
|
+
<xsd:restriction base="xsd:NMTOKEN">
|
48
|
+
<xsd:enumeration value="fundgroup"/>
|
49
|
+
<xsd:enumeration value="funder_identifier"/>
|
50
|
+
<xsd:enumeration value="ror"/>
|
51
|
+
<xsd:enumeration value="funder_name"/>
|
52
|
+
<xsd:enumeration value="award_number"/>
|
53
|
+
<!--<xsd:enumeration value="grant_doi"/> -->
|
54
|
+
</xsd:restriction>
|
55
|
+
</xsd:simpleType>
|
56
|
+
</xsd:attribute>
|
57
|
+
</xsd:complexType>
|
58
|
+
</xsd:element>
|
59
|
+
</xsd:schema>
|
@@ -1,14 +1,17 @@
|
|
1
|
-
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
3
|
+
targetNamespace="http://www.crossref.org/fundref.xsd"
|
4
|
+
xmlns="http://www.crossref.org/fundref.xsd">
|
5
|
+
|
6
|
+
<!--=========Change History===========
|
7
|
+
10/9/24 (PDF) added ror identifier
|
2
8
|
5/2/13 (PDF) changed funding_identifier to award_number
|
3
|
-
|
9
|
+
04/10/24 (PDF) added ror and grant_doi
|
10
|
+
-->
|
11
|
+
|
4
12
|
<xsd:element name="program">
|
5
13
|
<xsd:annotation>
|
6
|
-
<xsd:documentation>
|
7
|
-
</crossmark>
|
8
|
-
</fr:program>
|
9
|
-
</journal_article>
|
10
|
-
</assertion>
|
11
|
-
</xsd:documentation>
|
14
|
+
<xsd:documentation>Information about registering funding data is available in our documentation: https://www.crossref.org/documentation/funder-registry/funding-data-deposits/</xsd:documentation>
|
12
15
|
</xsd:annotation>
|
13
16
|
<xsd:complexType>
|
14
17
|
<xsd:sequence>
|
@@ -19,7 +22,13 @@
|
|
19
22
|
</xsd:element>
|
20
23
|
<xsd:element name="assertion">
|
21
24
|
<xsd:annotation>
|
22
|
-
<xsd:documentation>
|
25
|
+
<xsd:documentation>Funding data attributes included in assertion are:
|
26
|
+
* fundgroup: used to group funding info for items with multiple funding sources. Required for items with multiple award_number assertions, optional for items with a single award_number
|
27
|
+
* funder_identifier: funding agency identifier, must be nested within the funder_name assertion
|
28
|
+
* ror: ROR ID of a funder
|
29
|
+
* funder_name: name of the funding agency (required)
|
30
|
+
* award_number: grant number or other fund identifier
|
31
|
+
</xsd:documentation>
|
23
32
|
</xsd:annotation>
|
24
33
|
<xsd:complexType mixed="true">
|
25
34
|
<xsd:sequence>
|
@@ -27,23 +36,24 @@
|
|
27
36
|
</xsd:sequence>
|
28
37
|
<xsd:attribute name="provider" default="publisher">
|
29
38
|
<xsd:simpleType>
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
39
|
+
<xsd:restriction base="xsd:NMTOKEN">
|
40
|
+
<xsd:enumeration value="publisher"/>
|
41
|
+
<xsd:enumeration value="crossref"/>
|
42
|
+
</xsd:restriction>
|
34
43
|
</xsd:simpleType>
|
35
44
|
</xsd:attribute>
|
36
45
|
<xsd:attribute name="name" use="required">
|
37
46
|
<xsd:simpleType>
|
38
47
|
<xsd:restriction base="xsd:NMTOKEN">
|
39
|
-
<xsd:enumeration value="fundgroup"
|
40
|
-
|
41
|
-
<xsd:enumeration value="
|
42
|
-
<xsd:enumeration value="funder_name"
|
43
|
-
<xsd:enumeration value="award_number"
|
48
|
+
<xsd:enumeration value="fundgroup"/>
|
49
|
+
<xsd:enumeration value="funder_identifier"/>
|
50
|
+
<xsd:enumeration value="ror"/>
|
51
|
+
<xsd:enumeration value="funder_name"/>
|
52
|
+
<xsd:enumeration value="award_number"/>
|
53
|
+
<!--<xsd:enumeration value="grant_doi"/> -->
|
44
54
|
</xsd:restriction>
|
45
55
|
</xsd:simpleType>
|
46
56
|
</xsd:attribute>
|
47
57
|
</xsd:complexType>
|
48
58
|
</xsd:element>
|
49
|
-
</xsd:schema>
|
59
|
+
</xsd:schema>
|