Class: RetrieveAndRank

RetrieveAndRank

watson.retrieve_and_rank({version: 'v1', ...});

Parameters:
Name Type Description
options
Source:

Methods

createCluster(params, callback)

Creates a Solr cluster.
Parameters:
Name Type Description
params An Object representing the parameters for this service call. Optional params - cluster_name: name to use for identifying the cluster in responses - cluster_size: size of the cluster to create
callback The callback.
Source:

createCollection(params, callback)

Create a Solr collection.
Parameters:
Name Type Description
params An Object representing the parameters for this service call. Required params: - cluster_id: the ID of the Solr cluster to create the collection on - collection_name: the name of the collection to create - config_name: the name of the config in ZooKeeper Optional params: - wt: the writer type for the response, defaults to 'json'
callback The callback.
Source:

createRanker()

Creates a ranker
Source:

createSolrClient(params)

Get a Solr client for indexing and searching documents. See https://github.com/lbdremy/solr-node-client for documentation and examples.
Parameters:
Name Type Description
params An Object representing the parameters for this service call. Required params: - cluster_id: the ID of the Solr cluster to delete the collection on - collection_name: the name of the collection for indexing/searching
Source:

deleteCluster(params, callback)

Deletes a Solr cluster.
Parameters:
Name Type Description
params An Object representing the parameters for this service call. Required params: - cluster_id: the ID of the Solr cluster to delete
callback The callback.
Source:

deleteCollection(params, callback)

Delete a Solr collection.
Parameters:
Name Type Description
params An Object representing the parameters for this service call. Required params: - cluster_id: the ID of the Solr cluster to delete the collection on - collection_name: the name of the collection to delete Optional params: - wt: the writer type for the response, defaults to 'json'
callback The callback.
Source:

deleteConfig(params, callback)

Delete a configuration set in ZooKeeper.
Parameters:
Name Type Description
params An Object representing the parameters for this service call. Required params: - cluster_id: the ID of the Solr cluster to delete configuration from - config_name: the name of the config in ZooKeeper
callback The callback.
Source:

deleteRanker()

Deletes a ranker
Source:

getConfig(params, callback)

Get a configuration set from ZooKeeper as a .zip file.
Parameters:
Name Type Description
params An Object representing the parameters for this service call. Required params: - cluster_id: the ID of the Solr cluster to get configuration from - config_name: the name of the config in ZooKeeper
callback The callback.
Source:

listClusters(params, callback)

Lists all Solr clusters associated with the service instance.
Parameters:
Name Type Description
params An Object representing the parameters for this service call. This request currently does not require any parameters.
callback The callback.
Source:

listCollections(params, callback)

List all collections for a Solr cluster.
Parameters:
Name Type Description
params An Object representing the parameters for this service call. Required params: - cluster_id: the ID of the Solr cluster to list collections from Optional params: - wt: the writer type for the response, defaults to 'json'
callback The callback.
Source:

listConfigs(params, callback)

Lists the configuration sets in ZooKeeper.
Parameters:
Name Type Description
params An Object representing the parameters for this service call. Required params: - cluster_id: the ID of the Solr cluster to get configuration from
callback The callback.
Source:

listRankers()

Retrieves the list of rankers for the user
Source:

pollCluster(params, callback)

Checks whether the specified Solr cluster is ready for use.
Parameters:
Name Type Description
params An Object representing the parameters for this service call. Required params: - cluster_id: the ID of the Solr cluster to poll
callback The callback.
Source:

rank()

Returns the ranked candidates
Source:

rankerStatus()

Returns the training status of the ranker
Source:

uploadConfig(params, callback)

Upload a configuration set to ZooKeeper.
Parameters:
Name Type Description
params An Object representing the parameters for this service call. Required params: - cluster_id: the ID of the Solr cluster to upload configuration to - config_name: the name of the config in ZooKeeper referenced when creating a collection - config_zip_path: the ZIP file to upload
callback The callback.
Source: