Skip to main content
A dataset is a collection of records. You can create a dataset by doing the following:
from tatara import Dataset, init_dataset, get_dataset
from tatara import tatara

tatara.init(project=<my_project>)

my_test_dataset = init_dataset("my_test_dataset")
This dataset is empty, so we’ll add some records to it.
new_records = [
{
        "input":"my test input for record 1",
        "output":"my test output for record 1"
},
{
        "input":"my test input for record 2",
        "output":"my test output for record 2",
}
]

ds.insert(new_records)
Now all of this data has been saved to Tatara, so you can view it in the UI by going to the Datasets tab and selecting my_test_dataset. You can also get a dataset by its name in a new session.
from tatara import tatara, get_dataset
tatara.init(project="my_project")
my_test_dataset = get_dataset("my_test_dataset")