Generate new phrases based on a set of existing ones

Hi folks,

I’ve been reading through the docs, admittedly for the first time and i’m seeing examples for classification, completion, search etc but nothing for generation.

The goal is to pass a set of (<= 100) documents or prompts (each of which 1-2 lines, less than 140 chars a piece) over to OpenAI and it would return a set of unique, distinct phrases based on the sample set.

Anyone have any idea how to achieve this using the API? Any sample code snippets (in any lang) showing which model and basic params would be infinitely welcome!

Thanks you!

1 Like

See, I want to enter multiple prompts (i.e. a set) and have new text generated, rather than the existing documents/prompts being completed.

Is there a way to enter multiple different documents with say a line break that signifies that each line is a unique document in the playground?

No, look at it in terms of a ‘training set’ of data in and a single new item out based on the training set.

i.e In:

  • I hope everyone has had an excellent day.

  • What weird weather we’ve been having, everyone keeping safe out there.

  • I’m happy to be here and I hope everyone out there is too.


  • Wow, what a beautiful day, hopefully everyone is enjoying it!

(This could be multiple, individual outputs similar to the above.)

I’ve managed to somewhat achieve this by using the instruct beta model and and putting end characters between each of individual inputs, but i’m looking for the proper way to achieve this.