Query Profile
From n² wiki
Nearby: Platform Resource Types, Platform API
A Query Profile is a list of field names and their weights. It is used to configure the relevance ranking of searches against the Contentbox. When a user searches the Contentbox and doesn't supply an explicit field name in their search the store uses the Query Profile to determine which fields should be searched.
In this example query profile the field "name" is given a weight of 10 and the field "nick" is given a weight of 5:
<?xml version="1.0" encoding="utf-8"?> <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" xmlns:bf="http://schemas.talis.com/2006/bigfoot/configuration#" xmlns:frm="http://schemas.talis.com/2006/frame/schema#"> <bf:QueryProfile rdf:about="http://api.talis.local/stores/mystore/indexes/default/queryprofiles/default"> <rdfs:label>default query profile</rdfs:label> <bf:fieldWeight> <rdf:Description rdf:about="http://api.talis.com/stores/mystore/indexes/default/queryprofiles/default#name"> <bf:weight>10.0</bf:weight> <frm:name>name</frm:name> </rdf:Description> </bf:fieldWeight> <bf:fieldWeight> <rdf:Description rdf:about="http://api.talis.com/stores/mystore/indexes/default/queryprofiles/default#nick"> <bf:weight>5.0</bf:weight> <frm:name>nick</frm:name> </rdf:Description> </bf:fieldWeight> </bf:QueryProfile> </rdf:RDF>
This means that when a user searches for "bob" the store will rewrite that query internally to be "name:bob nick:bob" and will value occurences of bob in the name field twice as high as occurences in the nick field.
Resource Operations
| Method | Semantics | Capability required |
|---|---|---|
| GET | Retrieve a representation of the query profile | basic-search |
| PUT | Update a representation of the query profile | configure-store |
| DELETE | Not allowed | |
| POST | Not allowed |
The representation consists of the Hierarchical CBD for that resource
As described in Output Types representations of this resource can be obtained by specifying appropriate media types in the accept header of the request or by supplying an output parameter with an appropriate value in the URI's query string. This resource supports at least the following outputs:
- html
- rdf

