This DS Wizard repository contains set-up and related stuff for Biohackathon Europe 2019
Requirements: docker and docker-compose
- Just simply run
docker-compose up -d
- Open http://localhost:8080 in your favorite web-browser.
- Login as [email protected] with password password.
- Go to Knowledge Models and import them from file(s) that are located in
knowledge-models
folder of this repository - Explore DS Wizard and start with hacking!
For more information, visit the DSW documentation.
- Investigate
dsw:integrations:1.0.0
knowledge model in the DS Wizard:
- In Knowledge Models, view details of the Integration examples KM (knowledge model).
- Press Create KM Editor and name your customization of the KM.
- Using Preview, read the descriptions and try out the questions.
- Back in Knowledge Model view, tak a look at integration settings for FAIRsharing, Bio.tools, and TeSS.
- Then also take a look at the questions inside chapters in the KM.
- Select some API that you want to integrate and investigate it. The API should provide some search-based listing of items suitable as answer to certain question. Example: ORCID API for question to select certain members of a project.
- Once you know how to work with API to get the list (you can try it out using curl or Postman), create a new integration in the KM. Name it appropriately to the integrated service and fill the settings for integration.
- Create a new chapter named also using name of the integrated service. Then in the Text field of the chapter, describe the service and its API integration in detail (similarly to the examples). Use Markdown syntax for the description.
- Create a question in the chapter to demonstrate your API integration and test it out.
- When you are done, you can release a new version of the KM using Publish.
- Prepare a KM for which you want to create a DMP template.
- Investigate contents of
dmp-templates
folder:
common.json
is the metadata file for Common DSW Template and referencescommon/root.html.j2
.common/root.html.j2
is the template file for rendering answered questionnaire into a HTML document (that can be then transformed into DOCX, LaTeX, PDF, and other formats). It uses Jinja templating markup, more concretely its implementation Ginger for Haskell.common/root.css
is the cascade stylesheet used incommon/root.html.j2
(usinginclude
directive).
- Start a simple template by creating your
<template-name>.json
file that will reference your<template-name>.html.j2
template, where you can prepare the layout for now. - In the DS Wizard, create a questionnaire for your KM and export it. Pick your template, HTML format, and instead of pressing Download use right mouse button any copy the link of that button.
- Open a new tab in the browser and paste the link (should be something like
http://localhost:3000/questionnaires/e99406e2-9116-45f6-93fb-b7668bda4c83/dmp?format=**html**&templateUuid=43a3fdd1-8535-42e0-81a7-5edbff296e65
). Change the format parameter fromhtml
tohtml-preview
(e.g.http://localhost:3000/questionnaires/e99406e2-9116-45f6-93fb-b7668bda4c83/dmp?format=**html-preview**&templateUuid=43a3fdd1-8535-42e0-81a7-5edbff296e65
) and press Enter. - Now you should see the DMP document in the browser instead of downloading it. It is "live" - you can edit your
<template-name>.html.j2
file, save it, refresh the tab in your browser and it will show the new content. You do not have to restart the DSW nor to close the tab. - Work iteratively on the template to display what you need. For investigating provided structures, you can print them out into some
<pre>
or take a look in our documentation.
TIP: You can use prepared Hackathon Explanatory Template to explore what data are provided to the template. Exploration can be both in the Wizard and also in dmp-templates/explanatory.html.j2
.
You can change the configurations in the config
folder. For example, you can change the color to your favorite or edit the welcome message/warning.
This project (excluding knowledge models) is licensed under the MIT License - see the LICENSE file for more details.