From 9023a4a03eded8b1e281d390eac551287033f4e9 Mon Sep 17 00:00:00 2001
From: Xiao Gui <xgui3783@gmail.com>
Date: Wed, 8 Jan 2020 10:22:38 +0100
Subject: [PATCH] chore: user documentation for dataset fetching feat: new
 fetch dataset api breaking

---
 deploy/datasets/index.js                      |  29 +--
 deploy/datasets/supplements/commonSense.js    |   9 +-
 .../datasets/supplements/commonSense.spec.js  |  66 ++++++
 deploy/datasets/testData/bigbrain.js          | 141 ++++++++++++
 deploy/datasets/testData/colin27.js           | 113 ++++++++++
 deploy/datasets/testData/humanReceptor.js     | 115 ++++++++++
 deploy/datasets/testData/mni152.js            | 113 ++++++++++
 deploy/datasets/util.js                       | 145 ++++++++----
 deploy/datasets/util.spec.js                  |  48 +++-
 docs/advanced/datasets.md                     | 212 ++++++++++++++++++
 docs/releases/v2.1.0.md                       |   1 +
 mkdocs.yml                                    |   2 +
 12 files changed, 930 insertions(+), 64 deletions(-)
 create mode 100644 deploy/datasets/supplements/commonSense.spec.js
 create mode 100644 deploy/datasets/testData/bigbrain.js
 create mode 100644 deploy/datasets/testData/colin27.js
 create mode 100644 deploy/datasets/testData/humanReceptor.js
 create mode 100644 deploy/datasets/testData/mni152.js
 create mode 100644 docs/advanced/datasets.md

diff --git a/deploy/datasets/index.js b/deploy/datasets/index.js
index 3f58252f7..c29683d14 100644
--- a/deploy/datasets/index.js
+++ b/deploy/datasets/index.js
@@ -52,10 +52,11 @@ datasetsRouter.get('/tos', cacheMaxAge24Hr, async (req, res) => {
 
 datasetsRouter.use('/spatialSearch', noCacheMiddleWare, require('./spatialRouter'))
 
-datasetsRouter.get('/templateName/:templateName', noCacheMiddleWare, (req, res, next) => {
-  const { templateName } = req.params
+datasetsRouter.get('/templateNameParcellationName/:templateName/:parcellationName', noCacheMiddleWare, (req, res, next) => {
+  const { templateName, parcellationName } = req.params
+  
   const { user } = req
-  getDatasets({ templateName, user })
+  getDatasets({ templateName, parcellationName, user })
     .then(ds => {
       res.status(200).json(ds)
     })
@@ -68,21 +69,13 @@ datasetsRouter.get('/templateName/:templateName', noCacheMiddleWare, (req, res,
     })
 })
 
-datasetsRouter.get('/parcellationName/:parcellationName', noCacheMiddleWare, (req, res, next) => {
-  const { parcellationName } = req.params
-  const { user } = req
-  getDatasets({ parcellationName, user })
-    .then(ds => {
-      res.status(200).json(ds)
-    })
-    .catch(error => {
-      next({
-        code: 500,
-        error,
-        trace: 'parcellationName'
-      })
-    })
-})
+const deprecatedNotice = (_req, res) => {
+  res.status(400).send(`querying datasets with /templateName or /parcellationName separately have been deprecated. Please use /templateNameParcellationName/:templateName/:parcellationName instead`)
+}
+
+datasetsRouter.get('/templateName/:templateName', deprecatedNotice)
+
+datasetsRouter.get('/parcellationName/:parcellationName', deprecatedNotice)
 
 /**
  * It appears that query param are not 
diff --git a/deploy/datasets/supplements/commonSense.js b/deploy/datasets/supplements/commonSense.js
index 2d1116a34..a7673e935 100644
--- a/deploy/datasets/supplements/commonSense.js
+++ b/deploy/datasets/supplements/commonSense.js
@@ -50,7 +50,7 @@ const queryIsHuman = ({ templateName, parcellationName }) =>
   (templateName && humanTemplateSet.has(templateName))
   || (parcellationName && humanParcellationSet.has(parcellationName))
 
-exports.getCommonSenseDsFilter = ({ templateName, parcellationName }) => {
+const getCommonSenseDsFilter = ({ templateName, parcellationName }) => {
   const trueFilter = queryIsHuman({ templateName, parcellationName })
     ? dsIsHuman
     : queryIsMouse({ templateName, parcellationName })
@@ -61,3 +61,10 @@ exports.getCommonSenseDsFilter = ({ templateName, parcellationName }) => {
 
   return ds => trueFilter && trueFilter({ ds })
 }
+
+module.exports = {
+  getCommonSenseDsFilter,
+  dsIsHuman,
+  dsIsRat,
+  dsIsMouse
+}
\ No newline at end of file
diff --git a/deploy/datasets/supplements/commonSense.spec.js b/deploy/datasets/supplements/commonSense.spec.js
new file mode 100644
index 000000000..8412f28c8
--- /dev/null
+++ b/deploy/datasets/supplements/commonSense.spec.js
@@ -0,0 +1,66 @@
+const { 
+  getCommonSenseDsFilter,
+  dsIsHuman,
+  dsIsRat,
+  dsIsMouse
+} = require('./commonSense')
+
+const { expect } = require('chai')
+
+const bigbrain = require('../testData/bigbrain')
+const waxholmv2 = require('../testData/waxholmv2')
+const allen2015 = require('../testData/allen2015')
+
+describe('commonSense.js', () => {
+  describe('dsIsRat', () => {
+
+    it('filters bigbrain datasets properly', () => {
+      for (const ds of bigbrain){
+        const isHuman = dsIsRat({ ds })
+        expect(isHuman).to.be.false
+      }
+    })
+  })
+
+  describe('dsIsMouse', () => {
+
+    it('filters bigbrain datasets properly', () => {
+      for (const ds of bigbrain){
+        const isHuman = dsIsMouse({ ds })
+        expect(isHuman).to.be.false
+      }
+    })
+  })
+
+  describe('dsIsHuman', () => {
+    it('filters bigbrain datasets properly', () => {
+
+      for (const ds of bigbrain){
+        const isHuman = dsIsHuman({ ds })
+        expect(isHuman).to.be.true
+      }
+    })
+
+    it('filters waxholm v2 data properly', () => {
+      
+      for (const ds of waxholmv2){
+        const isHuman = dsIsHuman({ ds })
+        expect(isHuman).to.be.false
+      }
+    })
+
+    it('filters allen data properly', () => {
+
+      for (const ds of allen2015){
+        const isHuman = dsIsHuman({ ds })
+        expect(isHuman).to.be.false
+      }
+      
+    })
+  })
+
+  describe('getCommonSenseDsFilter', () => {
+    // TODO
+  })
+  
+})
\ No newline at end of file
diff --git a/deploy/datasets/testData/bigbrain.js b/deploy/datasets/testData/bigbrain.js
new file mode 100644
index 000000000..66156fbfb
--- /dev/null
+++ b/deploy/datasets/testData/bigbrain.js
@@ -0,0 +1,141 @@
+module.exports = [
+  {
+    "formats": [],
+    "datasetDOI": [
+      {
+        "cite": "Schleicher, A., Amunts, K., Geyer, S., Morosan, P., & Zilles, K. (1999). Observer-Independent Method for Microstructural Parcellation of Cerebral Cortex: A Quantitative Approach to Cytoarchitectonics. NeuroImage, 9(1), 165–177. ",
+        "doi": "10.1006/nimg.1998.0385"
+      },
+      {
+        "cite": "Spitzer, H., Kiwitz, K., Amunts, K., Harmeling, S., Dickscheid, T. (2018). Improving Cytoarchitectonic Segmentation of Human Brain Areas with Self-supervised Siamese Networks. In: Frangi A., Schnabel J., Davatzikos C., Alberola-López C., Fichtinger G. (eds) Medical Image Computing and Computer Assisted Intervention – MICCAI 2018. MICCAI 2018. Lecture Notes in Computer Science, vol 11072. Springer, Cham.",
+        "doi": "10.1007/978-3-030-00931-1_76"
+      },
+      {
+        "cite": "Spitzer, H., Amunts, K., Harmeling, S., and Dickscheid, T. (2017). Parcellation of visual cortex on high-resolution histological brain sections using convolutional neural networks, in 2017 IEEE 14th International Symposium on Biomedical Imaging (ISBI 2017), pp. 920–923.",
+        "doi": "10.1109/ISBI.2017.7950666"
+      },
+      {
+        "cite": "Amunts, K., Lepage, C., Borgeat, L., Mohlberg, H., Dickscheid, T., Rousseau, M. -E., Bludau, S., Bazin, P. -L., Lewis, L. B., Oros-Peusquens, A.-M., Shah, N. J., Lippert, T., Zilles, K., Evans, A. C. (2013).  BigBrain: An Ultrahigh-Resolution 3D Human Brain Model. Science, 340(6139),1472-5.",
+        "doi": "10.1126/science.1235381"
+      }
+    ],
+    "activity": [
+      {
+        "protocols": [
+          "imaging"
+        ],
+        "preparation": [
+          "Ex vivo"
+        ]
+      },
+      {
+        "protocols": [
+          "histology"
+        ],
+        "preparation": [
+          "Ex vivo"
+        ]
+      },
+      {
+        "protocols": [
+          "brain mapping"
+        ],
+        "preparation": [
+          "Ex vivo"
+        ]
+      },
+      {
+        "protocols": [
+          "analysis technique"
+        ],
+        "preparation": [
+          "Ex vivo"
+        ]
+      }
+    ],
+    "referenceSpaces": [
+      {
+        "name": "BigBrain",
+        "fullId": "https://nexus.humanbrainproject.org/v0/data/minds/core/referencespace/v1.0.0/a1655b99-82f1-420f-a3c2-fe80fd4c8588"
+      }
+    ],
+    "methods": [
+      "magnetic resonance imaging (MRI)",
+      "silver staining",
+      "cytoarchitectonic mapping",
+      "Deep-Learning based cytoarchitectonic mapping"
+    ],
+    "custodians": [
+      "Amunts, Katrin"
+    ],
+    "project": [
+      "Ultrahigh resolution 3D maps of cytoarchitectonic areas in the Big Brain model"
+    ],
+    "description": "This dataset contains automatically created cytoarchitectonic maps of Area hOc1 (V1, 17, CalcS) in the BigBrain dataset [Amunts et al. 2013]. The mappings were created using Deep Convolutional Neural networks based on the idea presented in Spitzer et al. 2017 and Spitzer et al. 2018, which were trained on delineations on every 120th section created using the semi-automatic method presented in Schleicher et al. 1999. Mappings are available on every section. Their quality was observed by a trained neuroscientist to exclude sections with low quality results from further processing. Automatic mappings were then transformed to the 3D reconstructed BigBrain space using transformations used in Amunts et al. 2013, which were provided by Claude Lepage (McGill). Individual sections were used to assemble a 3D volume of the area, low quality results were replaced by interpolations between nearest neighboring sections. The volume was then smoothed using an 11³ median filter and largest connected components were identified to remove false positive results of the classification algorithm.\nThe dataset consists of a single HDF5 file containing the volume in RAS dimension ordering and 20 micron isotropic resolution in the dataset “volume” and affine transformation matrix in the dataset “affine”. An additional dataset “interpolation_info” contains a vector with an integer value for each section which indicates if a section was interpolated due to low quality results (value 2) or not (value 1).\nDue to the large size of the volume, it’s recommended to view the data online using the provided viewer link.\n",
+    "parcellationAtlas": [
+      {
+        "name": "Jülich Cytoarchitechtonic Brain Atlas (human)",
+        "fullId": "https://nexus.humanbrainproject.org/v0/data/minds/core/parcellationatlas/v1.0.0/94c1125b-b87e-45e4-901c-00daee7f2579",
+        "id": [
+          "deec923ec31a82f89a9c7c76a6fefd6b",
+          "e2d45e028b6da0f6d9fdb9491a4de80a"
+        ]
+      }
+    ],
+    "licenseInfo": [
+      {
+        "name": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International",
+        "url": "https://creativecommons.org/licenses/by-nc-sa/4.0/"
+      }
+    ],
+    "embargoStatus": [
+      "Free"
+    ],
+    "license": [],
+    "parcellationRegion": [
+      {
+        "species": [],
+        "name": "Area hOc1 (V1, 17, CalcS)",
+        "alias": null
+      }
+    ],
+    "species": [
+      "Homo sapiens"
+    ],
+    "name": "Ultrahigh resolution 3D cytoarchitectonic map of Area hOc1 (V1, 17, CalcS) created by a Deep-Learning assisted workflow",
+    "files": [],
+    "fullId": "https://nexus.humanbrainproject.org/v0/data/minds/core/dataset/v1.0.0/696d6062-3b86-498f-9ca6-e4d67b433396",
+    "contributors": [
+      "Dickscheid, Timo",
+      "Amunts, Katrin",
+      "Kiwitz, Kai",
+      "Schiffer, Christian "
+    ],
+    "id": "696d6062-3b86-498f-9ca6-e4d67b433396",
+    "kgReference": [
+      "10.25493/DGEZ-Q93"
+    ],
+    "publications": [
+      {
+        "name": "Observer-Independent Method for Microstructural Parcellation of Cerebral Cortex: A Quantitative Approach to Cytoarchitectonics",
+        "cite": "Schleicher, A., Amunts, K., Geyer, S., Morosan, P., & Zilles, K. (1999). Observer-Independent Method for Microstructural Parcellation of Cerebral Cortex: A Quantitative Approach to Cytoarchitectonics. NeuroImage, 9(1), 165–177. ",
+        "doi": "10.1006/nimg.1998.0385"
+      },
+      {
+        "name": "Improving Cytoarchitectonic Segmentation of Human Brain Areas with Self-supervised Siamese Networks",
+        "cite": "Spitzer, H., Kiwitz, K., Amunts, K., Harmeling, S., Dickscheid, T. (2018). Improving Cytoarchitectonic Segmentation of Human Brain Areas with Self-supervised Siamese Networks. In: Frangi A., Schnabel J., Davatzikos C., Alberola-López C., Fichtinger G. (eds) Medical Image Computing and Computer Assisted Intervention – MICCAI 2018. MICCAI 2018. Lecture Notes in Computer Science, vol 11072. Springer, Cham.",
+        "doi": "10.1007/978-3-030-00931-1_76"
+      },
+      {
+        "name": "Parcellation of visual cortex on high-resolution histological brain sections using convolutional neural networks",
+        "cite": "Spitzer, H., Amunts, K., Harmeling, S., and Dickscheid, T. (2017). Parcellation of visual cortex on high-resolution histological brain sections using convolutional neural networks, in 2017 IEEE 14th International Symposium on Biomedical Imaging (ISBI 2017), pp. 920–923.",
+        "doi": "10.1109/ISBI.2017.7950666"
+      },
+      {
+        "name": "BigBrain: An Ultrahigh-Resolution 3D Human Brain Model",
+        "cite": "Amunts, K., Lepage, C., Borgeat, L., Mohlberg, H., Dickscheid, T., Rousseau, M. -E., Bludau, S., Bazin, P. -L., Lewis, L. B., Oros-Peusquens, A.-M., Shah, N. J., Lippert, T., Zilles, K., Evans, A. C. (2013).  BigBrain: An Ultrahigh-Resolution 3D Human Brain Model. Science, 340(6139),1472-5.",
+        "doi": "10.1126/science.1235381"
+      }
+    ]
+  }
+]
\ No newline at end of file
diff --git a/deploy/datasets/testData/colin27.js b/deploy/datasets/testData/colin27.js
new file mode 100644
index 000000000..b7f11f160
--- /dev/null
+++ b/deploy/datasets/testData/colin27.js
@@ -0,0 +1,113 @@
+module.exports = [
+  {
+    "formats": [
+      "NIFTI"
+    ],
+    "datasetDOI": [
+      {
+        "cite": "Amunts, K., Malikovic, A., Mohlberg, H., Schormann, T., & Zilles, K. (2000). Brodmann’s Areas 17 and 18 Brought into Stereotaxic Space—Where and How Variable? NeuroImage, 11(1), 66–84. ",
+        "doi": "10.1006/nimg.1999.0516"
+      }
+    ],
+    "activity": [
+      {
+        "protocols": [
+          "histology"
+        ],
+        "preparation": [
+          "Ex vivo"
+        ]
+      },
+      {
+        "protocols": [
+          "imaging"
+        ],
+        "preparation": [
+          "Ex vivo"
+        ]
+      },
+      {
+        "protocols": [
+          "brain mapping"
+        ],
+        "preparation": [
+          "Ex vivo"
+        ]
+      }
+    ],
+    "referenceSpaces": [
+      {
+        "name": null,
+        "fullId": "https://nexus.humanbrainproject.org/v0/data/minds/core/referencespace/v1.0.0/dafcffc5-4826-4bf1-8ff6-46b8a31ff8e2"
+      },
+      {
+        "name": "MNI Colin 27",
+        "fullId": "https://nexus.humanbrainproject.org/v0/data/minds/core/referencespace/v1.0.0/7f39f7be-445b-47c0-9791-e971c0b6d992"
+      }
+    ],
+    "methods": [
+      "silver staining",
+      "magnetic resonance imaging (MRI)",
+      "probability mapping",
+      "cytoarchitectonic mapping"
+    ],
+    "custodians": [
+      "Amunts, Katrin"
+    ],
+    "project": [
+      "JuBrain: cytoarchitectonic probabilistic maps of the human brain"
+    ],
+    "description": "This dataset contains the distinct architectonic Area hOc1 (V1, 17, CalcS) in the individual, single subject template of the MNI Colin 27 as well as the MNI ICBM 152 2009c nonlinear asymmetric reference space. As part of the JuBrain cytoarchitectonic atlas, the area was identified using cytoarchitectonic analysis on cell-body-stained histological sections of 10 human postmortem brains obtained from the body donor program of the University of Düsseldorf. The results of the cytoarchitectonic analysis were then mapped to both reference spaces, where each voxel was assigned the probability to belong to Area hOc1 (V1, 17, CalcS). The probability map of Area hOc1 (V1, 17, CalcS) are provided in the NifTi format for each brain reference space and hemisphere. The JuBrain atlas relies on a modular, flexible and adaptive framework containing workflows to create the probabilistic brain maps for these structures. Note that methodological improvements and integration of new brain structures may lead to small deviations in earlier released datasets.",
+    "parcellationAtlas": [
+      {
+        "name": "Jülich Cytoarchitechtonic Brain Atlas (human)",
+        "fullId": "https://nexus.humanbrainproject.org/v0/data/minds/core/parcellationatlas/v1.0.0/94c1125b-b87e-45e4-901c-00daee7f2579",
+        "id": [
+          "deec923ec31a82f89a9c7c76a6fefd6b",
+          "e2d45e028b6da0f6d9fdb9491a4de80a"
+        ]
+      }
+    ],
+    "licenseInfo": [
+      {
+        "name": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International",
+        "url": "https://creativecommons.org/licenses/by-nc-sa/4.0/"
+      }
+    ],
+    "embargoStatus": [
+      "Free"
+    ],
+    "license": [],
+    "parcellationRegion": [
+      {
+        "species": [],
+        "name": "Area hOc1 (V1, 17, CalcS)",
+        "alias": null
+      }
+    ],
+    "species": [
+      "Homo sapiens"
+    ],
+    "name": "Probabilistic cytoarchitectonic map of Area hOc1 (V1, 17, CalcS) (v2.4)",
+    "files": [],
+    "fullId": "https://nexus.humanbrainproject.org/v0/data/minds/core/dataset/v1.0.0/5c669b77-c981-424a-858d-fe9f527dbc07",
+    "contributors": [
+      "Zilles, Karl",
+      "Schormann, Thorsten",
+      "Mohlberg, Hartmut",
+      "Malikovic, Aleksandar",
+      "Amunts, Katrin"
+    ],
+    "id": "5c669b77-c981-424a-858d-fe9f527dbc07",
+    "kgReference": [
+      "10.25493/MXJ6-6DH"
+    ],
+    "publications": [
+      {
+        "name": "Brodmann's Areas 17 and 18 Brought into Stereotaxic Space—Where and How Variable?",
+        "cite": "Amunts, K., Malikovic, A., Mohlberg, H., Schormann, T., & Zilles, K. (2000). Brodmann’s Areas 17 and 18 Brought into Stereotaxic Space—Where and How Variable? NeuroImage, 11(1), 66–84. ",
+        "doi": "10.1006/nimg.1999.0516"
+      }
+    ]
+  }
+]
\ No newline at end of file
diff --git a/deploy/datasets/testData/humanReceptor.js b/deploy/datasets/testData/humanReceptor.js
new file mode 100644
index 000000000..6a0c2c2f5
--- /dev/null
+++ b/deploy/datasets/testData/humanReceptor.js
@@ -0,0 +1,115 @@
+module.exports = [
+  {
+    "formats": [
+      "xlsx, tif, txt"
+    ],
+    "datasetDOI": [
+      {
+        "cite": "Eickhoff, S. B., Schleicher, A., Scheperjans, F., Palomero-Gallagher, N., & Zilles, K. (2007). Analysis of neurotransmitter receptor distribution patterns in the cerebral cortex. NeuroImage, 34(4), 1317–1330. ",
+        "doi": "10.1016/j.neuroimage.2006.11.016"
+      },
+      {
+        "cite": "Zilles, K., Bacha-Trams, M., Palomero-Gallagher, N., Amunts, K., & Friederici, A. D. (2015). Common molecular basis of the sentence comprehension network revealed by neurotransmitter receptor fingerprints. Cortex, 63, 79–89. ",
+        "doi": "10.1016/j.cortex.2014.07.007"
+      }
+    ],
+    "activity": [
+      {
+        "protocols": [
+          "brain mapping"
+        ],
+        "preparation": [
+          "Ex vivo"
+        ]
+      },
+      {
+        "protocols": [
+          "histology"
+        ],
+        "preparation": [
+          "Ex vivo"
+        ]
+      }
+    ],
+    "referenceSpaces": [],
+    "methods": [
+      "receptor autoradiography plot",
+      "receptor density fingerprint analysis",
+      "receptor density profile analysis",
+      "autoradiography with [³H] SCH23390",
+      "autoradiography with [³H] ketanserin",
+      "autoradiography with [³H] 8-OH-DPAT",
+      "autoradiography with [³H] UK-14,304",
+      "autoradiography with [³H] epibatidine",
+      "autoradiography with [³H] 4-DAMP",
+      "autoradiography with [³H] oxotremorine-M",
+      "autoradiography with [³H] flumazenil",
+      "autoradiography with [³H] CGP 54626",
+      "autoradiography with [³H] prazosin",
+      "autoradiography with [³H] muscimol",
+      "autoradiography with [³H]LY 341 495",
+      "autoradiography with [³H] pirenzepine",
+      "autoradiography with [³H] MK-801",
+      "autoradiography with [³H] kainate",
+      "autoradiography with [³H] AMPA"
+    ],
+    "custodians": [
+      "Palomero-Gallagher, Nicola",
+      "Zilles, Karl"
+    ],
+    "project": [
+      "Quantitative Receptor data"
+    ],
+    "description": "This dataset contains the densities (in fmol/mg protein) of 16 receptors for classical neurotransmitters in Area hOc1 using quantitative in vitro autoradiography. The receptor density measurements can be provided in three ways: (fp) as density fingerprints (average across samples; mean density and standard deviation for each of the 16 receptors), (pr) as laminar density profiles (exemplary data from one sample; average course of the density from the pial surface to the border between layer VI and the white matter for each receptor), and (ar) as color-coded autoradiographs (exemplary data from one sample; laminar density distribution patterns for each receptor labeling). \nThis dataset contains the following receptor density measurements based on the labeling of these receptor binding sites: \n\nAMPA (glutamate; labelled with [³H]AMPA): fp, pr, ar\n\nkainate (glutamate; [³H]kainate): fp, pr, ar\n\nNMDA (glutamate; [³H]MK-801): fp, pr, ar\n\nmGluR2/3 (glutamate; [³H] LY 341 495): pr, ar\n\nGABA<sub>A</sub> (GABA; [³H]muscimol): fp, pr, ar\n\nGABA<sub>B</sub> (GABA; [³H] CGP54626): fp, pr, ar\n\nGABA<sub>A</sub> associated benzodiazepine binding sites (BZ; [³H]flumazenil): fp, pr, ar\n\nmuscarinic M₁ (acetylcholine; [³H]pirenzepine): fp, pr, ar\n\nmuscarinic M₂ (acetylcholine; [³H]oxotremorine-M): fp, pr, ar\n\nmuscarinic M₃ (acetylcholine; [³H]4-DAMP): fp, pr, ar\n\nnicotinic α₄β₂ (acetylcholine; [³H]epibatidine): fp, pr, ar\n\nα₁ (noradrenalin; [³H]prazosin): fp, pr, ar\n\nα₂ (noradrenalin; [³H]UK-14,304): fp, pr, ar\n\n5-HT₁<sub>A</sub> (serotonin; [³H]8-OH-DPAT): fp, pr, ar\n\n5-HT₂ (serotonin; [³H]ketanserin): fp, pr, ar\n\nD₁ (dopamine; [³H]SCH23390): fp, pr, ar\n\nWhich sample was used for which receptor density measurement is stated in metadata files accompanying the main data repository. For methodological details, see Zilles et al. (2002), and in Palomero-Gallagher and Zilles (2018).\n\nZilles, K. et al. (2002). Quantitative analysis of cyto- and receptorarchitecture of the human brain, pp. 573-602. In: Brain Mapping: The Methods, 2nd edition (A.W. Toga and J.C. Mazziotta, eds.). San Diego, Academic Press.\n\nPalomero-Gallagher N, Zilles K. (2018) Cyto- and receptorarchitectonic mapping of the human brain. In: Handbook of Clinical Neurology 150: 355-387",
+    "parcellationAtlas": [],
+    "licenseInfo": [
+      {
+        "name": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International",
+        "url": "https://creativecommons.org/licenses/by-nc-sa/4.0/"
+      }
+    ],
+    "embargoStatus": [
+      "Free"
+    ],
+    "license": [],
+    "parcellationRegion": [
+      {
+        "species": [],
+        "name": "Area hOc1",
+        "alias": null
+      }
+    ],
+    "species": [
+      "Homo sapiens"
+    ],
+    "name": "Density measurements of different receptors for Area hOc1",
+    "files": [],
+    "fullId": "https://nexus.humanbrainproject.org/v0/data/minds/core/dataset/v1.0.0/e715e1f7-2079-45c4-a67f-f76b102acfce",
+    "contributors": [
+      "Scheperjans, Filip",
+      "Schleicher, Axel",
+      "Eickhoff, Simon B.",
+      "Friederici, Angela D.",
+      "Amunts, Katrin",
+      "Palomero-Gallagher, Nicola",
+      "Bacha-Trams, Maraike",
+      "Zilles, Karl"
+    ],
+    "id": "0616d1e97b8be75de526bc265d9af540",
+    "kgReference": [
+      "10.25493/P8SD-JMH"
+    ],
+    "publications": [
+      {
+        "name": "Analysis of neurotransmitter receptor distribution patterns in the cerebral cortex",
+        "cite": "Eickhoff, S. B., Schleicher, A., Scheperjans, F., Palomero-Gallagher, N., & Zilles, K. (2007). Analysis of neurotransmitter receptor distribution patterns in the cerebral cortex. NeuroImage, 34(4), 1317–1330. ",
+        "doi": "10.1016/j.neuroimage.2006.11.016"
+      },
+      {
+        "name": "Common molecular basis of the sentence comprehension network revealed by neurotransmitter receptor fingerprints",
+        "cite": "Zilles, K., Bacha-Trams, M., Palomero-Gallagher, N., Amunts, K., & Friederici, A. D. (2015). Common molecular basis of the sentence comprehension network revealed by neurotransmitter receptor fingerprints. Cortex, 63, 79–89. ",
+        "doi": "10.1016/j.cortex.2014.07.007"
+      }
+    ]
+  }
+]
\ No newline at end of file
diff --git a/deploy/datasets/testData/mni152.js b/deploy/datasets/testData/mni152.js
new file mode 100644
index 000000000..b7f11f160
--- /dev/null
+++ b/deploy/datasets/testData/mni152.js
@@ -0,0 +1,113 @@
+module.exports = [
+  {
+    "formats": [
+      "NIFTI"
+    ],
+    "datasetDOI": [
+      {
+        "cite": "Amunts, K., Malikovic, A., Mohlberg, H., Schormann, T., & Zilles, K. (2000). Brodmann’s Areas 17 and 18 Brought into Stereotaxic Space—Where and How Variable? NeuroImage, 11(1), 66–84. ",
+        "doi": "10.1006/nimg.1999.0516"
+      }
+    ],
+    "activity": [
+      {
+        "protocols": [
+          "histology"
+        ],
+        "preparation": [
+          "Ex vivo"
+        ]
+      },
+      {
+        "protocols": [
+          "imaging"
+        ],
+        "preparation": [
+          "Ex vivo"
+        ]
+      },
+      {
+        "protocols": [
+          "brain mapping"
+        ],
+        "preparation": [
+          "Ex vivo"
+        ]
+      }
+    ],
+    "referenceSpaces": [
+      {
+        "name": null,
+        "fullId": "https://nexus.humanbrainproject.org/v0/data/minds/core/referencespace/v1.0.0/dafcffc5-4826-4bf1-8ff6-46b8a31ff8e2"
+      },
+      {
+        "name": "MNI Colin 27",
+        "fullId": "https://nexus.humanbrainproject.org/v0/data/minds/core/referencespace/v1.0.0/7f39f7be-445b-47c0-9791-e971c0b6d992"
+      }
+    ],
+    "methods": [
+      "silver staining",
+      "magnetic resonance imaging (MRI)",
+      "probability mapping",
+      "cytoarchitectonic mapping"
+    ],
+    "custodians": [
+      "Amunts, Katrin"
+    ],
+    "project": [
+      "JuBrain: cytoarchitectonic probabilistic maps of the human brain"
+    ],
+    "description": "This dataset contains the distinct architectonic Area hOc1 (V1, 17, CalcS) in the individual, single subject template of the MNI Colin 27 as well as the MNI ICBM 152 2009c nonlinear asymmetric reference space. As part of the JuBrain cytoarchitectonic atlas, the area was identified using cytoarchitectonic analysis on cell-body-stained histological sections of 10 human postmortem brains obtained from the body donor program of the University of Düsseldorf. The results of the cytoarchitectonic analysis were then mapped to both reference spaces, where each voxel was assigned the probability to belong to Area hOc1 (V1, 17, CalcS). The probability map of Area hOc1 (V1, 17, CalcS) are provided in the NifTi format for each brain reference space and hemisphere. The JuBrain atlas relies on a modular, flexible and adaptive framework containing workflows to create the probabilistic brain maps for these structures. Note that methodological improvements and integration of new brain structures may lead to small deviations in earlier released datasets.",
+    "parcellationAtlas": [
+      {
+        "name": "Jülich Cytoarchitechtonic Brain Atlas (human)",
+        "fullId": "https://nexus.humanbrainproject.org/v0/data/minds/core/parcellationatlas/v1.0.0/94c1125b-b87e-45e4-901c-00daee7f2579",
+        "id": [
+          "deec923ec31a82f89a9c7c76a6fefd6b",
+          "e2d45e028b6da0f6d9fdb9491a4de80a"
+        ]
+      }
+    ],
+    "licenseInfo": [
+      {
+        "name": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International",
+        "url": "https://creativecommons.org/licenses/by-nc-sa/4.0/"
+      }
+    ],
+    "embargoStatus": [
+      "Free"
+    ],
+    "license": [],
+    "parcellationRegion": [
+      {
+        "species": [],
+        "name": "Area hOc1 (V1, 17, CalcS)",
+        "alias": null
+      }
+    ],
+    "species": [
+      "Homo sapiens"
+    ],
+    "name": "Probabilistic cytoarchitectonic map of Area hOc1 (V1, 17, CalcS) (v2.4)",
+    "files": [],
+    "fullId": "https://nexus.humanbrainproject.org/v0/data/minds/core/dataset/v1.0.0/5c669b77-c981-424a-858d-fe9f527dbc07",
+    "contributors": [
+      "Zilles, Karl",
+      "Schormann, Thorsten",
+      "Mohlberg, Hartmut",
+      "Malikovic, Aleksandar",
+      "Amunts, Katrin"
+    ],
+    "id": "5c669b77-c981-424a-858d-fe9f527dbc07",
+    "kgReference": [
+      "10.25493/MXJ6-6DH"
+    ],
+    "publications": [
+      {
+        "name": "Brodmann's Areas 17 and 18 Brought into Stereotaxic Space—Where and How Variable?",
+        "cite": "Amunts, K., Malikovic, A., Mohlberg, H., Schormann, T., & Zilles, K. (2000). Brodmann’s Areas 17 and 18 Brought into Stereotaxic Space—Where and How Variable? NeuroImage, 11(1), 66–84. ",
+        "doi": "10.1006/nimg.1999.0516"
+      }
+    ]
+  }
+]
\ No newline at end of file
diff --git a/deploy/datasets/util.js b/deploy/datasets/util.js
index 186eaa9ff..60897ff13 100644
--- a/deploy/datasets/util.js
+++ b/deploy/datasets/util.js
@@ -129,61 +129,117 @@ const datasetRegionExistsInParcellationRegion = async (prs, atlasPrSet = new Set
   return prs.some(({ name, alias }) => atlasPrSet.has(alias) || atlasPrSet.has(name))
 }
 
+const templateNameToIdMap = new Map([
+  ['Big Brain (Histology)', {
+    kg: {
+      kgId: 'a1655b99-82f1-420f-a3c2-fe80fd4c8588',
+      kgSchema: 'minds/core/referencespace/v1.0.0'
+    }
+  }],
+  ['MNI 152 ICBM 2009c Nonlinear Asymmetric', {
+    kg: {
+      kgId: 'dafcffc5-4826-4bf1-8ff6-46b8a31ff8e2',
+      kgSchema: 'minds/core/referencespace/v1.0.0'
+    }
+  }],
+  ['MNI Colin 27', {
+    kg: {
+      kgId: '7f39f7be-445b-47c0-9791-e971c0b6d992',
+      kgSchema: 'minds/core/referencespace/v1.0.0'
+    }
+  }]
+])
+
+const getKgId = ({ templateName }) => {
+  const out = templateNameToIdMap.get(templateName)
+  if (!out) return null
+  const { kg } = out
+  const { kgSchema, kgId } = kg
+  return `${kgSchema}/${kgId}`
+}
+
+
+/**
+ * NB: if changed, also change ~/docs/advanced/datasets.md
+ * @param { templateName } template to be queried 
+ */
+const datasetBelongsInTemplate = ({ templateName }) => ({ referenceSpaces }) => {
+  if (referenceSpaces.length === 0) return true
+  else return referenceSpaces.some(({ name, fullId }) =>
+    name === templateName
+    || fullId && fullId.includes(getKgId({ templateName })))
+}
+
+/**
+ * NB: if changed, also change ~/docs/advanced/dataset.md
+ * @param {parcellationName, dataset} param0 
+ */
 const datasetBelongToParcellation = ({ parcellationName = null, dataset = {parcellationAtlas: []} } = {}) => parcellationName === null || dataset.parcellationAtlas.length === 0
   ? true
   : (dataset.parcellationAtlas || []).some(({ name }) => name === parcellationName)
 
+/**
+ * NB: if changed, also change ~/docs/advanced/dataset.md
+ * @param {*} dataset 
+ * @param {*} param1 
+ */
 const filterDataset = async (dataset = null, { templateName, parcellationName }) => {
 
   if (/infant/.test(dataset.name)) return false
-  if (templateName) {
-    return dataset.referenceSpaces.some(rs => rs.name === templateName)
-  }
-  if (parcellationName) {
-    if (dataset.parcellationRegion.length === 0) return false
-
-    let useSet
-
-    // temporary measure
-    // TODO ask curaion team re name of jubrain atlas
-    let overwriteParcellationName
-    switch (parcellationName) {
-      case 'Cytoarchitectonic Maps':
-      case 'JuBrain Cytoarchitectonic Atlas': 
-        useSet = juBrainSet
-        overwriteParcellationName = 'Jülich Cytoarchitechtonic Brain Atlas (human)'
-        break;
-      case 'Fibre Bundle Atlas - Short Bundle':
-        useSet = shortBundleSet
-        break;
-      case 'Fibre Bundle Atlas - Long Bundle':
-        useSet = longBundleSet
-        break;
-      case 'Waxholm Space rat brain atlas v1':
-        useSet = waxholm1Set
-        break;
-      case 'Waxholm Space rat brain atlas v2':
-        useSet = waxholm2Set
-        break;
-      case 'Waxholm Space rat brain atlas v3':
-        useSet = waxholm3Set
-        break;
-      case 'Allen Mouse Common Coordinate Framework v3 2015':
-        useSet = allen2015Set
-        break;
-      case 'Allen Mouse Common Coordinate Framework v3 2017':
-        useSet = allen2017Set
-        break;
-      default:
-        useSet = new Set()
-    }
-    return datasetBelongToParcellation({ dataset, parcellationName: overwriteParcellationName || parcellationName })
-      && await datasetRegionExistsInParcellationRegion(dataset.parcellationRegion, useSet)
+  
+  // check if dataset belongs to template selected
+  const flagDatasetBelongToTemplate = datasetBelongsInTemplate({ templateName })(dataset)
+
+  // check that dataset belongs to template selected
+  
+  // if (dataset.parcellationRegion.length === 0) return false
+
+  let useSet
+
+  // temporary measure
+  // TODO ask curaion team re name of jubrain atlas
+  let overwriteParcellationName
+  switch (parcellationName) {
+    case 'Cytoarchitectonic Maps':
+    case 'JuBrain Cytoarchitectonic Atlas': 
+      useSet = juBrainSet
+      overwriteParcellationName = 'Jülich Cytoarchitechtonic Brain Atlas (human)'
+      break;
+    case 'Fibre Bundle Atlas - Short Bundle':
+      useSet = shortBundleSet
+      break;
+    case 'Fibre Bundle Atlas - Long Bundle':
+      useSet = longBundleSet
+      break;
+    case 'Waxholm Space rat brain atlas v1':
+      useSet = waxholm1Set
+      break;
+    case 'Waxholm Space rat brain atlas v2':
+      useSet = waxholm2Set
+      break;
+    case 'Waxholm Space rat brain atlas v3':
+      useSet = waxholm3Set
+      break;
+    case 'Allen Mouse Common Coordinate Framework v3 2015':
+      useSet = allen2015Set
+      break;
+    case 'Allen Mouse Common Coordinate Framework v3 2017':
+      useSet = allen2017Set
+      break;
+    default:
+      useSet = new Set()
   }
+  const flagDatasetBelongToParcellation =  datasetBelongToParcellation({ dataset, parcellationName: overwriteParcellationName || parcellationName })
+    && await datasetRegionExistsInParcellationRegion(dataset.parcellationRegion, useSet)
 
-  return false
+  return flagDatasetBelongToTemplate && flagDatasetBelongToParcellation
 }
 
+/**
+ * NB: if changed, also change ~/docs/advanced/dataset.md
+ * @param {*} datasets 
+ * @param {*} param1 
+ */
 const filterDatasets = async (datasets = [], { templateName, parcellationName }) => {
 
   // filter by commonsense first (species)
@@ -246,6 +302,7 @@ module.exports = {
   filterDatasets,
   datasetBelongToParcellation,
   datasetRegionExistsInParcellationRegion,
+  datasetBelongsInTemplate,
   _getParcellations: async () => {
     await Promise.all(initPrArray)
     return {
diff --git a/deploy/datasets/util.spec.js b/deploy/datasets/util.spec.js
index ce51f7f45..081c106c2 100644
--- a/deploy/datasets/util.spec.js
+++ b/deploy/datasets/util.spec.js
@@ -1,8 +1,12 @@
-const { retry, filterDatasets, datasetRegionExistsInParcellationRegion, _getParcellations } = require('./util')
+const { retry, datasetBelongsInTemplate, filterDatasets, datasetRegionExistsInParcellationRegion, _getParcellations } = require('./util')
 const { fake } = require('sinon')
 const { assert, expect } = require('chai')
 const waxholmv2 = require('./testData/waxholmv2')
 const allen2015 = require('./testData/allen2015')
+const bigbrain = require('./testData/bigbrain')
+const humanReceptor = require('./testData/humanReceptor')
+const mni152 = require('./testData/mni152')
+const colin27 = require('./testData/colin27')
 
 describe('datasets/util.js', () => {
 
@@ -47,6 +51,48 @@ describe('datasets/util.js', () => {
       }
     })
   })
+
+  describe('datasetBelongsInTemplate', () => {
+    it('should filter datasets with template defined', () => {
+      for (const ds of bigbrain) {
+
+        const belong = datasetBelongsInTemplate({ templateName: 'Big Brain (Histology)' })(ds)
+        expect(belong).to.be.true
+        
+      }
+      for (const ds of mni152) {
+
+        const belong = datasetBelongsInTemplate({ templateName: 'MNI 152 ICBM 2009c Nonlinear Asymmetric' })(ds)
+        expect(belong).to.be.true
+      }
+      for (const ds of colin27) {
+
+        const belong = datasetBelongsInTemplate({ templateName: 'MNI Colin 27' })(ds)
+        expect(belong).to.be.true
+      }
+    })
+
+    it('should include datasets without any reference space defined', () => {
+      for (const ds of humanReceptor) {
+
+        const belong = datasetBelongsInTemplate({ templateName: 'Big Brain (Histology)' })(ds)
+        expect(belong).to.be.true
+      }
+    })
+
+    it('should filter out referenceSpaces not in list', () => {
+      for (const ds of bigbrain) {
+
+        const belong = datasetBelongsInTemplate({ templateName: 'MNI 152 ICBM 2009c Nonlinear Asymmetric' })(ds)
+        expect(belong).to.be.false
+      }
+      for (const ds of mni152) {
+
+        const belong = datasetBelongsInTemplate({ templateName: 'Big Brain (Histology)' })(ds)
+        expect(belong).to.be.false
+      }
+    })
+  })
   
   describe('datasetRegionExistsInParcellationRegion', () => {
     it('should filter waxholm v2 properly', async () => {
diff --git a/docs/advanced/datasets.md b/docs/advanced/datasets.md
new file mode 100644
index 000000000..bd0d5fa5d
--- /dev/null
+++ b/docs/advanced/datasets.md
@@ -0,0 +1,212 @@
+# Fetching datasets from Knowledge Graph
+
+Human Brain Project Knowledge Graph is a metadata database consisting of datasets contributed by collaborators of the Human Brain Project and curated by human curoators in order to ensure the highest standards. 
+
+The interactive atlas viewer fetches the datasets relevant to the template space and parcellation atlas selected by the user using the following conditions:
+
+## Species
+
+The relevant species of datasets catalogued by Knowledge Graph are obtained from the following links:
+
+```json
+{
+  "fieldname": "query:species",
+  "relative_path": [
+    "https://schema.hbp.eu/minds/specimen_group",
+    "https://schema.hbp.eu/minds/subjects",
+    "https://schema.hbp.eu/minds/species",
+    "http://schema.org/name"
+  ]
+}
+```
+
+Depending on the selected template space and/or parcellation atlas, the datasets will be filtered to include only datasets from the relevant species.
+
+### Human
+
+If the selected template is any of:
+
+- Big Brain (Histology)
+- MNI Colin 27
+- MNI 152 ICBM 2009c Nonlinear Asymmetric
+
+**or**, the selected parcellation is any of:
+
+- Grey/White matter
+- Cytoarchitectonic Maps
+- BigBrain Cortical Layers Segmentation
+- JuBrain Cytoarchitectonic Atlas
+- Fibre Bundle Atlas - Short Bundle
+- Fibre Bundle Atlas - Long Bundle
+- Cytoarchitectonic Maps
+
+Then datasets which have *`Homo sapiens`* as one of its species described above will proceed to the next filter.
+
+### Rat
+
+And selected parcellation is any of:
+
+- Waxholm Space rat brain atlas v1
+- Waxholm Space rat brain atlas v2
+- Waxholm Space rat brain atlas v3
+
+Then datasets which have *`Rattus norvegicus`* as one of its species described above will proceed to the next filter.
+
+### Mouse
+
+And selected parcellation is any of:
+
+- Allen Mouse Common Coordinate Framework v3 2017
+- Allen Mouse Common Coordinate Framework v3 2015
+
+Then datasets which have *`Mus musculus`* as one of its species described above will proceed to the next filter.
+
+
+## Selected template space and parcellation atlas
+
+The datasets are then filtered based on the selected template space and parcellation atlas. 
+
+The dataset must satisfy both conditionals.
+
+### Template space
+
+The reference space associated with datasets are queried with the following querying links:
+
+```json
+{
+  "fieldname": "query:referenceSpaces",
+  "fields": [
+    {
+      "fieldname": "query:name",
+      "relative_path": "http://schema.org/name"
+    },
+    {
+      "fieldname": "query:fullId",
+      "relative_path": "@id"
+    }
+  ],
+  "relative_path": "https://schema.hbp.eu/minds/reference_space"
+}
+```
+
+The dataset is considered relevant (returns true for this conditional) if the stripped `fullId` attribute[^1]  of any of the reference spaces matches to:
+
+[^1]: `fullId` is a URI, which in the case of Human Brain Project Knowledge Graph, always starts with `https://nexus.humanbrainproject.org/v0/data/`. Stripping the domain allows for easier comparison.
+
+| Selected template space | fullId |
+| --- | --- |
+| Big Brain (Histology) | minds/core/dataset/v1.0.0/a1655b99-82f1-420f-a3c2-fe80fd4c8588 |
+| MNI 152 ICBM 2009c Nonlinear Asymmetric | minds/core/dataset/v1.0.0/dafcffc5-4826-4bf1-8ff6-46b8a31ff8e2 |
+| MNI Colin 27 | minds/core/dataset/v1.0.0/7f39f7be-445b-47c0-9791-e971c0b6d992 |
+
+!!! important
+    If the dataset does not have any reference spaces defined, it is considered relevant for any template space, and will return `true` for this conditional.
+
+### Parcellation atlas
+
+The parcellation atlas associated with the dataset are quried with the following querying links:
+
+```json
+{
+  "fieldname": "query:parcellationAtlas",
+  "fields": [
+    {
+      "fieldname": "query:name",
+      "relative_path": "http://schema.org/name"
+    },
+    {
+      "fieldname": "query:fullId",
+      "relative_path": "@id"
+    },
+    {
+      "fieldname": "query:id",
+      "relative_path": "http://schema.org/identifier"
+    }
+  ],
+  "relative_path": "https://schema.hbp.eu/minds/parcellationAtlas"
+}
+```
+
+The parcellation region associated with the dataset are queried with the following querying links:
+
+```json
+{
+  "fieldname": "query:parcellationRegion",
+  "fields": [
+    {
+      "fieldname": "query:name",
+      "relative_path": "http://schema.org/name"
+    },
+    {
+      "fieldname": "query:species",
+      "fields": [
+        {
+          "fieldname": "query:name",
+          "relative_path": "http://schema.org/name"
+        },
+        {
+          "fieldname": "query:@id",
+          "relative_path": "@id"
+        },
+        {
+          "fieldname": "query:identifier",
+          "relative_path": "http://schema.org/identifier"
+        }
+      ],
+      "relative_path": "https://schema.hbp.eu/minds/species"
+    },
+    {
+      "fieldname": "query:alias",
+      "relative_path": "https://schema.hbp.eu/minds/alias"
+    }
+  ],
+  "relative_path": "https://schema.hbp.eu/minds/parcellationRegion"
+}
+```
+
+A dataset is considered relevant (returns true for this conditional) if **both** of the following conditionals are true:
+
+#### Parcellation name
+
+If the name of the selected parcellation in interactive atlas viewer matches exactly with either name of any of the `parcellationAtlas`, or any of its aliases listed below
+
+| `parcellationAtlas` name | aliases |
+| --- | --- |
+| Jülich Cytoarchitechtonic Brain Atlas (human) | Cytoarchitectonic Maps |
+| Jülich Cytoarchitechtonic Brain Atlas (human) | JuBrain Cytoarchitectonic Atlas |
+
+!!! important
+    If the dataset does not have any `parcellationAtlas` defined, it is considered relevant, and will return `true` for this conditional.
+
+#### Parcellation region
+
+If the name of any of the `parcellationRegion` matches either the name or any of the `relatedAreas` attribute of any of the regions of the selected parcellation.
+
+For example, the following dataset ...
+
+```json
+{
+  "name": "dataset foobar",
+  "parcellationRegion": [
+    {
+      "species": [],
+      "name": "Area 44v",
+      "alias": null
+    }
+  ]
+}
+
+```
+
+... will be considered relevant to `JuBrain Cytoarchitectonic Atlas`, as it has an region entry with the following attributes:
+
+```json
+
+{
+  "name": "Area 44 (IFG)",
+  "relatedAreas": [
+    "Area 44v",
+    "Area 44d"
+  ]
+}
+```
\ No newline at end of file
diff --git a/docs/releases/v2.1.0.md b/docs/releases/v2.1.0.md
index d3f114ce3..226989eb2 100644
--- a/docs/releases/v2.1.0.md
+++ b/docs/releases/v2.1.0.md
@@ -1,4 +1,5 @@
 # v2.1.0
 
 New features:
+- updating the querying logic of datasets
 - connectivity browsing for JuBrain atlas
\ No newline at end of file
diff --git a/mkdocs.yml b/mkdocs.yml
index 17acd21e5..cbe53d48d 100644
--- a/mkdocs.yml
+++ b/mkdocs.yml
@@ -11,6 +11,7 @@ docs_dir: docs
 markdown_extensions:
   - admonition
   - codehilite
+  - footnotes
   - mdx_truly_sane_lists
 
 pages:
@@ -23,6 +24,7 @@ pages:
   - Advanced usage:
     - Keyboard shortcuts: 'advanced/keyboard.md'
     - URL parsing: 'advanced/url.md'
+    - Fetching datasets: 'advanced/datasets.md'
   - Release notes:
     - v2.1.0: 'releases/v2.1.0.md'
     - v2.0.2: 'releases/v2.0.2.md'
-- 
GitLab