Skip to main content

Train GPT for Work on your files

info

Only GPT for Sheets and GPT for Excel support this method.

OpenAI Assistants can be used as models in GPT for Work to tailor your results based on specific instructions and data.

This guide shows how to generate product descriptions using customer reviews and marketing briefs uploaded to an Assistant.

Create and set up an Assistant

To create and set up an Assistant to use your files as context for generating responses:

  1. Log in to the OpenAI Platform.

  2. Open the Assistants settings and click Create.

  3. Upload the files that you want the Assistant to use as context when generating responses:

    1. Enable File search and click Files.

      Upload files
    2. In the file attachment screen, select the files and click Attach.

      Attach files

You have created an Assistant and set it up to use your files as context for generating responses.

info

We recommend trying executions in the OpenAI Playground to understand the cost before using it massively.

Prompt an Assistant from GPT for Work

Prerequisites
You have set your OpenAI API key in GPT for Sheets or GPT for Excel.

To prompt an Assistant from GPT for Work:

  1. In GPT for Sheets or GPT for Excel, in the sidebar menu, select Bulk AI tools.

  2. Expand the model switcher and select the Assistant.

    OpenAI Assistant selected in the model switcher
  3. Select Custom prompt.

  4. Enter the following prompt:

    Write a description for this product: {{A}}
  5. In Put results in column, select B.

  6. Click Run rows.

    The Assistant creates a description in Google Sheets when you provide a product ID.

The Assistant searches for information in the files uploaded and uses it to generate content in the selected column. The Instructions as well as Temperature and Top P settings defined during the Assistant creation are taken into account in GPT for Work.