Issue #529 suggests a way to add metadata to columns.
However, it would also be very useful to be able to add metadata to the entire table. For example, a reference to the json-ld context for this table or a reference to other tables that define resources that we refer to in this table.
However, the CSV specification does not open for adding metadata to a csv file.
Two possible solutions are listed below. Other suggestions are welcome.
Alternative 1: Custom metadata section
Inspired by the SSSOM tsv format, one possibility could be to add an initial YAML section at the top of the CSV file.
pros:
cons:
- will confuse many CSV parsers
- unclear how this should be represented in Excel?
Alternative 2: Master configuration file
Another alternative would be to have a YAML file next to to the CSV documentation files with needed metadata.
Example of such a YAML file:
context: https://w3id.org/ssbd/context/
tables:
- datasets.csv
- processes.csv
- software.csv
- people.csv
- instruments.csv
pros:
- no changes to the existing CSV format
- works also when the tables are included as sheets in a spreadsheet
cons:
Issue #529 suggests a way to add metadata to columns.
However, it would also be very useful to be able to add metadata to the entire table. For example, a reference to the json-ld context for this table or a reference to other tables that define resources that we refer to in this table.
However, the CSV specification does not open for adding metadata to a csv file.
Two possible solutions are listed below. Other suggestions are welcome.
Alternative 1: Custom metadata section
Inspired by the SSSOM tsv format, one possibility could be to add an initial YAML section at the top of the CSV file.
pros:
cons:
Alternative 2: Master configuration file
Another alternative would be to have a YAML file next to to the CSV documentation files with needed metadata.
Example of such a YAML file:
pros:
cons: