Tutorials
Uptrain API Client
How to run your evaluations remotely using the Uptrain API Client
Create an API Key
To get started, you will first need to get your API key from the Uptrain Dashboard.
- Login with Google
- Click on “Create API Key”
- Copy the API key and save it somewhere safe
Install the Uptrain Python Package
Create an API Client
Check if you are authenticated
Running Evaluations
Step 1: Define the dataset
Your dataset should contain the following columns:
context
: The context for the questionquestion
: The question to be answeredresponse
: The correct answer to the question
Go through the code below to learn how to create a dataset for your evaluation.
Step 2: Run the evaluation
Now that we have our data, we can log it and evaluate it using UpTrain. We use the log_and_evaluate
method to do this. This method takes the following arguments:
project_name
: The name of your projectdata
: The data you want to log and evaluateevals
: The evaluations you want to perform on your data
You can find the list of all available evaluations here.
Step 3: View the results
Was this page helpful?