API
Q&A API Documentation.
Last updated
Q&A API Documentation.
Last updated
Note: All API needs an API Key to be sent in the request headers. Please follow these steps to generate an API Key.
To generate an API key for interacting with these APIs, please follow the steps outlined in the "API key generation" section.
Ask a simple question to a specific QnA system or ask a question in the context of a conversation and leverage RAG techniques to get the question answered based on the data corpus configured for that QnA system. You should specify the LLM to use from the ones configured for this QnA system. Note that for chat type conversations (i.e. with conversation history) you are limited to gpt-4 and llama3-70B models. You can pass filter expressions to control the data retrieval process. Optionally, flags can be passed to configure the RAG engine behaviour. Each request is associated with an id to perform additional actions later.
/qna/v1/systems/{systemId}/answer
Id of the QnA system
3756809c-4032-4e48-b3f0-2a6d30a03a54
Text of the question asked to the QnA system
Example to join 2 datasets in S3 and write the output to MongoDB
Reference to Large language model to use for parts of the pipeline such as Generate Answer and Query Rewriting.
774c246b-a079-4fa5-b3dc-4a82b35aa258
Filter expression to apply to data retrieval
version in ('1.2', '2.0')
Flags to control behaviour. Format is Key=value pairs separated by ; Supported flags - include_probe : Default is true. Set to false to disable returning probe data with request
include_probe=false;context=3
For Dataworkz API Token use the format 'SSWS <token>' and for OAuth2 generated JWT token use 'Bearer <token>'
Get a list of all agents in this account - id, name, description
/qna/v1/agents
For Dataworkz API Token use the format 'SSWS <token>' and for OAuth2 generated JWT token use 'Bearer <token>'
For the given agent specified by the agentId, get the agent's response for the user's text and the conversation history
/qna/v1/agents/{agentId}/response
Id of the Agent in the system
3756809c-4032-4e48-b3f0-2a6d30a03a54
The last text from the user
What is the status of the order?
id of the LLM to use with the agent. This must be one of the LLMs configured in this account. Currently, gpt-4 and llama3-70B models are supported.
3756809c-4032-4e48-b3f0-2a6d30a03a54
Any additional properties to be passed to influence execution
For Dataworkz API Token use the format 'SSWS <token>' and for OAuth2 generated JWT token use 'Bearer <token>'
Returns a map containing unique identifier and name for all QnA systems that have been set up in Dataworkz
/qna/v1/systems
For Dataworkz API Token use the format 'SSWS <token>' and for OAuth2 generated JWT token use 'Bearer <token>'
Get details of a specific QnA system
/qna/v1/systems/{systemId}
Id of the QnA system
3756809c-4032-4e48-b3f0-2a6d30a03a54
For Dataworkz API Token use the format 'SSWS <token>' and for OAuth2 generated JWT token use 'Bearer <token>'
Returns a map containing unique identifier and LLM models that have been configured for a given QnA system
/qna/v1/systems/{systemId}/llm-providers
Id of the QnA system
3756809c-4032-4e48-b3f0-2a6d30a03a54
For Dataworkz API Token use the format 'SSWS <token>' and for OAuth2 generated JWT token use 'Bearer <token>'
Ask a question to a specific QnA system and leverage RAG techniques to get the question answered based on the data corpus configured for that QnA system. You should specify the LLM to use from the ones configured for this QnA system. You can pass filter expressions to control the data retrieval process. Optionally, flags can be passed to configure the RAG engine behaviour. Each request is associated with an id to perform additional actions later.
/qna/v1/systems/{systemId}/answer
Id of the QnA system
3756809c-4032-4e48-b3f0-2a6d30a03a54
Text of the question asked to the QnA system
Example to join 2 datasets in S3 and write the output to MongoDB
Reference to Large language model to use for parts of the pipeline such as Generate Answer and Query Rewriting.
774c246b-a079-4fa5-b3dc-4a82b35aa258
Filter expression to apply to data retrieval
version in ('1.2', '2.0')
Flags to control behaviour. Format is Key=value pairs separated by ; Supported flags - include_probe : Default is true. Set to false to disable returning probe data with request
include_probe=false;context=3
For Dataworkz API Token use the format 'SSWS <token>' and for OAuth2 generated JWT token use 'Bearer <token>'
Get a list of search results from the configured system that semantically match the query asked based on similarity with the data corpus configured for that QnA system. You can pass filter expressions to control the data retrieval process. Optionally, flags can be passed to configure the RAG engine behaviour. Each request is associated with an id to perform additional actions later.
/qna/v1/systems/{systemId}/search
Id of the QnA system
3756809c-4032-4e48-b3f0-2a6d30a03a54
search query terms
Example to join 2 datasets in S3 and write the output to MongoDB
Reference to Large language model to use for parts of the pipeline such as Query Rewriting. Will only be used if required.
774c246b-a079-4fa5-b3dc-4a82b35aa258
Filter expression to apply to data retrieval
version in ('1.2', '2.0')
Flags to control behaviour. Format is Key=value pairs separated by ; Supported flags - include_probe : Default is true. Set to false to disable returning probe data with request
include_probe=false;context=3
For Dataworkz API Token use the format 'SSWS <token>' and for OAuth2 generated JWT token use 'Bearer <token>'
Get a list of all filters associated with this system and their metadata which includes their datatype, cardinality and values (for low cardinality filters)
/qna/v1/systems/{systemId}/filters
Id of the QnA system
3756809c-4032-4e48-b3f0-2a6d30a03a54
For Dataworkz API Token use the format 'SSWS <token>' and for OAuth2 generated JWT token use 'Bearer <token>'
Get list of all questions that have been asked by a user in last 6 months from a QnA system
/qna/v1/systems/{systemId}/questionshistory
Id of the QnA system
3756809c-4032-4e48-b3f0-2a6d30a03a54
For Dataworkz API Token use the format 'SSWS <token>' and for OAuth2 generated JWT token use 'Bearer <token>'
Get details about any question that had been asked previously by a user from a QnA system
/qna/v1/systems/{systemId}/questions/{questionId}
Id of the QnA system
3756809c-4032-4e48-b3f0-2a6d30a03a54
Id of the answer request
a647381-1087-6e98-b3f0-5o9876a03a54
For Dataworkz API Token use the format 'SSWS <token>' and for OAuth2 generated JWT token use 'Bearer <token>'