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

Speed up tripper.dataset.save_data() #337

Open
jesper-friis opened this issue Feb 19, 2025 · 0 comments
Open

Speed up tripper.dataset.save_data() #337

jesper-friis opened this issue Feb 19, 2025 · 0 comments

Comments

@jesper-friis
Copy link
Contributor

jesper-friis commented Feb 19, 2025

The tripper.dataset.save_data() creates a json-ld string that is sent to rdflib.Graph.parse(format="json-ld") for each documented resource. This is very slow for when documenting many resources.

This can probably be speeded up a lot if we documents all the resources in a single json-ld and only calls rdflib.Graph.parse(format="json-ld") once. The json-ld document could use the "@graph" keyword like this:

{
  "@context": "...",
  "@graph: {
    "iri_for_dataset1": {...},
    "iri_for_dataset2": {...},
    ...
  }
}
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

1 participant