BlueBrain / nexus-forge

Building and Using Knowledge Graphs made easy
https://nexus-forge.readthedocs.io
GNU Lesser General Public License v3.0
38 stars 19 forks source link

Enable querying to ES with _source = False or fewer fields, and no Resource creation #334

Open ssssarah opened 11 months ago

ssssarah commented 11 months ago

Would be useful to have the ability to make the usual forge.elastic, forge.search calls but only to check the existence of something = non empty response with just an id (or less fields than all of them), and not build Resources for matches if one is not interested in the content of the Resource(s)

ssssarah commented 1 month ago

https://github.com/BlueBrain/nexus-forge/pull/382 This enables returning it as a dictionary (not a resource). Additionally one can provide a list of fields in "_source" and because there is no Resource building, it will return this subset of fields successfully. However, _source = False is not yet supported