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

[Question] Process for converting JSON response from metadata/user endpoint to JSON-LD in Bioschema format for FAIRsoft evaluator #1

Open
abnerbog opened this issue Sep 14, 2024 · 1 comment

Comments

@abnerbog
Copy link

abnerbog commented Sep 14, 2024

Question:
What is the process used for converting the JSON output from the metadata/user endpoint in the Metadata Extractor into a JSON-LD file in Bioschema format that can be used as input in the FAIRsoft evaluator?

Description and Context:
I am investigating programmatically using the FAIRsoft evaluator and would like to understand the specific steps or logic used to transform JSON output into a compliant JSON-LD file that adheres to the Bioschema format. Understanding this process will help ensure my integration of metadata follows best practices and is aligned with the tool’s intended usage.

Attempts:
I have reviewed this repository and also explored the Node-API repository on GitLab for any relevant endpoints or code that handles this conversion but have not yet found a detailed explanation or working solution.

Additional Context:
Any specific code references, guidelines, or examples of converting the JSON output from the metadata/user endpoint to JSON-LD and then inputting this in the FAIRsoft evaluator would be very helpful.

@EvaMart
Copy link
Member

EvaMart commented Oct 29, 2024

Hi Abner,

The code responsible for the conversion is here: makejson.py. It performs a mapping of attributes for the conversion.

As for an endpoint, the front end currently uses POST /tools/jsonld (see code). This endpoint expects metadata in a slightly different format than '/metadata/user', due to additional indexing on the front end.

If you need to convert metadata to maSMP (which includes properties from schema.org, Bioschemas, etc.) programmatically, I can easily adapt the /tools/jsonld endpoint by adding a parameter to handle this.

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