Perform reduce for the project

Executes a reduce operation on project data.

Parameters


"omni_key" is the private key.
You can generate a personal key in your profile settings on the platform. Instructions on how to do this can be found here > API key
"customPrompt" Please summarize the original context in up to 100 words, ensuring the entire response is in the original language and formatted using Markdown.

The following is a friendly conversation between a human and an AI. The AI is talkative is and provides lots of specific details from its context.
If the AI does not know the answer to a question, add
Most likely’ before answering.
Please take into attention the context: {}
Answer the question: {question}

"saveKey" a name of the key in db where results or customPrompt are saved

"language" we support many languages, please indicate which one you use in your project.
Specify the language in code format en/es/ua/de…

Parameters

/rest/v1/projects/{id}/actions/reduce/
Example
{
  "omni_key": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VyIjp7ImlkIjoiNGFiNDUyYTMtNGMwYi00MTIyLWI3NDgtYzk4MWRiN2VlYWFlIiwiZGVmYXVsdFJvbGUiOiJ1c2VyIiwiYWxsb3dlZFJvbGVzIjpbInVzZXIiLCJtZSJdfSwiaWF0IjoxNzE0MzgxNzM4LCJleHAiOjE3NDU5MzkzMzgsInN1YiI6IjRhYjQ1MmEzLTRjMGItNDEyMi1iNzQ4LWM5ODFkYjdlZWFhZSJ9.EFa4TEFmXrSdUX7X6rrfbFSy2xP78YEhHSRWUid9hMo",
  "customPrompt": "{\"question\": \"Write examples.\", \"context\": \"Write examples:\"}",
  "saveKey": "key2",
  "language": "en"
}
Schema
{
  "omni_key": "string",
  "customPrompt": "string",
  "language": "string",
  "saveKey": "string"
}

Responses

Successful operation

Example
{
    "results": [
        {
            "key2": "The provided context appears to be related to sample exam questions for the Certified Tester Foundation Level (CTFL) certification. The questions cover various topics related to software testing, including test activitie..."
        }
    ]
}
Schema
{
  "results": [
    {
      "result": "string"
    }
  ]
}
Was this article helpful to you? Yes No

How can we help?