Giter VIP home page Giter VIP logo

citation-file-format / citation-file-format Goto Github PK

View Code? Open in Web Editor NEW
429.0 429.0 107.0 31.77 MB

The Citation File Format lets you provide citation metadata for software or datasets in plaintext files that are easy to read by both humans and machines.

Home Page: http://citation-file-format.github.io

License: Creative Commons Attribution 4.0 International

Python 100.00%
attribution citation citation-files credit format research-software-engineering software-sustainability wssspe

citation-file-format's Introduction

Citation File Format

Build Status DOI License: CC BY 4.0 Project homepage

The Citation File Format lets you provide citation metadata for software or datasets in plaintext files that are easy to read by both humans and machines.

Structure

You can specify citation metadata for your software (or dataset) in a file named CITATION.cff. This is what a typical CITATION.cff file may look like for research software:

cff-version: 1.2.0
message: If you use this software, please cite it using these metadata.
title: My Research Software
abstract: This is my awesome research software. It does many things.
authors:
  - family-names: Druskat
    given-names: Stephan
    orcid: "https://orcid.org/1234-5678-9101-1121"
  - name: "The Research Software project"
version: 0.11.2
date-released: "2021-07-18"
identifiers:
  - description: This is the collection of archived snapshots of all versions of My Research Software
    type: doi
    value: "10.5281/zenodo.123456"
  - description: This is the archived snapshot of version 0.11.2 of My Research Software
    type: doi
    value: "10.5281/zenodo.123457"
license: Apache-2.0
repository-code: "https://github.com/citation-file-format/my-research-software"

In addition, the Citation File Format allows you to

Format specifications πŸ“š

You can find the complete format specifications in the Guide to the Citation File Format schema.

Why should I add a CITATION.cff file to my repository? πŸ’‘

When you do this, great things may happen:

  1. Users of your software can easily cite it using the metadata from CITATION.cff!
  2. If your repository is hosted on GitHub, they will show the citation information in the sidebar, which makes it easy for visitors to cite your software or dataset correctly.
  3. When you publish your software on Zenodo via the GitHub-Zenodo integration, they will use the metadata from your CITATION.cff file.
  4. People can import the correct reference to your software into the Zotero reference manager via a browser plugin.

Creation βž•

To create a CITATION.cff file, you can

  • use the cffinit website,
  • copy and paste the example snippet, and adapt it to your needs, or
  • create a new file called CITATION.cff using the Add file button on GitHub, and use the template they provide.

Validation βœ”οΈ

You can validate your CITATION.cff file on the command line with the cffconvert Python package:

# Install cffconvert with pip in user space
python3 -m pip install --user cffconvert

# Validate your CFF file
cffconvert --validate

If you get a Traceback with error messages, look for the relevant validation error and fix it. If the output is very long, it may help if you search it for lines starting with jsonschema.exceptions.ValidationError.

If you prefer to use Docker, you can use the cffconvert Docker image:

cd <directory-containing-your-CITATION.cff>
docker run --rm -v ${PWD}:/app citationcff/cffconvert --validate

Tools to work with CITATION.cff files πŸ”§

There is tooling available to work with CITATION.cff files to do different things: create new files, edit existing files, validate existing files, convert files from the Citation File Format into another format. The following table gives an overview of the tools that we know about. If there is a tool missing from this table, please open a new issue and let us know.

Creation Editing/Updating Validation Conversion
Command line β€’ cffconvert β€’ cffconvert
β€’ bibtex-to-cff
β€’ cff-from-621
β€’ openCARP-CI
GitHub Actions cff-validator β€’ cffconvert
β€’ codemeta2cff
GitHub Bot #238
Docker cffconvert Docker image cffconvert Docker image
Go β€’ datatools/codemeta2cff
Haskell β€’ cffreference
Java β€’ CFF Maven plugin β€’ CFF Maven plugin β€’ CFF Maven plugin
JavaScript β€’ Citation.js plugin
Julia β€’ Bibliography.jl β€’ Bibliography.jl
PHP β€’ bibtex-to-cff
Python β€’ doi2cff β€’ cffconvert β€’ cff-from-621
β€’ cffconvert
β€’ doi2cff
β€’ openCARP-CI
β€’ py_bibtex_to_cff_converter
R β€’ citation
β€’ r2cff
β€’ handlr
β€’ cffr
Ruby β€’ ruby-cff β€’ ruby-cff β€’ ruby-cff β€’ ruby-cff
Rust β€’ Aeruginous β€’ Aeruginous β€’ citeworks
TypeScript #28
Website β€’ cffinit

Maintainers πŸ€“

The Citation File Format schema is maintained by

Contributing 🀝

The Citation File Format is a collaborative project and we welcome suggestions and contributions. We hope one of the invitations below works for you, but if not, please let us know!

πŸƒ I'm busy, I only have 1 minute

  • Tell a friend about the Citation File Format, or tweet about it!
  • Give the project a star ⭐!

⏳ I've got 10 minutes - tell me what I should do

  • Create a CITATION.cff file for your repository.
  • Suggest ideas for how you would like to use the Citation File Format, or for an improvement to the format or its tooling.
  • If you know how to validate CITATION.cff files, help someone with a validation problem and look at the issues labeled GitHub labels

πŸ’» I've got a few hours to work on this

πŸŽ‰ I want to help grow the community

  • Write a blog post or news item for your own community.
  • Organise a hack event or workshop to help others use or improve the Citation File Format.

Please read the more detailed contributing guidelines and open a GitHub issue to suggest a new idea or let us know about bugs. Please put up pull requests for changes to the format and schema against the develop branch!

License βš–οΈ

Copyright Β© 2016 - 2023. The Citation File Format Contributors

This work is licensed under a Creative Commons Attribution 4.0 International (CC-BY-4.0) license.

Acknowledgments πŸ™

We'd like to thank everyone who has contributed to the Citation File Format!
They are listed in the CITATION.cff file for this repository. Please open an issue if you find that you are missing from the file.

We gratefully acknowledge support from:

citation-file-format's People

Contributors

abelsiqueira avatar alex-konovalov avatar axel-loewe avatar bast avatar dieghernan avatar dpshelio avatar egonw avatar funkyfuture avatar hainesr avatar jodischneider avatar jspaaks avatar kevinmatthes avatar mcmarius avatar monperrus avatar olexandr-konovalov avatar ots22 avatar pothitos avatar sbliven avatar sdruskat avatar vdplasthijs avatar yarikoptic avatar yochannah avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

citation-file-format's Issues

Make CFF version identifiable in file

Clients (human and software alike) should be able to identify the version of CFF that is used in a CITATION.cff file.

The simplest solution would be to introduce a mandatory key cff-version.

Other options should be investigated, such as custom YAML tags, etc.

Review and test 1.0-RC2

1.0-RC2 should be reviewed again and tested against CodeMeta crosswalk before releasing 1.0.

Fix examples in 1.0.0 and 1.0.1

1.0.0 and 1.0.1 still include examples that follow 1.0-RC1 and hence will not validate against the schema.
To be fixed in 1.0.2.

YAML list structure

In the file structure we recommend "exactly one message containing instructions ...".
This is perhaps nit-picking (but it is good to settle this early) but I was a bit surprised by the hyphen which signals that this is a list item. Why not message: If you use this software, please cite the works below. instead of the one with hyphen?

Related to this (we can split this up into a separate issue) it could be an idea to collect references to references. I.e., instead of:

- message: If you use this software, please cite the works below.
- type: software-code
  authors:
    - name: ...
      orcid: ...
- type: ...
  authors:
    - name: ...
      orcid: ...

rather:

message: If you use this software, please cite the works below.
references:
  - type: software-code
    authors:
      - name: ...
        orcid: ...
  - type: ...
    authors:
      - name: ...
        orcid: ...

The latter signals to me more clearly that there is only one message and that the types are actually references.

CFF-Core 1.0 will break full BibTeX compatibility for person names

1.0-RC1 has introduced splittable names according to W3C suggestions and the BibTeX standard of using four units (family names, given names, name particle and name suffix, cf. #10 (comment)).

This will be broken in 1.0 to achieve cross-walkability with CodeMeta, which only defines given name and family name (cf. there and @mfenner for details).

In order to re-introduce this in CFF-Core, it will have to be fixed in CodeMeta first, which depends on it being fixed in schema.org.

Back-pedal to minimal specs

See force11/force11-sciwg#24: If the purpose of CFF is to provide citation metadata, some of the unrelated keys (e.g., role in person objects, programming-languages) are unnecessary. Hence, CFF "Core" should be about citation metada only.

If feasible (#22), keys going beyond "core" could be developed further towards, e.g., an implementation of transitive credit, but this should be done in an extension (and a separate repo), e.g., "CFF Transitive".

Documentation?

Stupid question: Where is the documentation on how it looks like, and maybe some examples?

I came to this site:
https://citation-file-format.github.io/
Which motivates me to use it - but does not feature examples as far as I could tell.

Then I went to github:
https://github.com/citation-file-format
It seems to have been the only link that might contain the documentation.

That contains among some language specific things (which I am currently not interested in, as I am still trying to rather understand what it is) and the websites only to repositories:

What have I missed? Where can I learn what a file looks like, except for reading the python parser in schema?

Create converter for CodeMeta JSON

This depends on #21.

As CodeMeta JSON emerges as the go-to format for extraction and provision of software metadata, it is imperative that CFF can interface with CodeMeta JSON.

Hence, the first converter that should be built is one for CodeMeta JSON.

Clarify why neither the 'repository{-*}' nor the 'doi' key are required

Stumbled over this when re-reading the principles paper: All three use cases (1, 3, 15) require Location/repository as well as Unique identifier.

However, the text mentions in sections "Access to software" and "Unique identification", that in cases where no unique identifier exist, a combination of repo URL and, e.g., commit hash or version number may be used. Therefore, the 'doi' key cannot be made required as this would lock out users providing metadata for a software without a unique ID.

Likewise, ("Access to software"):

For commercial software, the metadata should still provide information on how to access the specific software, but this may be a company’s product number or a link to a website that allows the software be purchased. As stated in the Persistence principle (4), we recognize that the software version may no longer be available, but it still should be cited along with information about how it was accessed.

Hence, repository information cannot be made required.

This information is indirectly given in Software citation metadata (required), but should perhaps be made more public in a FAQ or similar.

Introduce "scope" key in "references" subschema?

As discussed in #9 (and more specifically https://github.com/sdruskat/citation-file-format/issues/9#issuecomment-333075185), each CFF file should have a single, global field message which has scope over the software that the CFF file is maintained for.

Every discrete "piece of software" should have its own CFF file.

This means that a larger software project may have more than one CFF file. Ideally, these would be distributed over, e.g., different nesting levels in the repository, i.e., different "directories". For example, the repo root would contain a CFF file with references to the software project as a whole, and perhaps another publication discussing the software project as a whole. Other levels may contain CFF files with references to smaller parts of the software. For example, if a Java class implements a specific algorithm which should be made available for citation via CFF, the repo level for the package containing that class should contain the CFF file giving a reference to the algorithm paper:

In other cases this might not be feasible, e.g.:

  • CFF files for executables bundling different packages
  • Several classes implementing different algorithms in the same package
  • Repo structure does not reflect package structure in a programming language

Here, I can see two options to solve this in the CFF file.

  1. Use the global message to instruct the user which reference to cite for which, package/class, etc.
  2. Specify a scope for each single reference which states which package/class/LOCs, etc., the reference "is meant for".

I think both options are valid.

Option 2 could either be implemented by using the notes field, but this would break Separation of Concerns, as notes will likely be used for more general purposes by creators of CFF files. Hence, I'd introduce a new key scope on the level of references whose value would be the information which software the reference(s) "are meant for".

Make website more accessible

https://citation-file-format.github.io should give a good overview on its home page, including one or more simple examples to get started (cf. #50).

The home page should also list tools available, or point to a centrally maintained list in citation-file-format/citation-file-format's README.md (which should also be updated to be more accessible and informative.

Wrap long lines

I suggest to wrap the currently long lines in the source text (gq in vim). This will create more manageable diffs for small edits in text.

Move repo to a CFF org

It makes sense (especially in the light of #23) to split up the current state of CFF across several repos:

  • cff-core for the schema for a minimal format for citation metadata
  • cff-transitive (if feasible) for an extension for transitive credit
  • A repo for the website & docs (i.e., what's in here at the moment, Jekyll site + PDF)

Implement strict schema if and when possible

A strict schema with attribute constraints for specific reference types (subschemas, e.g., disallow commit for type conference) would be a great asset.

However, this is currently not supported by the Python port for Kwalify, PyKwalify (which has a larger feature set than Kwalify), which I have originally identified as probably the best option for validating CITATION.cff files against a schema (other suggestions welcome!). See issue #12 for details.

At the moment, the plan for CFF is to have a relatively loose schema with PyKwalify, and update to a stricter schema in a later version, if and when this becomes possible in PyKwalify (cf. Grokzen/pykwalify#112).

Run a case study

In order to test usability and usefulness of CFF, a case study with a (smaller) repository/community should be run, which uses citation-relevant metadata, but not in a standardized format.

@npch has suggested ASCL.

Add examples

The specs should contain a sizable list of examples of complete CITATION.cff files, at least for the most common reference types.

Create a creation service for CFF files

Create a web service for the creation of CFF files from scratch.

This should include a web frontend where users can input their specs and create a file for download.

Should harvest available metadata from, e.g., ORCID and DOI providers or, indeed, integrate with providers' APIs to create a DOI in the process (needs to be investigated if, e.g., Zenodo supports this).

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.