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

Implement describe-file-collection #652

Open
mih opened this issue Apr 11, 2024 · 3 comments
Open

Implement describe-file-collection #652

mih opened this issue Apr 11, 2024 · 3 comments

Comments

@mih
Copy link
Member

mih commented Apr 11, 2024

The work over at https://github.com/psychoinformatics-de/datalad-concepts has reached a state that makes it worthwhile to start implementing the first pieces for a dataset serializer. I am thinking that a good first step would be to provide the analog of the directory listing compiler that is used in the context of https://github.com/datalad/datalad-catalog. I am thinking that an implementation could simply wrap ls-file-collection. Internally, it would more or less translate the data classes ls-file-collection uses already. But I believe it would be sensible to not pollute ls-file-collection API with this functionality.

I am further thinking that describe-file-collection would be a good name, and it would support any file collection that ls-file-collection supports: directory, tarfile, zipfile, gittree, gitworktree, annexworktree.

The implementation would (need to) be done in a way that feature additions to ls-file-collection (i.e. new collection types) automatically become available for describe-file-collection too.

In terms of metadata types, a file collection maps to a https://concepts.datalad.org/s/distribution/unreleased/Distribution

@mslw
Copy link
Collaborator

mslw commented Apr 11, 2024

provide the analog of the directory listing compiler that is used in the context of https://github.com/datalad/datalad-catalog

FTR, my directory listing compilers:

these were really quick drafts, see commit messages for explanations why they ended up the way they are.

@mih
Copy link
Member Author

mih commented Apr 12, 2024

https://concepts.datalad.org/ now provides JSON-LD context, LinkML YAML and OWL for every schema.

A sensible behavior for describe-file-collection appears to be to produce JSON-LD that is plain JSON with an @context field that points to the relevant schema and version of it. Template:

  https://concepts.datalad.org/s/<schema>/<version>.jsonld

I see no real need to implement the complexity required for being able to report in multiple "languages" (schemas and versions). We can simply refer to the one that is used. https://concepts.datalad.org/ is already set up to continue to serve past schema versions.

@mih
Copy link
Member Author

mih commented Apr 12, 2024

After making the first code steps with this, I believe this is not suitable for datalad-next. Too little s understood with confidence. I will pursue this development over at https://github.com/mih/datalad-mihextras until a bigger picture emerges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants