Search

Three search modes are available: full-text, vector (embedding-based), and hybrid (blended).


POST /api/teams/{teamName}/datasets/{dataSetName}/search

bash
curl -X POST https://your-host/api/teams/acme/datasets/products/search \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{"text": "wireless headphones", "maxNumberOfRecordsToReturn": 20}'

With Coverage

json
{
  "text": "wireless headphones",
  "maxNumberOfRecordsToReturn": 30,
  "enableCoverage": true,
  "coverageDepth": 500
}

With Facets and Filter

json
{
  "text": "headphones",
  "maxNumberOfRecordsToReturn": 20,
  "enableFacets": true,
  "filter": {"hashString": "abc123..."}
}

With Per-Field Boosts (BM25F mode only)

fieldBoosts adjusts how much each field counts for one search, without reconfiguring or rebuilding the index. Keys are field names, values are multipliers.

json
{
  "text": "noise cancelling",
  "maxNumberOfRecordsToReturn": 10,
  "fieldBoosts": {
    "title": 3.0,
    "description": 0.5
  }
}
  • A boost multiplies the field's configured weight; it does not replace it. A field with weight: 2.0 and a boost of 3.0 counts 6×. Fields you leave out keep their configured weight (a boost of 1.0).
  • Every key must be a searchable field. Here title and description must both have searchable: true in the dataset's field configuration.
  • A key that is not a searchable field empties the whole search. The response is 200 with no records and a reason naming the field ("FieldBoosts contains unknown or non-searchable field: 'x'"), so read reason before showing "no results". If a search that used to return results suddenly returns none, check fieldBoosts against the field configuration first — making a field non-searchable does not remove it from boosts your code still sends.
  • Boosts only apply in BM25F mode, which a dataset is in when every searchable field has the same bM25k1 (the default; check with GET fields/configuration). If bM25k1 differs between searchable fields the dataset scores each field separately and ignores fieldBoosts — valid keys have no effect, and an invalid key still empties the search.
json
{
  "text": "",
  "maxNumberOfRecordsToReturn": 50,
  "sortBy": "rating",
  "sortAscending": false,
  "enableFacets": true
}

POST /api/teams/{teamName}/datasets/{dataSetName}/search/vector

Approximate nearest-neighbour search against a field marked Embeddable. The query vector must match the field's embedding dimensions. Any length is accepted: Indx brings it to unit length, so scores are cosine similarity.

bash
curl -X POST https://your-host/api/teams/acme/datasets/products/search/vector \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{
    "fieldName": "embedding",
    "vector": [0.12, -0.45, 0.33, ...],
    "maxResults": 10
  }'
PropertyTypeDefaultDescription
fieldName
string
required
Name of the Embeddable field to search
vector
float[]
required
Query vector, with the field's dimensions
maxResults
int
10
Maximum number of results
filter
FilterProxy?
null
Optional filter to restrict the search space

Returns an array of EmbeddingResultEntry with scores in [0, 1] (cosine similarity).


POST /api/teams/{teamName}/datasets/{dataSetName}/search/hybrid

Blends text search and vector search scores. The combined score is:

score = alpha × embeddingScore + (1 − alpha) × normalisedTextScore
bash
curl -X POST https://your-host/api/teams/acme/datasets/products/search/hybrid \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{
    "text": "comfortable headphones",
    "embeddingField": "embedding",
    "vector": [0.12, -0.45, 0.33, ...],
    "alpha": 0.6,
    "maxNumberOfRecordsToReturn": 20
  }'
PropertyTypeDefaultDescription
text
string
""
Text query
embeddingField
string
required
Name of the Embeddable field
vector
float[]
required
Query vector, with the field's dimensions
alpha
float
0.5
Blend weight. 0 = pure text, 1 = pure embedding. Values around 0.5–0.7 work well
maxNumberOfRecordsToReturn
int
10
Maximum results
filter
FilterProxy?
null
Optional filter
timeOutLimitMilliseconds
int
1000
Text search timeout

Returns an array of EmbeddingResultEntry with blended scores in [0, 1].


Retrieving Full Documents

Search endpoints return keys and scores only. Use documents/lookup to fetch the full JSON for a set of keys.

POST /api/teams/{teamName}/datasets/{dataSetName}/documents/lookup

bash
curl -X POST https://your-host/api/teams/acme/datasets/products/documents/lookup \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '[42, 17, 305]'

Returns a string[] of JSON documents in the same order as the input keys.

POST/api/teams/{teamName}/datasets/{dataSetName}/search

Search will validate the search query and return the search result.

Parameters
NameInTypeRequired
teamName
path
string
Yes
dataSetName
path
string
Yes
api-version
header
string
No
api-version
query
string
No
Request Body
Content TypeSchema
application/json
object
POST/api/teams/{teamName}/datasets/{dataSetName}/search/vector

Searches a single embedding field using approximate nearest-neighbour search.

Parameters
NameInTypeRequired
teamName
path
string
Yes
dataSetName
path
string
Yes
api-version
header
string
No
api-version
query
string
No
Request Body
Content TypeSchema
application/json
object
POST/api/teams/{teamName}/datasets/{dataSetName}/search/hybrid

Combines text search with embedding nearest-neighbour search and blends scores.

Parameters
NameInTypeRequired
teamName
path
string
Yes
dataSetName
path
string
Yes
api-version
header
string
No
api-version
query
string
No
Request Body
Content TypeSchema
application/json
object