Title | Added | Status | Last reviewed |
---|---|---|---|
Search Ai service |
v7.0.0-alpha.3 |
Active |
2024-07-12 |
Manages search AI in Content Services.
In order to use this service, you need to have the HX Insights Connector (additional ACS module) installed.
- updateSearchAiInputState(state:
SearchAiInputState
):void
Update the state of the search AI input.- state:
SearchAiInputState
- The new state of the search AI input.
- state:
- ask(question:
QuestionRequest
):Observable
<
QuestionModel
>
Ask a question to the AI.- question:
QuestionRequest
- The question to ask. - Returns
Observable
<
QuestionModel
>
- QuestionModel object containing information about questions.
- question:
- getAnswer(questionId:
string
):Observable
<
AiAnswerEntry
>
Get an answer to specific question.- questionId:
string
- The ID of the question to get an answer for. - Returns
Observable
<
AiAnswerEntry
>
- AiAnswerEntry object containing the answer.
- questionId:
- getConfig():
Observable
<
KnowledgeRetrievalConfigEntry
>
Get the knowledge retrieval configuration.- Returns
Observable
<
KnowledgeRetrievalConfigEntry
>
- KnowledgeRetrievalConfigEntry object containing the configuration.
- Returns
- checkSearchAvailability(selectedNodesState:
SelectionState
, maxSelectedNodes:number
):string
Check if using of search is possible (if all conditions are met).- selectedNodesState:
SelectionState
- information about selected nodes. - maxSelectedNodes:
number
- max number of selected nodes. Default 100. - Returns
string
- string with error if any condition is not met, empty string otherwise.
- selectedNodesState:
See the Search Ai API for more information about the types returned by Search Ai service methods and for the implementation of the REST API the service is based on.