Commonmeta Writer

This notebook shows how to generate a metadata in Commonmeta format. Commonmeta is the internal format used by commonmeta-py, all readers generate metadata in this format, and all writers use commonmeta as input.

Fetch metadata

from commonmeta import Metadata

# Fetch metadata from a DOI
string = '10.1155/2012/291294'
metadata = Metadata(string)

# Check that metadata was fetched successfully
print(metadata.state)
findable

Generate Commonmeta

We can now generate commonmeta.

commonmeta = metadata.write()
print(commonmeta)
{
    "id": "https://doi.org/10.1155/2012/291294",
    "type": "JournalArticle",
    "url": "http://www.hindawi.com/journals/pm/2012/291294",
    "contributors": [
        {
            "type": "Person",
            "contributorRoles": [
                "Author"
            ],
            "givenName": "Wendy",
            "familyName": "Thanassi",
            "affiliation": [
                {
                    "name": "Department of Medicine, Veterans Affairs Palo Alto Health Care System, 3801 Miranda Avenue MC-, Palo Alto, CA 94304-1207, USA"
                },
                {
                    "name": "Occupational Health Strategic Health Care Group, Office of Public Health, Veterans Health Administration, Washington, DC 20006, USA"
                },
                {
                    "name": "Division of Emergency Medicine, Stanford University School of Medicine, Stanford, CA 94304, USA"
                },
                {
                    "name": "War Related Illness and Injury Study Center (WRIISC) and Mental Illness Research Education and Clinical Center (MIRECC), Department of Veterans Affairs, Palo Alto, CA 94304, USA"
                }
            ]
        },
        {
            "type": "Person",
            "contributorRoles": [
                "Author"
            ],
            "givenName": "Art",
            "familyName": "Noda",
            "affiliation": [
                {
                    "name": "War Related Illness and Injury Study Center (WRIISC) and Mental Illness Research Education and Clinical Center (MIRECC), Department of Veterans Affairs, Palo Alto, CA 94304, USA"
                },
                {
                    "name": "Department of Psychiatry and Behavioral Sciences, Stanford University School of Medicine, Stanford, CA 94304, USA"
                }
            ]
        },
        {
            "id": "https://orcid.org/0000-0003-2043-4925",
            "type": "Person",
            "contributorRoles": [
                "Author"
            ],
            "givenName": "Beatriz",
            "familyName": "Hernandez",
            "affiliation": [
                {
                    "name": "War Related Illness and Injury Study Center (WRIISC) and Mental Illness Research Education and Clinical Center (MIRECC), Department of Veterans Affairs, Palo Alto, CA 94304, USA"
                },
                {
                    "name": "Department of Psychiatry and Behavioral Sciences, Stanford University School of Medicine, Stanford, CA 94304, USA"
                }
            ]
        },
        {
            "type": "Person",
            "contributorRoles": [
                "Author"
            ],
            "givenName": "Jeffery",
            "familyName": "Newell",
            "affiliation": [
                {
                    "name": "War Related Illness and Injury Study Center (WRIISC) and Mental Illness Research Education and Clinical Center (MIRECC), Department of Veterans Affairs, Palo Alto, CA 94304, USA"
                }
            ]
        },
        {
            "type": "Person",
            "contributorRoles": [
                "Author"
            ],
            "givenName": "Paul",
            "familyName": "Terpeluk",
            "affiliation": [
                {
                    "name": "Department of Occupational Health, The Cleveland Clinic, Cleveland, OH 44195, USA"
                }
            ]
        },
        {
            "type": "Person",
            "contributorRoles": [
                "Author"
            ],
            "givenName": "David",
            "familyName": "Marder",
            "affiliation": [
                {
                    "name": "University Health Services, University of Illinois Chicago, Chicago, IL 60612, USA"
                }
            ]
        },
        {
            "type": "Person",
            "contributorRoles": [
                "Author"
            ],
            "givenName": "Jerome A.",
            "familyName": "Yesavage",
            "affiliation": [
                {
                    "name": "War Related Illness and Injury Study Center (WRIISC) and Mental Illness Research Education and Clinical Center (MIRECC), Department of Veterans Affairs, Palo Alto, CA 94304, USA"
                },
                {
                    "name": "Department of Psychiatry and Behavioral Sciences, Stanford University School of Medicine, Stanford, CA 94304, USA"
                }
            ]
        }
    ],
    "titles": [
        {
            "title": "Delineating a Retesting Zone Using Receiver Operating Characteristic Analysis on Serial QuantiFERON Tuberculosis Test Results in US Healthcare Workers"
        }
    ],
    "publisher": {
        "id": "https://api.crossref.org/members/98",
        "name": "Hindawi Limited"
    },
    "date": {
        "published": "2012",
        "updated": "2016-08-02T18:42:41Z"
    },
    "container": {
        "type": "Journal",
        "identifier": "2090-1844",
        "identifierType": "ISSN",
        "title": "Pulmonary Medicine",
        "volume": "2012",
        "firstPage": "1",
        "lastPage": "7"
    },
    "subjects": [
        {
            "subject": "Pulmonary and Respiratory Medicine"
        },
        {
            "subject": "General Medicine"
        }
    ],
    "language": "en",
    "references": [
        {
            "key": "1",
            "publicationYear": "2009",
            "volume": "179",
            "containerTitle": "American Journal of Respiratory and Critical Care Medicine"
        },
        {
            "key": "2",
            "doi": "https://doi.org/10.1128/cvi.00168-09"
        },
        {
            "key": "3",
            "doi": "https://doi.org/10.1164/rccm.200604-472oc"
        },
        {
            "key": "4",
            "doi": "https://doi.org/10.5588/ijtld.11.0364"
        },
        {
            "key": "5",
            "doi": "https://doi.org/10.1128/cvi.05058-11"
        },
        {
            "key": "6",
            "doi": "https://doi.org/10.1007/s00420-010-0571-x"
        },
        {
            "key": "7",
            "doi": "https://doi.org/10.1086/593965"
        },
        {
            "key": "8",
            "doi": "https://doi.org/10.1378/chest.09-2350"
        },
        {
            "key": "9",
            "publicationYear": "2008",
            "volume": "12",
            "issue": "11",
            "firstPage": "1235",
            "containerTitle": "International Journal of Tuberculosis and Lung Disease"
        },
        {
            "key": "10",
            "doi": "https://doi.org/10.1056/nejmsa031667"
        },
        {
            "key": "11",
            "doi": "https://doi.org/10.1378/chest.128.1.116"
        },
        {
            "key": "12",
            "publicationYear": "2012"
        },
        {
            "key": "13",
            "publicationYear": "2010",
            "volume": "59",
            "issue": "5",
            "firstPage": "1",
            "containerTitle": "Morbidity and Mortality Weekly Report"
        },
        {
            "key": "14",
            "publicationYear": "2011"
        },
        {
            "key": "15",
            "publicationYear": "2011"
        },
        {
            "key": "16",
            "publicationYear": "2011"
        },
        {
            "key": "17",
            "publicationYear": "2011"
        },
        {
            "key": "18",
            "publicationYear": "2012"
        },
        {
            "key": "20",
            "publicationYear": "1992"
        },
        {
            "key": "22",
            "doi": "https://doi.org/10.3205/dgkh000148"
        },
        {
            "key": "23",
            "doi": "https://doi.org/10.1378/chest.11-0992"
        },
        {
            "key": "24",
            "doi": "https://doi.org/10.1186/1471-2334-10-220"
        },
        {
            "key": "25",
            "doi": "https://doi.org/10.1186/1745-6673-7-6"
        },
        {
            "key": "27",
            "doi": "https://doi.org/10.1128/cvi.00398-07"
        },
        {
            "key": "28",
            "doi": "https://doi.org/10.1164/rccm.201006-0974oc"
        },
        {
            "key": "29",
            "doi": "https://doi.org/10.1136/thx.2010.143180"
        },
        {
            "key": "30",
            "doi": "https://doi.org/10.1378/chest.12-0045"
        }
    ],
    "license": {
        "id": "CC-BY-3.0",
        "url": "https://creativecommons.org/licenses/by/3.0/legalcode"
    },
    "descriptions": [
        {
            "description": "Objective. To find a statistically significant separation point for the QuantiFERON Gold In-Tube (QFT) interferon gamma release assay that could define an optimal \u201cretesting zone\u201d for use in serially tested low-risk populations who have test \u201creversions\u201d from initially positive to subsequently negative results.Method. Using receiver operating characteristic analysis (ROC) to analyze retrospective data collected from 3 major hospitals, we searched for predictors of reversion until statistically significant separation points were revealed. A confirmatory regression analysis was performed on an additional sample.Results. In 575 initially positive US healthcare workers (HCWs), 300 (52.2%) had reversions, while 275 (47.8%) had two sequential positive tests. The most statistically significant (Kappa = 0.48, chi-square = 131.0,P<0.001) separation point identified by the ROC for predicting reversion was the tuberculosis antigen minus-nil (TBag-nil) value at 1.11 International Units per milliliter (IU/mL). The second separation point was found at TBag-nil at 0.72 IU/mL (Kappa = 0.16, chi-square = 8.2,P<0.01). The model was validated by the regression analysis of 287 HCWs.Conclusion. Reversion likelihood increases as the TBag-nil approaches the manufacturer's cut-point of 0.35 IU/mL. The most statistically significant separation point between those who test repeatedly positive and those who revert is 1.11 IU/mL. Clinicians should retest low-risk individuals with initial QFT results < 1.11 IU/mL.",
            "descriptionType": "Abstract"
        }
    ],
    "files": [
        {
            "url": "http://downloads.hindawi.com/journals/pm/2012/291294.pdf",
            "mimeType": "application/pdf"
        },
        {
            "url": "http://downloads.hindawi.com/journals/pm/2012/291294.xml",
            "mimeType": "application/xml"
        }
    ],
    "provider": "Crossref"
}