- Populate a Frequently Asked Questions page
- Support a search of similar questions
- Prepare test data for Smart Answers
-
POST request - submits a prediction task for a specific
useCaseandmodelId. The API responds with the following information: -
predictionId. A unique UUID for the submitted prediction task that can be used later to retrieve the results. -
status. The current state of the prediction task.- GET request - uses the
predictionIdyou submit from a previously-submitted POST request and returns the results associated with that previous request.
- GET request - uses the
Prerequisites
To use this API, you need:- The unique
APPLICATION_IDfor your Lucidworks AI application, which is provided by Lucidworks. - A bearer token generated with a scope value of
machinelearning.predict. For more information, see Authentication API. - The
USE_CASEandMODEL_IDfields in the/async-predictionfor the POST request. The path is/ai/async-prediction/USE_CASE/MODEL_ID. A list of supported modes is returned in the Lucidworks AI Use Case API. For more information about supported models, see Generative AI models. - Other required fields specified in each individual use case.
Common POST request parameters and fields
Some parameters in the/ai/async-prediction/USE_CASE/MODEL_ID POST request are common to all of the generative AI (Gen-AI) use cases, such as the modelConfig parameter.
Also referred to as hyperparameters, these fields set certain controls on the response.
Refer to the API spec for more information.
Unique values for the FAQ enrichment use case
Some parameter values in thefaq-enrichment use case are unique and may not be available in other use cases, including values for the text and useCaseConfig parameters. Refer to the API spec for more information.
Example POST request
This example does not includemodelConfig parameters, but you can submit requests that include parameters described in Common parameters and fields.