The results can be accessed through the Python dictionary object returned by Hyperspace_client.search(), which has the following entries –
'took_ms' – Specifies the query time in [ms].
'similarity' – Provides the list of results. Each item in results['similarity'] contains the following entries –
'score' (float) – Specifies the matching score for Classic, Vector or Hybrid Search.
'id' (str) – The unique identifier of a document. This is the same id that you assigned to this data when it was uploaded. You can use this identifier to retrieve the document, as described in .
Here is an example of what results might look like if they were printed on the screen –
collection_name – Specifies the Collection name from which to retrieve the documents.
id - the id of each result that was returned.
Retrieving Query Results With Selected Fields
Provide the key fields =[...] to Hyperspace_client.search() during the query submission to retrieve selected document fields, in addition to the document Id. See example below -
The results object will now include a field named "fields" that contains the user selected fields. Here is an example of what results might look like now if they were printed on the screen –