AI
Pick the best topic for a prompt
Changed onAnalyze a natural language prompt and determine which topic in the model is the best fit for answering the question. Useful as a preprocessing step before calling generate-query or submitting an AI job, especially when the user's question could relate to multiple topics.
post/api/v1/ai/pick-topic
Request
- Base URLhttps://omniapp.co (the document declares no server; this is the origin it was published from)
- URLhttps://omniapp.co/api/v1/ai/pick-topic
- AuthHTTP bearer
Request body
Example request
{
"branchId": "550e8400-e29b-41d4-a716-446655440000",
"currentTopicName": "order_items",
"modelId": "770e8400-e29b-41d4-a716-446655440002",
"potentialTopicNames": [
"order_items",
"customers",
"products"
],
"prompt": "How many orders were placed last month?",
"userId": "990e8400-e29b-41d4-a716-446655440004"
}Response
Topic selected successfully. The returned topicId can be used as the topicName parameter in other AI endpoints.
Example response
{
"topicId": "order_items"
}Changes
- info
added the new optional request property
/ - info
the
////request property format was generalized fromuuidto no format
- info
- info
added the non-success response with the status
- info