> ## Documentation Index
> Fetch the complete documentation index at: https://docs.keywordsai.co/llms.txt
> Use this file to discover all available pages before exploring further.

# Add test cases from logs

This guide will show you how to create a dataset from logs.

## Prerequisites

You should pass variables in the API request, since we use the variables to define columns of the dataset. Learn how to [log variables here](/documentation/products/prompt_management/use_prompt_in_code/use_prompt_in_llms#log-variables-via-api).

## Steps

<Steps>
  <Step title="Choose the logs you want to include in the testset">
    Click a log, and if it has the Variables section, it means the log has variables and can be included in the testset.

    <Frame>
      <img src="https://keywordsai-static.s3.us-east-1.amazonaws.com/docs/evaluations/logs-variables.png" />
    </Frame>
  </Step>

  <Step title="Bring the log to the testset">
    Click the `+` button, and choose the testset you want to add the log to or create a new testset.

    <Frame>
      <img src="https://keywordsai-static.s3.us-east-1.amazonaws.com/docs/evaluations/log-to-testsets.png" />
    </Frame>
  </Step>
</Steps>
