LogoLogo
  • Welcome to Gretel!
  • Gretel Basics
    • Getting Started
      • Quickstart
      • Blueprints
      • Use Case Examples
      • Environment Setup
        • Console
        • SDK
      • Projects
      • Inputs and Outputs
      • Gretel Connectors
        • Object Storage
          • Amazon S3
          • Google Cloud Storage
          • Azure Blob
        • Database
          • MySQL
          • PostgreSQL
          • MS SQL Server
          • Oracle Database
        • Data Warehouse
          • Snowflake
          • BigQuery
          • Databricks
        • Gretel Project
    • Release Notes
      • Platform Release Notes
        • May 2025
        • April 2025
        • March 2025
        • February 2025
        • January 2025
        • December 2024
        • November 2024
        • October 2024
        • September 2024
        • August 2024
        • July 2024
        • June 2024
      • Console Release Notes
        • January 2025
        • December 2024
        • November 2024
        • October 2024
        • September 2024
        • August 2024
      • Python SDKs
  • Create Synthetic Data
    • Gretel Safe Synthetics
      • Transform
        • Reference
        • Examples
        • Supported Entities
      • Synthetics
        • Gretel Tabular Fine-Tuning
        • Gretel Text Fine-Tuning
        • Gretel Tabular GAN
        • Benchmark Report
        • Privacy Protection
      • Evaluate
        • Synthetic Quality & Privacy Report
        • Tips to Improve Synthetic Data Quality
        • Data Privacy 101
      • SDK
    • Gretel Data Designer
      • Getting Started with Data Designer
      • Define your Data Columns
        • Column Types
        • Add Constraints to Columns
        • Custom Model Configurations
        • Upload Files as Seeds
      • Building your Dataset
        • Seeding your Dataset
        • Generating Data
      • Generate Realistic Personal Details
      • Structured Outputs
      • Code Validation
      • Data Evaluation
      • Magic Assistance
      • Using Jinja Templates
  • Gretel Playground [Legacy]
    • Getting Started
    • Prompts Tips & Best Practices
    • FAQ
    • SDK Examples
    • Tutorials
    • Videos
    • Gretel Playground [Legacy] Inference API
    • Batch Job SDK
  • Reference
    • Gretel's Python Client
    • Gretel’s Open Source Synthetic Engine
    • Gretel’s REST API
    • Homepage
    • Model Suites
Powered by GitBook
On this page
  • Make sure your prompt is at least 25 characters
  • Write prompts relevant for tabular data
  • Describe the data you want in detail
  • Make sure your prompt matches sample data, if you include sample data
  • When adding an example table of records, supplement your prompt with a short text prompt
  • When using SQL statements as your prompt, use CREATE TABLE statements
  • Add clear column descriptions
  • If you encounter errors

Was this helpful?

Export as PDF
  1. Gretel Playground [Legacy]

Prompts Tips & Best Practices

Writing a well-formatted, clear prompt can get you a long way toward high quality tabular results, and often resolve errors you may be experiencing. Follow these guidelines to get the best from Playground.

Make sure your prompt is at least 25 characters

For generating tabular data, make sure your prompt is at least 25 characters.

Write prompts relevant for tabular data

Do not submit spam or prompts irrelevant to a tabular dataset (like "hello") to Playground's tabular data format. If you're looking for question-and-answer style data, try submitting a prompt to our text chat interface (select "Natural Language" in the Playground)

Describe the data you want in detail

The more detail you include, both in terms of what the output should and shouldn’t look like, will lead to better results. This includes:

  • List columns you want the input to have.

  • Describe each column, include things like format you want the data to follow (e.g. YYYY-MM-DD for dates). Describe range of values, if applicable, and the context.

Make sure your prompt matches sample data, if you include sample data

If there is a mismatch between the text prompt and sample data you provide, this can confuse the model and cause errors. For best results, always make sure your text prompt and sample data match.

When adding an example table of records, supplement your prompt with a short text prompt

This helps the model parse the example table. The text prompt can be as simple as an instruction to generate more data following the example data. Example:

Generate 30 rows of data exactly like the following table

When using SQL statements as your prompt, use CREATE TABLE statements

This includes more information than SELECT. You can also combine them both, for example

CREATE TABLE users (
    first_name VARCHAR(50),
    last_name VARCHAR(50),
    dob DATE,
    email VARCHAR(100), -- formatted as the first letter of their first name followed by their last name @foo.io (e.g., jdupont@foo.io)
    city VARCHAR(50),
    country VARCHAR(50) -- all users are from France
);
SELECT * FROM users where dob > "2000-01-01";

Add clear column descriptions

If you want to generate a table with multiple columns, use a bulleted list and a short, clear description of the data you want in each column. Example:

Create a U.S. flight passenger dataset with the following columns: - Traveler ID: a 6-character alphanumeric ID - Departing city: a city in the U.S. - Arrival city: a city in the U.S. - Duration: duration of the flight, in minutes - Number of seats: seats on the flight

If you encounter errors

  • Playground can generate roughly 20-30 columns worth of data, depending on the length of the column name. If you need more columns, consider generating in pieces using edit mode, then joining afterwards

PreviousGetting StartedNextFAQ

Last updated 1 month ago

Was this helpful?

If you encounter issues towards the end of batch generation, consider generating in smaller batches or , which can give you finer control over error handling

If you're having issues with a relatively small prompt, reach out to

using the SDK
support@gretel.ai