SciCatProject / SciCatProject/backend
Add field for capturing dataset links
@dylanmcreynolds is already working on this.
Since Aug 25, 2023.
- Dominant language
- TypeScript
- Stars
- 27
- Forks
- 37
- Avg merge
- 17h 32m
- Merged PRs (30d)
- 38
Description
Background
SciCat allows users to add thumbnails (stored in mongo) with each data set that is ingested. This allows facilities to provide some very rudimentary visualization alongside datasets.
There is also a "Jupyter" button on datasets that can only be configured to take the user to a particular Jupyter(Hub) instance. This cannot be coded to take users to a particular notebook, nor is there a method to associate a notebook with a particular dataset once opened.
We get a lot of requests from users and researchers to provide a variety of different types of web-based tools that related directly to datasets. These can be pages that display visualization, pages that provide analysis tools (including AI/ML) and jupyter notebooks on particular JupyterHub instance. In all cases, we would want to take the user to the page with the dataset in context.
Proposal
I can imagine a lot of solutions in SciCat. We could start maintaining visualizations on a technique/instrument basis within SciCat, but the wide variety of instruments, techniques and tools used across the Scicat facilities makes this a truly daunting task.
Instead, I propose moving the task of creating links for datasets ingestors. I proposed adding a new field to the dataset models (raw and derived) called links. This would be a list of link object that contain urls, display and type, something like:
"links": [
{"type": "analysis", "display": "Reconstruction Notebook", "link": "http://magrathea.org/jupyter/a/b/c/notebook.ipynb?scicat_dataset=abc123"},
{"type": "visualization", "display": "Raw Data Visualization", "link": "http://magrathea.org/planet_viz?scicat_dataset=abc123"},
{"type": "segmentation", "display": "Fjord Segmentation Application", "link": "http://magrathea.org/fjord_seg?scicat_dataset=abc123"},
]
The frontend could then display these items as href links. We might even think about adding another optional embed field to each link that lets the frontend decide wether to embed the web page in an iframe tag so that the visitation opens when you view the dataset.
If this were approved by the community, I could put it into the backend now, then follow up with a PR to the front end to display the links.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.